summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorrbb <rbb@13f79535-47bb-0310-9956-ffa450edef68>2001-04-06 18:57:17 +0000
committerrbb <rbb@13f79535-47bb-0310-9956-ffa450edef68>2001-04-06 18:57:17 +0000
commitcd35cada41ee653dadba5e6999a03d4382965a8b (patch)
tree671d36803608e076546a1efb8c5f0bb142176056
parent9367d04b53aa2d7d656609e285388680fdec6556 (diff)
downloadlibapr-cd35cada41ee653dadba5e6999a03d4382965a8b.tar.gz
Make libtool a configure-time option. This is done with --without-libtool.
The default is to use libtool git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@61465 13f79535-47bb-0310-9956-ffa450edef68
-rw-r--r--CHANGES3
-rw-r--r--Makefile.in7
-rw-r--r--build/rules.mk.in6
-rw-r--r--configure.in20
4 files changed, 29 insertions, 7 deletions
diff --git a/CHANGES b/CHANGES
index c7ce3099b..85ff46b70 100644
--- a/CHANGES
+++ b/CHANGES
@@ -1,5 +1,8 @@
Changes with APR b1
+ *) Make libtool optional at configure time. This is done with
+ --without-libtool. [Ryan Bloom]
+
*) Recognize systems where the TCP_NODELAY setting is inherited from
the listening socket, and optimize apr_setsockopt(APR_TCP_NODELAY)
accordingly. [Jeff Trawick]
diff --git a/Makefile.in b/Makefile.in
index 2065af7f4..6375665a1 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -42,7 +42,7 @@ includedir=@includedir@
delete-lib:
@if test -f $(TARGET_LIB); then \
- for i in $(SUBDIRS); do objects="$$objects $$i/*.lo"; done ; \
+ for i in $(SUBDIRS); do objects="$$objects $$i/*.@so_ext@"; done ; \
if test -n "`find $$objects -newer $(TARGET_LIB)`"; then \
echo Found newer objects. Will relink $(TARGET_LIB). ; \
echo $(RM) -f $(TARGET_LIB) ; \
@@ -61,9 +61,8 @@ install: $(TARGET_LIB)
$(LIBTOOL) --mode=install cp $(TARGET_LIB) $(libdir)
$(TARGET_LIB):
- @for i in $(SUBDIRS); do objects="$$objects $$i/*.lo"; done ; \
- echo $(LINK) -rpath $(libdir) $$objects ; \
- $(LINK) -rpath $(libdir) $$objects
+ @for i in $(SUBDIRS); do objects="$$objects $$i/*.@so_ext@"; done ; \
+ $(LINK)
delete-exports:
@if test -f $(TARGET_EXPORTS); then \
diff --git a/build/rules.mk.in b/build/rules.mk.in
index 133c24fc9..0b672aa26 100644
--- a/build/rules.mk.in
+++ b/build/rules.mk.in
@@ -83,10 +83,10 @@ LTFLAGS = --silent
#
# Basic macro setup
#
-COMPILE = $(CC) $(CPPFLAGS) $(INCLUDES) $(CFLAGS) $(OPTIM)
-LT_COMPILE = $(LIBTOOL) --mode=compile $(LTFLAGS) $(COMPILE) -c $< && touch $@
+COMPILE = $(CC) $(CPPFLAGS) $(CFLAGS) $(OPTIM) $(INCLUDES)
+LT_COMPILE = @lt_compile@
-LINK = $(LIBTOOL) --mode=link $(LTFLAGS) $(COMPILE) $(LDFLAGS) -o $@
+LINK = @link@
MKEXPORT = $(AWK) -f $(apr_builders)/make_export.awk
MKDEP = $(apr_builders)/mkdep.sh
diff --git a/configure.in b/configure.in
index a23e92a25..232b93b48 100644
--- a/configure.in
+++ b/configure.in
@@ -96,6 +96,26 @@ AC_PROG_LIBTOOL
;;
esac
+AC_ARG_WITH(libtool, [--with-libtool use libtool to link the library],
+ [ if test "$withval" = "yes"; then
+ lt_compile="\$(LIBTOOL) --mode=compile \$(LTFLAGS) \$(COMPILE) -c \$< && touch $@"
+ link="\$(LIBTOOL) --mode=link \$(LTFLAGS) \$(COMPILE) \$(LDFLAGS) -o \$@ -rpath \$(libdir) \$\$objects"
+ so_ext="lo"
+ lib_target="\$(libdir) \$\$objects"
+ else
+ lt_compile="\$(COMPILE) -c \$< && touch \$@"
+ link="ar cr \$(TARGET_LIB) \$\$objects; ranlib \$(TARGET_LIB)"
+ so_ext="o"
+ fi ], [
+ lt_compile="\$(LIBTOOL) --mode=compile \$(LTFLAGS) \$(COMPILE) -c \$< && touch $@"
+ link="\$(LIBTOOL) --mode=link \$(LTFLAGS) \$(COMPILE) \$(LDFLAGS) -o \$@"
+ so_ext="lo"
+ ] )
+AC_SUBST(lt_compile)
+AC_SUBST(link)
+AC_SUBST(so_ext)
+
+
dnl #----------------------------- Checks for compiler flags
nl='
'