summaryrefslogtreecommitdiffstats
path: root/Configurations/windows-makefile.tmpl
AgeCommit message (Collapse)Author
2016-08-02Don't overwrite existing installed openssl.cnfRichard Levitte
Instead, install the new one as openssl.cnf.dist (openssl.cnf-dist on VMS), and only install it as openssl.cnf if that file doesn't already exist. Also, don't install with exec privileges on VMS. Reviewed-by: Rich Salz <rsalz@openssl.org>
2016-07-18Don't make a difference between building test programs and other programsRichard Levitte
This adds a new target 'build_programs' and makes 'build_apps' and 'build_tests' aliases for it, for backward compatibility. Reviewed-by: Rich Salz <rsalz@openssl.org>
2016-07-18Adapt the build files to the new "install" hash tableRichard Levitte
Reviewed-by: Rich Salz <rsalz@openssl.org>
2016-07-15Windows: allow input and output flags to end with a space, or notRichard Levitte
With a number of tools, especially those coming with Visual Studio, some command options are separated from their argument with a space, others with a space. Since we parametrise them, we can't know beforehand which it will be, so we must allow the input and output options to have either. However, spaces at the end of nmake macro values are trimmed, so allow spaces to exist by adding a reference to an undefined macro at the end. Reviewed-by: Andy Polyakov <appro@openssl.org>
2016-07-14Install applink.c with the public header files.Richard Levitte
This is only done for the platforms where 'OPENSSL_USE_APPLINK' is defined. Also, change the docs of OPENSSL_Applink to say where to find applink.c in the installation directory. Reviewed-by: Rich Salz <rsalz@openssl.org>
2016-07-14Windows: take care of manifest filesRichard Levitte
The easiest way to take care of manifest files is to integrate them into the associated binary (.exe or .dll). MT (the Manifest Tool) is the utility to use for this. Reviewed-by: Rich Salz <rsalz@openssl.org>
2016-07-07Windows: make some vars in windows-makefile.tmpl reachable againRichard Levitte
$openssldir and $enginesdir were mistakenly made unavailable to other perl fragments. They are still needed in the definition of CFLAGS. Reviewed-by: Rich Salz <rsalz@openssl.org>
2016-07-07Versioning engines default location: the Windows caseRichard Levitte
OpenSSL engines are tied to the OpenSSL shared library versions, starting with OpenSSL 1.1. We therefore need to install them in directories which have the shared library version in it's name, to easily allow multiple OpenSSL versions to be installed at the same time. For windows, the default installation directory is changed from $PREFIX/lib/engines to $PREFIX/lib/engines-${major}_${minor} ($PREFIX is the directory given for the configuration option --prefix, and ${major} and ${minor} are the major and minor shared library version numbers) Reviewed-by: Rich Salz <rsalz@openssl.org>
2016-07-06Make 'build_libs' build shared libraries as wellRichard Levitte
Reviewed-by: Matt Caswell <matt@openssl.org>
2016-06-30Windows: Recreate the $prefix variableRichard Levitte
$prefix was removed as part of the DESTDIR work. However, it was still used to create the ENGINESDIR_dev and ENGINESDIR_dir variables, so a restoration is needed. Reviewed-by: Rich Salz <rsalz@openssl.org>
2016-06-28Windows: Make DESTDIR workRichard Levitte
DESTDIR can't be used on Windows the same way as on Unix, the device part of the installation paths get in the way. To remedy this, have INSTALLTOP, OPENSSLDIR and ENGINESDIR get different values depending on if $(DESTDIR) is empty or not, and use $(INSTALLTOP), $(OPENSSLDIR) and $(ENGINESDIR) alone. Reviewed-by: Andy Polyakov <appro@openssl.org>
2016-06-28Build files: don't generate empty action lines in generatedir()Richard Levitte
Reviewed-by: Andy Polyakov <appro@openssl.org>
2016-06-27Use include paths to our source before any other cflagsRoumen Petrov
This is just in case someone passed an inclusion path with the configuration, and there are OpenSSL headers from another version in there. Reviewed-by: Tim Hudson <tjh@openssl.org> Reviewed-by: Richard Levitte <levitte@openssl.org>
2016-06-27windows-makefile.tmpl: don't use $? in library targets.Andy Polyakov
Problem with Microsoft lib.exe is that it doesn't *update* modules in .lib archive, but creates new one upon every invocation. As result if a source file was updated and nmake was executed, a useless archive with only one module was created. In other words one has to always pass all .obj modules on command line, not only recently recompiled. [This also creates dilemma for directory targets, e.g. crypto\aes, that were added to simplify every-day life for developer. Since whole idea behind those targets is to minimize the re-compile time upon single file modification, the only sensible thing to do is to omit intended library update.] Reviewed-by: Rich Salz <rsalz@openssl.org> Reviewed-by: Richard Levitte <levitte@openssl.org>
2016-06-17Harmonise the different build filesRichard Levitte
- User targets are now the same and generally do the same things - configdata.pm depends on exactly the same files on all platforms - VMS production of shared libraries is simplified - VMS automatic dependency files get the extension .D rather than .MMS Reviewed-by: Rich Salz <rsalz@openssl.org>
2016-06-14Add a developer target 'build_generated' to rebuild mandatory headersRichard Levitte
Reviewed-by: Rich Salz <rsalz@openssl.org>
2016-06-14Build file templates: make sure to depend on generated header filesRichard Levitte
As well as properly generating those that are made from .in files. Reviewed-by: Rich Salz <rsalz@openssl.org>
2016-06-04Add developer targets for each subdirectory we have something to build inRichard Levitte
Previous build scheme allowed building just the stuff in one subdirectory, like this: make -C crypto/aes Because the unified only has a top-level Makefile, this is not possible with it. This change adds a replacement where each directory we have something to build in becomes a target in its own right, allowing building something like this: make crypto/aes The exception is the directory test, because we already have such a target. Reviewed-by: Stephen Henson <steve@openssl.org>
2016-06-04Windows build: Remove .manifest files in test/ as wellRichard Levitte
Reviewed-by: Rich Salz <rsalz@openssl.org>
2016-05-27Windows makefile: handle the case with space in source directoryRichard Levitte
This applies when building out-of-source. RT#4486 NOTE: we can't do the same for Unix, as Unix make doesn't handle this type of issue. Also, directory specs are much less likely to have spaces on Unix... Reviewed-by: Matt Caswell <matt@openssl.org>
2016-05-25Complete the list of files to clean up on WindowsRichard Levitte
Reviewed-by: Rich Salz <rsalz@openssl.org>
2016-05-25Communicate Configure generated header files to build filesRichard Levitte
Add Configure generated header files to $unified_info{generate}. This makes sure the build files will pick them up with the rest for the GENERATED macro, and thereby make sure they get cleaned away by 'make clean' Reviewed-by: Rich Salz <rsalz@openssl.org>
2016-05-23Install the scripts the same way on Windows and VMS as on UnixRichard Levitte
Reviewed-by: Rich Salz <rsalz@openssl.org>
2016-05-23Make sure tsget.pl and c_rehash.pl get installed on VMS and Windows.Richard Levitte
Reviewed-by: Rich Salz <rsalz@openssl.org>
2016-05-23Windows: shut DEL upRichard Levitte
Reviewed-by: Matt Caswell <matt@openssl.org>
2016-05-19Use the process_docs script to install docs on Windows and VMSRichard Levitte
Reviewed-by: Rich Salz <rsalz@openssl.org>
2016-05-16Small MSVC build fixes.Richard Levitte
- "/Ox /O2 /Ob2" get's reduced to "/O2", the reason being: /Ox = /Ob2 /Og /Oi /Ot /Oy /Gs /O2 = /Ob2 /Og /Oi /Ot /Oy /Gs /GF /Gy - apps/openssl.cnf gets installed. - always delete files quietly, as they might not be there. Reviewed-by: Matt Caswell <matt@openssl.org> (Merged from https://github.com/openssl/openssl/pull/1075)
2016-05-12Windows: When installing libraries and executables, install .pdb files as wellRichard Levitte
Reviewed-by: Rich Salz <rsalz@openssl.org>
2016-05-10windows-makefile.tmpl: minor adjustments.Andy Polyakov
- some Perl versions are allergic to missing ';'; - don't stop if del fails; - omit unused environment variable; Reviewed-by: Stephen Henson <steve@openssl.org>
2016-05-09Configurations/windows-makefile.tmpl: expand environments early.Andy Polyakov
If environment variables are not explanded early enough, expanded strings are passed with single backslash to C compiler, e.g. C:\Program Files, which effectively results in OpenSSL looking for engines and certificates in C:Program Files. Reviewed-by: Richard Levitte <levitte@openssl.org>
2016-04-25Build system: add include directories and dependencies for generatorsRichard Levitte
In the case of generating a file like this: GENERATE[foo.S]=mkfoo.pl arg1 arg2 the 'mkfoo.pl' generator itself might need to include other files, such as perl modules within our source tree. We can reuse already existing syntax for it, like this: INCLUDE[mkfoo.pl]=module/path or: DEPEND[mkfoo.pl]=modules/mymodule.pm This change implements the support for such constructs, and for the DEPEND statement, for any value that indicates a perl module (.pm file), it will automatically infer an INCLUDE statement for its directory, just like it does for C header files, so you won't have do write this: DEPEND[mkfoo.pl]=modules/mymodule.pm INCLUDE[mkfoo.pl]=modules Reviewed-by: Emilia Käsper <emilia@openssl.org>
2016-04-19Build: Make 'test' depend on 'tests'Richard Levitte
Because we have a directory 'test', the target 'test' may be confusing to make. However, if we make it depend on 'tests', which doesn't exist, make should never fail to run the actions. Reviewed-by: Andy Polyakov <appro@openssl.org>
2016-04-14Fix no-stdio and no-autoalginitMatt Caswell
no-stdio does not work with the apps. Since the tests also need the apps it doesn't support that either. Therefore we disable building of both. no-autoalginit is not compatible with the apps because it requires explicit loading of the algorithms, and the apps don't do that. Therefore we disable building the apps for this option. Similarly the tests depend on the apps so we also disable the tests. Finally the whole point about no-autoalginit is to avoid excessive executable sizes when doing static linking. Therefore we disable "shared" if this option is selected. Reviewed-by: Richard Levitte <levitte@openssl.org>
2016-04-13Fix the handling of --with-zlib-includeRichard Levitte
The handling was Unix centric, already in Configure. Change that to just collect the value and let the build file templates figure out what to do with it. Reviewed-by: Matt Caswell <matt@openssl.org>
2016-04-07windows-makefile.tmpl: clean up after DLL link failure.Andy Polyakov
Without proper cleanup after DLL link failure second attempt to run nmake would actually proceed and failure will be "shifted" to run time. This is because libcrypto.lib import library is generated even if DLL link fails. Reviewed-by: Richard Levitte <levitte@openssl.org>
2016-04-04Makefile et al template: only modify static library with new object filesRichard Levitte
Previously, we updated the static libraries (libcrypto.a on Unix, libcrypto.lib on Windows) with all the object files, regardless of if they were rebuilt or not. With this change, we only update them with the object files were rebuilt. NOTE: this does not apply on VMS, as the expansion of $? may be too large for a command line. Reviewed-by: Andy Polyakov <appro@openssl.org>
2016-03-29Build system: VC-WIN64I fixups.Andy Polyakov
Reviewed-by: Richard Levitte <levitte@openssl.org>
2016-03-21Build system: VC-WIN64I fixups.Andy Polyakov
Reviewed-by: Richard Levitte <levitte@openssl.org>
2016-03-21Configurations/windows-makefile.tmpl: respect no-makedepend.Andy Polyakov
Reviewed-by: Richard Levitte <levitte@openssl.org>
2016-03-21Remove generation of ms/version32.rc from Configure, use util/mkrc.plRichard Levitte
utils/mkrc.pl was added a while ago as a better generator for the Windows DLL resource file. Finalize the change by removing the ms/version32.rc generator from Configure and adding resource file support using mkrc.pl in Configurations/windows-makefile.pl Reviewed-by: Andy Polyakov <appro@openssl.org>
2016-03-19If the asm file to be compiled isn't generated, leave the ext aloneRichard Levitte
Closes RT#4447 Reviewed-by: Viktor Dukhovni <viktor@openssl.org>
2016-03-19Add a few more quotes for Windows (install_ssldirs)Richard Levitte
Reviewed-by: Rich Salz <rsalz@openssl.org>
2016-03-19Use the dependencies received in generatesrc()Richard Levitte
generatesrc() did already receive dependency information, but never used it, and never really needed to... until now. Reviewed-by: Rich Salz <rsalz@openssl.org>
2016-03-17windows-makefile.tmpl: Stop keeping temporary filesRichard Levitte
Reviewed-by: Andy Polyakov <appro@openssl.org>
2016-03-17Add install targets for WindowsRichard Levitte
On Windows, we set INSTALLTOP to default as follows: VC-WIN32: PREFIX: %ProgramFiles(x86)%\OpenSSL OPENSSLDIR: %CommonProgramFiles(x86)%\SSL VC-WIN64*: PREFIX: %ProgramW6432%\OpenSSL OPENSSLDIR: %CommonProgramW6432%\SSL Should those environment variables be missing, the following is used as fallback: PREFIX: %ProgramFiles%\OpenSSL OPENSSLDIR: %CommonProgramFiles%\SSL Reviewed-by: Andy Polyakov <appro@openssl.org>
2016-03-16When building DLLs, hack the library name in the .def fileRichard Levitte
util/mkdef.pl assumes it knows what the resulting library name will be. Really, it shouldn't, but changing it will break classic native Windows builds, so we leave it for now and change the LIBRARY line externally when needed instead. Reviewed-by: Matt Caswell <matt@openssl.org>
2016-03-13Harmonize Unix Makefile template with Windows ditoRichard Levitte
The variable SHARED_CFLAGS and SHARD_LDFLAGS were used in the Unix template because they normally contain options used when building "shared". The Windows template, on the other hand, uses LIB_CFLAGS, to express the intended use of those flags rather than their content. The Windows template still used SHARED_LDFLAGS, which seems inconsistent. To harmonize the two, any SHARED_CFLAGS gets renamed to LIB_CFLAGS and SHARED_LDFLAGS to LIB_LDFLAGS. That makes the intent consistent along with BIN_{C,LD}FLAGS and DSO_{C,LD}FLAGS. Finally, make sure to pass down $(LIB_CFLAGS) or $(DSO_CFLAGS) along with $(CFLAGS) when using Makefile.shared. Reviewed-by: Rich Salz <rsalz@openssl.org>
2016-03-10Add cleaning targets to Configurations/windows-makefile.tmplRichard Levitte
Reviewed-by: Matt Caswell <matt@openssl.org>
2016-03-10Pass down inclusion directories to source file generatorsRichard Levitte
The source file generators sometimes use $(CC) to post-process generated source, and getting the inclusion directories may be necessary at times, so we pass them down. RT#4406 Reviewed-by: Rich Salz <rsalz@openssl.org>
2016-03-10When configured "shared", don't build static libraries on WindowsRichard Levitte
The reason for this is that the static libraries and the DLL import libraries are named the same on Windows. When configured "shared", the static libraries are unused anyway. Reviewed-by: Rich Salz <rsalz@openssl.org>