aboutsummaryrefslogtreecommitdiffstats
path: root/src/build-data/makefile
diff options
context:
space:
mode:
authorlloyd <[email protected]>2013-04-17 16:06:56 +0000
committerlloyd <[email protected]>2013-04-17 16:06:56 +0000
commit77f0c643c0a575842fda1891f68bebc4bb8d2697 (patch)
treed066a4075efd5450e25780392f6b32e7f85a2c9a /src/build-data/makefile
parentf1d38d7a08b3939148b3426d00244bad89d23948 (diff)
Always include modules requiring ISA extensions as long as the
compiler and target platform might support it. For instance the AES SSSE3 code is now always in any x86 build, with just that specific file being compiled with -mssse3. Since we'll only call that code if cpuid confirms it works at runtime, we don't have portability issues, and it can be safely included in generic builds (eg for distributions). Tweak how machine specific compiler flags are generated to be a bit easier to maintain.
Diffstat (limited to 'src/build-data/makefile')
-rw-r--r--src/build-data/makefile/unix.in21
-rw-r--r--src/build-data/makefile/unix_shr.in26
2 files changed, 24 insertions, 23 deletions
diff --git a/src/build-data/makefile/unix.in b/src/build-data/makefile/unix.in
index 5290beda8..ca881d65d 100644
--- a/src/build-data/makefile/unix.in
+++ b/src/build-data/makefile/unix.in
@@ -7,6 +7,9 @@ LANG_FLAGS = %{lang_flags}
WARN_FLAGS = %{warn_flags}
LINK_TO = %{link_to}
+LIB_FLAGS = $(LIB_OPT) $(MACH_OPT) $(LANG_FLAGS) $(WARN_FLAGS)
+CHECK_FLAGS = $(CHECK_OPT) $(LANG_FLAGS) $(WARN_FLAGS)
+
# Version Numbers
VERSION = %{version}
SERIES = %{version_major}.%{version_minor}
@@ -38,6 +41,14 @@ RANLIB = %{ranlib_command}
RM = @rm -f
RM_R = @rm -rf
+# Targets
+LIBRARIES = $(STATIC_LIB)
+
+LIBNAME = %{lib_prefix}libbotan
+STATIC_LIB = $(LIBNAME)-$(SERIES).a
+
+all: $(LIBRARIES)
+
# File Lists
CHECK = %{check_prefix}check
@@ -47,16 +58,6 @@ LIBOBJS = %{lib_objs}
CHECKOBJS = %{check_objs}
-LIB_FLAGS = $(LIB_OPT) $(MACH_OPT) $(LANG_FLAGS) $(WARN_FLAGS)
-CHECK_FLAGS = $(CHECK_OPT) $(LANG_FLAGS) $(WARN_FLAGS)
-
-LIBRARIES = $(STATIC_LIB)
-
-LIBNAME = %{lib_prefix}libbotan
-STATIC_LIB = $(LIBNAME)-$(SERIES).a
-
-all: $(LIBRARIES)
-
# Build Commands
%{lib_build_cmds}
diff --git a/src/build-data/makefile/unix_shr.in b/src/build-data/makefile/unix_shr.in
index 31060afbb..806969a00 100644
--- a/src/build-data/makefile/unix_shr.in
+++ b/src/build-data/makefile/unix_shr.in
@@ -2,13 +2,15 @@
CXX = %{cc}
LIB_OPT = %{lib_opt}
CHECK_OPT = %{check_opt}
-MACH_OPT = %{mach_opt}
LANG_FLAGS = %{lang_flags}
WARN_FLAGS = %{warn_flags}
SO_OBJ_FLAGS = %{shared_flags}
SO_LINK_CMD = %{so_link}
LINK_TO = %{link_to}
+LIB_FLAGS = $(LIB_OPT) $(LANG_FLAGS) $(WARN_FLAGS) $(SO_OBJ_FLAGS)
+CHECK_FLAGS = $(CHECK_OPT) $(LANG_FLAGS) $(WARN_FLAGS)
+
# Version Numbers
VERSION = %{version}
SERIES = %{version_major}.%{version_minor}
@@ -40,18 +42,7 @@ RANLIB = %{ranlib_command}
RM = @rm -f
RM_R = @rm -rf
-# File Lists
-CHECK = %{check_prefix}check
-
-HEADERS = %{include_files}
-
-LIBOBJS = %{lib_objs}
-
-CHECKOBJS = %{check_objs}
-
-LIB_FLAGS = $(LIB_OPT) $(MACH_OPT) $(LANG_FLAGS) $(WARN_FLAGS) $(SO_OBJ_FLAGS)
-CHECK_FLAGS = $(CHECK_OPT) $(LANG_FLAGS) $(WARN_FLAGS)
-
+# Targets
LIBRARIES = $(STATIC_LIB) $(SHARED_LIB)
LIBNAME = %{lib_prefix}libbotan
@@ -64,6 +55,15 @@ SYMLINK = $(LIBNAME)-$(SERIES).%{so_suffix}
all: $(LIBRARIES)
+# File Lists
+CHECK = %{check_prefix}check
+
+HEADERS = %{include_files}
+
+LIBOBJS = %{lib_objs}
+
+CHECKOBJS = %{check_objs}
+
# Build Commands
%{lib_build_cmds}