aboutsummaryrefslogtreecommitdiff
path: root/Configurations
AgeCommit message (Collapse)AuthorFilesLines
2016-03-13Collect the names of generated files and clean them away at target clean:Richard Levitte1-7/+9
Reviewed-by: Rich Salz <rsalz@openssl.org>
2016-03-13Use single quotes rather than double quotes when neededRichard Levitte1-16/+16
When passing down values to Makefile.shared, do so with single quotes as much as possible to avoid having the shell create a mess of quotes. Reviewed-by: Rich Salz <rsalz@openssl.org>
2016-03-13Harmonize Unix Makefile template with Windows ditoRichard Levitte2-27/+28
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-12Avoid sed for dependency post-processingRichard Levitte1-7/+3
It turns out that different sed implementations treat -i differently to cause issues. make it simpler by avoiding it entirely and give perl the trust to be consistent enough. Reviewed-by: Rich Salz <rsalz@openssl.org>
2016-03-11Some sed implementations are not greedy enough, use perl insteadRichard Levitte1-1/+10
The issue is demonstrated as follows: On Linux: $ echo ': foo.h /usr/include/stddef.h bar.h' | sed -e 's/ \/\(\\.\|[^ ]\)*//g' : foo.h bar.h On MacOS X: $ echo ': foo.h /usr/include/stddef.h bar.h' | sed -e 's/ \/\(\\.\|[^ ]\)*//g' : foo.husr/include/stddef.h bar.h Perl is more consistent: On Linux: $ echo ': foo.h /usr/include/stddef.h bar.h' | perl -pe 's/ \/(\\.|[^ ])*//g;' : foo.h bar.h On MacOS X: $ echo ': foo.h /usr/include/stddef.h bar.h' | perl -pe 's/ \/(\\.|[^ ])*//g;' : foo.h bar.h Reviewed-by: Andy Polyakov <appro@openssl.org>
2016-03-11Configurations/unix-Makefile.tmpl: don't leave empty .s files behind.Andy Polyakov1-2/+2
If pre-processor failed, an empty .s file could be left behind, which could get successfully compiled if one simply re-ran make and cause linking failures. Not anymore. Remove even intermediate .S in case of pre-processor failure. Reviewed-by: Richard Levitte <levitte@openssl.org>
2016-03-11Harmonise the two methods to generate dependency filesRichard Levitte1-2/+8
One of them didn't clean away .d.tmp files properly. The other would overwrite the .d files unconditionally, thereby causing a possibly unnecessary dependency rebuild, which touches the date of Makefile, which causes a possibly unnecessary rebuild of buildinf.h and everything that depends on that. Reviewed-by: Andy Polyakov <appro@openssl.org>
2016-03-10In the recipe using "makedepend", make sure the object file extension is thereRichard Levitte1-1/+1
Reviewed-by: Stephen Henson <steve@openssl.org>
2016-03-10Add cleaning targets to Configurations/windows-makefile.tmplRichard Levitte1-0/+14
Reviewed-by: Matt Caswell <matt@openssl.org>
2016-03-10Pass down inclusion directories to source file generatorsRichard Levitte3-6/+15
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 Levitte1-0/+5
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>
2016-03-09Adapt the Windows makefile template to source generationRichard Levitte1-0/+47
Reviewed-by: Rich Salz <rsalz@openssl.org>
2016-03-09Unified - extract settings from util/pl/VC-32.pl and make the config settingsRichard Levitte3-36/+212
This introduces the settings loutflag and aroutflag, because different Windows tools that do the same thing have different ways to specify the output file. The Borland C++ config is commented away for the monent, perhaps permanently. Reviewed-by: Rich Salz <rsalz@openssl.org>
2016-03-09Unified - a native Windows makefile templateRichard Levitte1-0/+293
Reviewed-by: Rich Salz <rsalz@openssl.org>
2016-03-09Because crypto/build.info demands CFLAGS_Q, descrip.mms.tmpl must deliverRichard Levitte1-0/+1
Reviewed-by: Andy Polyakov <appro@openssl.org>
2016-03-09Add missing semiRichard Levitte1-1/+1
Reviewed-by: Viktor Dukhovni <viktor@openssl.org>
2016-03-09Adapt unix Makefile template to 'no-makedepend'Richard Levitte1-5/+18
This change is a bit more complex, as it involves several recipe variants. Also, remove the $(CROSS_COMPILE) prefix for the makedepend program. When we use the program "makedepend", this doesn't serve anything, and when we use the compiler, this value isn't even used. Reviewed-by: Rich Salz <rsalz@openssl.org>
2016-03-09Adapt descrip.mms.tmpl to 'no-makedepend'Richard Levitte1-1/+7
VMS doesn't have "makedepend" anyway, so this is just a matter of using the right qualifiers when 'makedepend' is enabled. Reviewed-by: Rich Salz <rsalz@openssl.org>
2016-03-09Redo the Unix source code generatorRichard Levitte1-20/+29
For assembler, we want the final target to be foo.s (lowercase s). However, the build.info may have lines like this (note upper case S): GENERATE[foo.S]=foo.pl This indicates that foo.s (lowercase s) is still to be produced, but that producing it will take an extra step via $(CC) -E. Therefore, the following variants (simplified for display) can be generated: GENERATE[foo.S]=foo.pl => foo.s: foo.pl $(PERL) $foo.pl $@.S; \ $(CC) $(CFLAGS) -E -P $@.S > $@ && \ rm -f $@.S GENERATE[foo.s]=foo.pl => foo.s: foo.pl $(PERL) $foo.pl $@ GENERATE[foo.S]=foo.m4 => foo.s: foo.m4 m4 -B 8192 $foo.m4 > $@.S; \ $(CC) $(CFLAGS) -E -P $@.S > $@ && \ rm -f $@.S GENERATE[foo.s]=foo.m4 => foo.s: foo.m4 m4 -B 8192 $foo.m4 > $@ Reviewed-by: Andy Polyakov <appro@openssl.org>
2016-03-08SPARCv9 assembly pack: unify build rules and argument handling.Andy Polyakov1-5/+5
Make all scripts produce .S, make interpretation of $(CFLAGS) pre-processor's responsibility, start accepting $(PERLASM_SCHEME). [$(PERLASM_SCHEME) is redundant in this case, because there are no deviataions between Solaris and Linux assemblers. This is purely to unify .pl->.S handling across all targets.] Reviewed-by: Richard Levitte <levitte@openssl.org>
2016-03-08Fix configurations such as 'dist' and tar buildingRichard Levitte2-3/+8
For config targets such as 'dist', which doesn't have a BASE template, we still need to have a default build scheme. Additionally, the unified Makefile template's target 'tar' wasn't quite as flexible as the unixmake one. Finally, .travis-create-release.sh can be somewhat simplified now that it builds with the unified build scheme. Reviewed-by: Matt Caswell <matt@openssl.org>
2016-03-08Make unified builds the default on UnixRichard Levitte1-4/+1
Reviewed-by: Matt Caswell <matt@openssl.org>
2016-03-07Unified - Add the build.info command OVERRIDE, to avoid build file clashesRichard Levitte2-0/+15
Should it be needed because the recipes within a RAW section might clash with those generated by Configure, it's possible to tell it not to generate them with the use of OVERRIDES, for example: SOURCE[libfoo]=foo.c bar.c OVERRIDES=bar.o BEGINRAW[Makefile(unix)] bar.o: bar.c $(CC) $(CFLAGS) -DSPECIAL -c -o $@ $< ENDRAW[Makefile(unix)] Reviewed-by: Rich Salz <rsalz@openssl.org>
2016-03-07Unified - Adapt the Unix and VMS templates to support GENERATERichard Levitte2-0/+52
Reviewed-by: Rich Salz <rsalz@openssl.org>
2016-03-07Unified - Add the build.info command GENERATE, to generate source filesRichard Levitte3-14/+62
In some cases, one might want to generate some source files from others, that's done as follows: GENERATE[foo.s]=asm/something.pl $(CFLAGS) GENERATE[bar.s]=asm/bar.S The value of each GENERATE line is a command line or part of it. Configure places no rules on the command line, except the the first item muct be the generator file. It is, however, entirely up to the build file template to define exactly how those command lines should be handled, how the output is captured and so on. Reviewed-by: Rich Salz <rsalz@openssl.org>
2016-03-05No -fno-common for DarwinRichard Levitte1-1/+2
When object files with common block symbols are added to static libraries on Darwin, those symbols are invisible to the linker that tries to use them. Our solution was to use -fno-common when compiling C source. Unfortunately, there is assembler code that defines OPENSSL_ia32cap_P as a common block symbol, unconditionally, and in some cases, there is no other definition. -fno-common doesn't help in this case. However, 'ranlib -c' adds common block symbols to the index of the static library, which makes them visible to the linker using it, and that solves the problem we've seen. The common conclusion is, either use -fno-common or ranlib -c on Darwin. Since we have common block symbols unconditionally, choosing the method for our source is easy. Reviewed-by: Kurt Roeckx <kurt@openssl.org>
2016-03-05Change names of ordinals and libs, libeay => libcrypto and ssleay => libsslRichard Levitte1-4/+4
Reviewed-by: Rich Salz <rsalz@openssl.org>
2016-03-04Correction, $disabled{shared} rather than $config{no_shared}Richard Levitte1-1/+1
Reviewed-by: Rich Salz <rsalz@openssl.org>
2016-03-03Remove overzealous echoingRichard Levitte1-17/+9
This construct in a Makefile is a bit overzealous: @echo FOO @FOO Cleaned up. Reviewed-by: Rich Salz <rsalz@openssl.org>
2016-03-02Document the changes in config settingsRichard Levitte1-28/+9
Reviewed-by: Andy Polyakov <appro@openssl.org>
2016-03-02Don't copy from %target to %config so much, see %config as a complementRichard Levitte2-5/+5
We copied $target{cflags}, $target{defines} and a few more to %config, just to add to the entries. Avoid doing so, and let the build templates deal with combining the two. There are a few cases where we still fiddle with %target, but that's acceptable. Reviewed-by: Andy Polyakov <appro@openssl.org>
2016-03-02Configure - Get rid of the special thread_cflag, replace with thread_schemeRichard Levitte8-192/+263
The thread_cflag setting filled a double role, as kinda sorta an indicator of thread scheme, and as cflags. Some configs also added lflags and ex_libs for multithreading regardless of if threading would be enabled or not. Instead of this, add threading cflags among in the cflag setting, threading lflags in the lflag setting and so on if and only if threads are enabled (which they are by default). Also, for configs where there are no special cflags for threading (the VMS configs are of that kind), this makes it possible to still clearly mention what thread scheme is used. The exact value of thread scheme is currently ignored except when it's "(unknown)", and thereby only serves as a flag to tell if we know how to build for multi-threading in a particular config. Yet, the currently used values are "(unknown)", "pthreads", "uithreads" (a.k.a solaris threads) and "winthreads". Reviewed-by: Andy Polyakov <appro@openssl.org>
2016-03-02Configure - get rid of the special debug_ and release_ settingsRichard Levitte3-157/+166
Instead, make the build type ("debug" or "release") available through $config{build_type} and let the configs themselves figure out what the usual settings (such as "cflags", "lflags" and so on) should be accordingly. The benefit with this is that we can now have debug and release variants of any setting, not just those Configure supports, and may also involve other factors (the MSVC flags /MD[d] and /MT[d] involve both build type and whether threading is enabled or not) Reviewed-by: Andy Polyakov <appro@openssl.org>
2016-03-02Minimize copied config settingsRichard Levitte2-3/+3
$target{lflags} and $target{plib_flag} were copied to %config for no good reason. Reviewed-by: Andy Polyakov <appro@openssl.org>
2016-03-02Configure - move the addition of the zlib / libz lib to configsRichard Levitte6-47/+96
Configure had the Unix centric addition of -lz when linking with zlib is enabled, which doesn't work on other platforms. Therefore, we move it to the BASE_unix config template and add corresponding ones in the other BASE_* config templates. The Windows one is probably incomplete, but that doesn't matter for the moment, as mk1mf does it's own thing anyway. This required making the %withargs table global, so perl snippets in the configs can use it. Reviewed-by: Andy Polyakov <appro@openssl.org>
2016-03-02Configure - Rename BASE to DEFAULTS and add a few inheritable BASEsRichard Levitte2-45/+113
These BASE templates are intended to hold values that are common for all configuration variants for whole families of configurations. So far, three "families" are identified: Unix, Windows and VMS, mostly characterised by the build system they currently use. Reviewed-by: Andy Polyakov <appro@openssl.org>
2016-03-02Add a shared_target to the VC-common configRichard Levitte1-0/+1
This has no real meaning, except it gives Configure a hint that VC targets are indeed capable of producing shared objects. Reviewed-by: Matt Caswell <matt@openssl.org>
2016-03-02Make uplink auxiliary source separate from cpuid sourceRichard Levitte1-4/+5
There are cases, for example when configuring no-asm, that the added uplink source files got in the way of the cpuid ones. The best way to solve this is to separate the two. Reviewed-by: Andy Polyakov <appro@openssl.org>
2016-03-01Unified - have configdata.pm depend on a few more thingsRichard Levitte2-2/+2
Reviewed-by: Andy Polyakov <appro@openssl.org>
2016-02-28VMS - don't exit out of a MMS recipeRichard Levitte1-4/+4
Exiting out of a recipe more than necessary leaves an ugly message. Reviewed-by: Rich Salz <rsalz@openssl.org>
2016-02-28Make generation of dependency files more efficient when possibleRichard Levitte2-14/+11
When building with GNU C, clang or VMS C, it's more efficient to generate dependency file and object file in one call rather than two. Have the dependency output in a temporary file and compare it with the previous one if available to see if replacement is waranted, thereby avoiding unnecessary reconstruction of Makefile / descrip.mms. Github issue #750 Reviewed-by: Rich Salz <rsalz@openssl.org>
2016-02-27Remove some old files.Rich Salz2-29/+3
I read the PROBLEMS, and they're outdated; nothing I'd put in the online FAQ, for example. Test-builds work without using these files. Had to remove the rehash.time stuff from Makefile.in Reviewed-by: Richard Levitte <levitte@openssl.org>
2016-02-27Keep a cache of files that already have a recipe, in common.tmplRichard Levitte1-1/+12
We don't want recipes for the same files generated more than once Reviewed-by: Rich Salz <rsalz@openssl.org>
2016-02-27GH753: More spelling fixFdaSilvaYY3-11/+11
Signed-off-by: Rich Salz <rsalz@akamai.com> Reviewed-by: Kurt Roeckx <kurt@openssl.org>
2016-02-26Public API for Certificate TransparencyRob Percival2-6/+2
Reviewed-by: Ben Laurie <ben@openssl.org> Reviewed-by: Rich Salz <rsalz@openssl.org>
2016-02-26Remove comments saying you must do 'make -f Makefile.in TABLE'Richard Levitte8-32/+0
Since the configs were remade into hash tables, this isn't needed any more. Reviewed-by: Rich Salz <rsalz@openssl.org>
2016-02-26Unified on VMS - add %disabled in vmsconfig.pm (util/dofile.pl demands it)Richard Levitte1-1/+2
Reviewed-by: Rich Salz <rsalz@openssl.org>
2016-02-26Configure - neater looking add() and add_before()Richard Levitte3-37/+37
They now default to " " as separator, but that can be overridden by having a hash with parameters as last argument. The only currently recognised parameter is `separator'. The special separator `undef' will force the result to become a list rather than a concatenated string. Reviewed-by: Andy Polyakov <appro@openssl.org>
2016-02-25Make it possible to build even if dependency files can't be generatedRichard Levitte1-1/+1
If the local system doesn't have GNU C or clang, and not even makedepend, the build will stop because the call of 'makedepend' fails. This changes so the build won't stop because of such failure. The result will be empty .d files, and that's ok. Reviewed-by: Rich Salz <rsalz@openssl.org>
2016-02-23Remove all -march= from configsRichard Levitte2-11/+7
These flags are limitting needlessly, are often patched by packagers, and should be specified on the configuration command line by anyone who desires for it to be specific rather than forced by us. This work was already done with mingw when those configs were worked on, now it gets applied to the remaining configs. Reviewed-by: Andy Polyakov <appro@openssl.org>