Make link-shard a little bit more efficient. If there are no
authorRichard Levitte <levitte@openssl.org>
Wed, 13 Feb 2002 10:15:05 +0000 (10:15 +0000)
committerRichard Levitte <levitte@openssl.org>
Wed, 13 Feb 2002 10:15:05 +0000 (10:15 +0000)
extensions to link together, there's no point looping at all.

Makefile.org

index 1ca0b283684992734e51a9bd3187c8a75a225334..1b2e9e90f8d8f0edf7bd551a3403c056d94843a8 100644 (file)
@@ -243,16 +243,16 @@ clean-shared:
        done
 
 link-shared:
-       @for i in $(SHLIBDIRS); do \
-               prev=lib$$i$(SHLIB_EXT); \
-               if [ -n "$(SHARED_LIBS_LINK_EXTS)" ]; then \
-                       tmp="$(SHARED_LIBS_LINK_EXTS)"; \
+       if [ -n "$(SHARED_LIBS_LINK_EXTS)" ]; then \
+               tmp="$(SHARED_LIBS_LINK_EXTS)"; \
+               @for i in $(SHLIBDIRS); do \
+                       prev=lib$$i$(SHLIB_EXT); \
                        for j in $${tmp:-x}; do \
                                ( set -x; ln -f -s $$prev lib$$i$$j ); \
                                prev=lib$$i$$j; \
                        done; \
-               fi; \
-       done
+               done; \
+       fi
 
 build-shared: clean-shared do_$(SHLIB_TARGET) link-shared