Allow shared builds for aix[64]-gcc targets.
[openssl.git] / Makefile.shared
index ef1ec63..acdbb2e 100644 (file)
@@ -510,26 +510,26 @@ link_app.hpux:
 
 link_o.aix:
        @ $(CALC_VERSIONS); \
-       OBJECT_MODE=`expr x$(SHARED_LDFLAGS) : 'x\-[a-z]\([0-9]*\)'`; \
+       OBJECT_MODE=`expr x$(SHARED_LDFLAGS) : 'x\-[a-z]*\(64\)'` || :; \
        OBJECT_MODE=$${OBJECT_MODE:-32}; export OBJECT_MODE; \
        SHLIB=lib$(LIBNAME).so; \
        SHLIB_SUFFIX=; \
        ALLSYMSFLAGS=''; \
        NOALLSYMSFLAGS=''; \
-       SHAREDFLAGS='$(CFLAGS) $(SHARED_LDFLAGS) -G -bexpall -bnolibpath -bM:SRE'; \
+       SHAREDFLAGS='$(CFLAGS) $(SHARED_LDFLAGS) -Wl,-G,-bexpall,-bnolibpath,-bM:SRE'; \
        $(LINK_SO_O);
 link_a.aix:
        @ $(CALC_VERSIONS); \
-       OBJECT_MODE=`expr x$(SHARED_LDFLAGS) : 'x\-[a-z]\([0-9]*\)'`; \
+       OBJECT_MODE=`expr x$(SHARED_LDFLAGS) : 'x\-[a-z]*\(64\)'` || : ; \
        OBJECT_MODE=$${OBJECT_MODE:-32}; export OBJECT_MODE; \
        SHLIB=lib$(LIBNAME).so; \
        SHLIB_SUFFIX=; \
        ALLSYMSFLAGS='-bnogc'; \
        NOALLSYMSFLAGS=''; \
-       SHAREDFLAGS='$(CFLAGS) $(SHARED_LDFLAGS) -G -bexpall -bnolibpath -bM:SRE'; \
+       SHAREDFLAGS='$(CFLAGS) $(SHARED_LDFLAGS) -Wl,-G,-bexpall,-bnolibpath,-bM:SRE'; \
        $(LINK_SO_A_VIA_O)
 link_app.aix:
-       LDFLAGS="$(CFLAGS) -brtl -blibpath:$(LIBRPATH):$${LIBPATH:-/usr/lib:/lib}"; \
+       LDFLAGS="$(CFLAGS) -Wl,-brtl,-blibpath:$(LIBRPATH):$${LIBPATH:-/usr/lib:/lib}"; \
        $(LINK_APP)
 
 link_o.reliantunix: