From: Tom Yu Date: Wed, 1 Mar 2000 11:33:47 +0000 (+0000) Subject: Tweak build system to deal somewhat better with HPUX shared libs X-Git-Tag: krb5-1.2-beta1~29 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=716028865235bb0953431df6ad77af79b78d93a8;p=krb5.git Tweak build system to deal somewhat better with HPUX shared libs git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@12095 dc483132-0cff-0310-8789-dd5450dbe970 --- diff --git a/src/ChangeLog b/src/ChangeLog index 903449e24..9f28934dc 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,8 @@ +2000-03-01 Tom Yu + + * aclocal.m4: Add support for setting the INSTALL_SHLIB variable. + Tweak the HPUX shared lib build somewhat. + 2000-02-28 Ken Raeburn * configure.in: Add enable-kdc-replay-cache arg, to make usage diff --git a/src/aclocal.m4 b/src/aclocal.m4 index 2c30f36bc..dba83554a 100644 --- a/src/aclocal.m4 +++ b/src/aclocal.m4 @@ -906,6 +906,7 @@ AC_SUBST(LIBLINKS) AC_SUBST(LDCOMBINE) AC_SUBST(LDCOMBINE_TAIL) AC_SUBST(SHLIB_EXPFLAGS) +AC_SUBST(INSTALL_SHLIB) AC_SUBST(STLIBEXT) AC_SUBST(SHLIBEXT) AC_SUBST(SHLIBVEXT) @@ -941,6 +942,7 @@ AC_SUBST(LIBLINKS) AC_SUBST(LDCOMBINE) AC_SUBST(LDCOMBINE_TAIL) AC_SUBST(SHLIB_EXPFLAGS) +AC_SUBST(INSTALL_SHLIB) AC_SUBST(STLIBEXT) AC_SUBST(SHLIBEXT) AC_SUBST(SHLIBVEXT) @@ -1106,6 +1108,8 @@ SHLIBVEXT=.so.v-nobuild SHLIBSEXT=.so.s-nobuild # Most systems support profiled libraries. PFLIBEXT=_p.a +# Most systems install shared libs as mode 644, etc. while hpux wants 755 +INSTALL_SHLIB='$(INSTALL_DATA)' STOBJEXT=.o SHOBJEXT=.so @@ -1130,7 +1134,7 @@ alpha-dec-osf*) RUN_ENV='LD_LIBRARY_PATH=`echo $(PROG_LIBPATH) | sed -e "s/-L//g" -e "s/ /:/g"`:$(PROG_RPATH):/usr/shlib:/usr/ccs/lib:/usr/lib/cmplrs/cc:/usr/lib:/usr/local/lib; export LD_LIBRARY_PATH; _RLD_ROOT=/dev/dummy/d; export _RLD_ROOT;' ;; -# HPUX untested... +# HPUX *seems* to work under 10.20. # # Note: "-Wl,+s" when building executables enables the use of the # SHLIB_PATH environment variable for finding shared libraries @@ -1142,10 +1146,12 @@ alpha-dec-osf*) # *-*-hpux*) PICFLAGS=+z + INSTALL_SHLIB='$(INSTALL_PROGRAM)' SHLIBEXT=.sl SHLIBVEXT='.sl.$(LIBMAJOR).$(LIBMINOR)' + SHLIBSEXT='.sl.$(LIBMAJOR)' SHLIB_EXPFLAGS='+b $(SHLIB_RDIRS) $(SHLIB_DIRS) $(SHLIB_EXPLIBS)' - LDCOMBINE='ld -b' + LDCOMBINE='ld -b +h lib$(LIB)$(SHLIBSEXT)' CC_LINK_SHARED='$(CC) $(PROG_LIBPATH) -Wl,+s -Wl,+b,$(PROG_RPATH)' CC_LINK_STATIC='$(CC) $(PROG_LIBPATH)' RUN_ENV='SHLIB_PATH=`echo $(PROG_LIBPATH) | sed -e "s/-L//g" -e "s/ /:/g"`; export SHLIB_PATH;' diff --git a/src/config/ChangeLog b/src/config/ChangeLog index f6f9ea866..97bce15ad 100644 --- a/src/config/ChangeLog +++ b/src/config/ChangeLog @@ -1,3 +1,9 @@ +2000-03-01 Tom Yu + + * pre.in (INSTALL_SHLIB): New variable. + + * lib.in (install-shared): Use $(INSTALL_SHLIB) + 2000-02-15 Tom Yu * libobj.in: Fix up .c.so and .c.po rules to include $(CFLAGS), diff --git a/src/config/lib.in b/src/config/lib.in index 22a801b9e..203376ec1 100644 --- a/src/config/lib.in +++ b/src/config/lib.in @@ -150,7 +150,7 @@ install-static: install-shared: $(RM) $(DESTDIR)$(KRB5_LIBDIR)/lib$(LIB)$(SHLIBVEXT) $(RM) $(DESTDIR)$(KRB5_LIBDIR)/lib$(LIB)$(SHLIBEXT) - $(INSTALL_DATA) lib$(LIB)$(SHLIBVEXT) $(DESTDIR)$(KRB5_LIBDIR) + $(INSTALL_SHLIB) lib$(LIB)$(SHLIBVEXT) $(DESTDIR)$(KRB5_LIBDIR) (cd $(DESTDIR)$(KRB5_LIBDIR) && $(LN_S) lib$(LIB)$(SHLIBVEXT) \ lib$(LIB)$(SHLIBEXT)) install-shlib-soname: install-shared diff --git a/src/config/pre.in b/src/config/pre.in index 375df9fa8..abc3dff58 100644 --- a/src/config/pre.in +++ b/src/config/pre.in @@ -90,6 +90,7 @@ CLNTDEPLIBS = @CLNTDEPLIBS@ INSTALL=@INSTALL@ INSTALL_PROGRAM=@INSTALL_PROGRAM@ -s INSTALL_DATA=@INSTALL_DATA@ +INSTALL_SHLIB=@INSTALL_SHLIB@ INSTALL_SETUID=$(INSTALL) -s -m 4755 -o root ## This is needed because autoconf will sometimes define @exec_prefix@ to be ## ${prefix}.