Change the main Makefile to have "mini-build" targets.
authorRichard Levitte <levitte@openssl.org>
Wed, 9 Oct 2002 14:52:01 +0000 (14:52 +0000)
committerRichard Levitte <levitte@openssl.org>
Wed, 9 Oct 2002 14:52:01 +0000 (14:52 +0000)
PR: 253, last part.

Makefile.org

index cdeaae66d7f96d43876510f03e43b80e13ed7412..fa99283e5c1f8d035c8c80f43a6f863de6f737c0 100644 (file)
@@ -205,18 +205,30 @@ HEADER=         e_os.h
 # When we're prepared to use shared libraries in the programs we link here
 # we might remove 'clean-shared' from the targets to perform at this stage
 
-all: Makefile.ssl sub_all
+all: Makefile.ssl build_all
 
-sub_all:
-       @for i in $(DIRS); \
-       do \
+BUILD_CMD=if echo " $(DIRS) " | grep " $$i " >/dev/null 2>/dev/null; then \
        if [ -d "$$i" ]; then \
                (cd $$i && echo "making all in $$i..." && \
                $(MAKE) CC='${CC}' PLATFORM='${PLATFORM}' CFLAG='${CFLAG}' SDIRS='$(SDIRS)' INSTALLTOP='${INSTALLTOP}' PEX_LIBS='${PEX_LIBS}' EX_LIBS='${EX_LIBS}' BN_ASM='${BN_ASM}' DES_ENC='${DES_ENC}' BF_ENC='${BF_ENC}' CAST_ENC='${CAST_ENC}' RC4_ENC='${RC4_ENC}' RC5_ENC='${RC5_ENC}' SHA1_ASM_OBJ='${SHA1_ASM_OBJ}' MD5_ASM_OBJ='${MD5_ASM_OBJ}' RMD160_ASM_OBJ='${RMD160_ASM_OBJ}' AR='${AR}' PROCESSOR='${PROCESSOR}' PERL='${PERL}' RANLIB='${RANLIB}' KRB5_INCLUDES='${KRB5_INCLUDES}' LIBKRB5='${LIBKRB5}' EXE_EXT='${EXE_EXT}' SHARED_LIBS='${SHARED_LIBS}' SHLIB_EXT='${SHLIB_EXT}' SHLIB_TARGET='${SHLIB_TARGET}' all ) || exit 1; \
        else \
                $(MAKE) $$i; \
-       fi; \
-       done;
+       fi; fi
+
+build_all: build_libs build_apps build_tests build_tools
+
+build_libs: build_crypto build_ssl
+
+build_crypto:
+       @i=crypto; $(BUILD_CMD)
+build_ssl:
+       @i=ssl; $(BUILD_CMD)
+build_apps:
+       @i=apps; $(BUILD_CMD)
+build_tests:
+       @i=test; $(BUILD_CMD)
+build_tools:
+       @i=tools; $(BUILD_CMD)
 
 libcrypto$(SHLIB_EXT): libcrypto.a
        @if [ "$(SHLIB_TARGET)" != "" ]; then \