You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@apr.apache.org by gs...@apache.org on 2004/02/05 11:16:27 UTC
cvs commit: apr-util/xml Makefile.in
gstein 2004/02/05 02:16:27
Modified: . .cvsignore Makefile.in buildconf configure.in
build apr_rules.mk.in
. .cvsignore Makefile.in buildconf configure.in
Added: . build.conf
build gen-build.py
. build.conf
build gen-uri-delims.py
Removed: atomic/os390 Makefile.in
atomic/unix Makefile.in
build Makefile.in
dso/aix Makefile.in
dso/beos Makefile.in
dso/os2 Makefile.in
dso/os390 Makefile.in
dso/unix Makefile.in
file_io/os2 Makefile.in
file_io/unix Makefile.in
locks/beos Makefile.in
locks/os2 Makefile.in
locks/unix Makefile.in
memory/unix Makefile.in
misc/unix Makefile.in
mmap/unix Makefile.in
network_io/beos Makefile.in
network_io/os2 Makefile.in
network_io/unix Makefile.in
passwd Makefile.in
poll/os2 Makefile.in
poll/unix Makefile.in
random/unix Makefile.in
shmem/beos Makefile.in
shmem/os2 Makefile.in
shmem/unix Makefile.in
strings Makefile.in
support/unix Makefile.in
tables Makefile.in
threadproc/beos Makefile.in
threadproc/os2 Makefile.in
threadproc/unix Makefile.in
time/unix Makefile.in
user/unix Makefile.in
buckets Makefile.in
crypto Makefile.in
dbm Makefile.in
dbm/sdbm Makefile.in
encoding Makefile.in
hooks Makefile.in
ldap Makefile.in
misc Makefile.in
strmatch Makefile.in
uri Makefile.in
xlate Makefile.in
xml Makefile.in
Log:
First whack at switching to a single top-level make. This adds a dependency
upon Python at packaging time, but not at end-user config/build time. As far
as I can tell, the build continues to function properly. (out-of-dir
config/make not tested, and apr-iconv prolly needs some work)
The buildconf scripts now generate a build-outputs.mk file which is included
by the root's Makefile (via the build/gen-build.py script). bulid-outputs.mk
specifies all of the various files present in the distribution.
The top-level Makefiles were simplified to use an $(OBJECTS) symbol rather
than 'find'ing them. Similarly, a $(HEADERS) symbol is used for the exports.
The corresponding delete-* targets were eliminated since we have a precise
set of inputs.
The subdirs' Makefiles were removed since they are no longer called/used.
The apr-util/uri Makefile was responsible for compiling a C program to
generate the uri_delims.h file. That process was replaced by a Python script
to generate the header (called by buildconf). The .c and .dsp were left for
the Windows build to continue, but that should be revamped.
build/apr_rules.mk was revamped somewhat to avoid recursion, but a lot of
cleanup is still needed. Much of the recursive/local/x- logic is no longer
needed and can be elimianated. rules.mk was created for inclusion by N
makefiles, but that isn't really true any more, so it could probably be
tossed (caveat: test/Makefile). Saved for a phase 2.
Some additional work was added to properly clean up files in */build/,
rather than relying on a makefile in there.
Revision Changes Path
1.18 +1 -0 apr/.cvsignore
Index: .cvsignore
===================================================================
RCS file: /home/cvs/apr/.cvsignore,v
retrieving revision 1.17
retrieving revision 1.18
diff -u -u -r1.17 -r1.18
--- .cvsignore 1 Feb 2004 16:42:44 -0000 1.17
+++ .cvsignore 5 Feb 2004 10:16:20 -0000 1.18
@@ -32,3 +32,4 @@
*.vcproj
autom4te.cache
ltcf-c.sh
+build-outputs.mk
1.92 +15 -40 apr/Makefile.in
Index: Makefile.in
===================================================================
RCS file: /home/cvs/apr/Makefile.in,v
retrieving revision 1.91
retrieving revision 1.92
diff -u -u -r1.91 -r1.92
--- Makefile.in 3 Feb 2004 10:08:20 -0000 1.91
+++ Makefile.in 5 Feb 2004 10:16:20 -0000 1.92
@@ -10,14 +10,14 @@
# Macros for supporting directories
#
INCDIR=./include
-INCDIR1=../include
-INCLUDES=-I$(INCDIR) -I$(INCDIR1)
+OSDIR=$(INCDIR)/arch/@OSDIR@
+DEFOSDIR=$(INCDIR)/arch/@DEFAULT_OSDIR@
+INCLUDES=-I$(INCDIR) -I$(OSDIR) -I$(DEFOSDIR)
#
# Macros for target determination
#
-SUBDIRS=@SUBDIRS@
-CLEAN_SUBDIRS= . test build
+CLEAN_SUBDIRS= test
INSTALL_SUBDIRS=@INSTALL_SUBDIRS@
TARGET_LIB = lib@APR_LIBNAME@.la
@@ -26,16 +26,18 @@
# Rules for building specific targets, starting with 'all' for
# building the entire package.
#
-TARGETS = delete-lib $(TARGET_LIB) delete-exports export_vars.h apr.exp
+TARGETS = $(TARGET_LIB) export_vars.h apr.exp
# bring in rules.mk for standard functionality
@INCLUDE_RULES@
+@INCLUDE_OUTPUTS@
CLEAN_TARGETS = apr-config.out apr.exp exports.c export_vars.h
DISTCLEAN_TARGETS = config.cache config.log config.status \
include/apr.h include/arch/unix/apr_private.h \
- libtool apr-config
-EXTRACLEAN_TARGETS = configure aclocal.m4 include/arch/unix/apr_private.h.in
+ libtool apr-config build/apr_rules.mk
+EXTRACLEAN_TARGETS = configure aclocal.m4 include/arch/unix/apr_private.h.in \
+ build-outputs.mk build/ltcf-c.sh build/ltmain.sh build/libtool.m4
prefix=@prefix@
exec_prefix=@exec_prefix@
@@ -48,17 +50,6 @@
top_srcdir=@apr_srcdir@
top_blddir=@apr_builddir@
-EXPORT_FILES = $(top_srcdir)/include/*.h
-
-delete-lib:
- @if test -f $(TARGET_LIB); then \
- 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) ; \
- $(RM) -f $(TARGET_LIB) ; \
- fi \
- fi
# Create apr-config script suitable for the install tree
apr-config.out: apr-config
@@ -102,27 +93,14 @@
done \
fi
-$(TARGET_LIB):
- @for i in $(SUBDIRS); do objects="$$objects $$i/*.@so_ext@"; done ; \
- tmpcmd="$(LINK) @lib_target@ $(ALL_LIBS)"; \
- echo $$tmpcmd; \
- $$tmpcmd && touch $@
-
-delete-exports:
- @if test -f apr.exp; then \
- headers="`find include/*.h -newer apr.exp`" ; \
- if test -n "$$headers"; then \
- echo Found newer headers. Will rebuild apr.exp. ; \
- echo $(RM) -f apr.exp exports.c export_vars.h ; \
- $(RM) -f apr.exp exports.c export_vars.h ; \
- fi \
- fi
+$(TARGET_LIB): $(OBJECTS)
+ $(LINK) @lib_target@ $(ALL_LIBS)
-exports.c:
- $(AWK) -f $(top_srcdir)/build/make_exports.awk $(EXPORT_FILES) > $@
+exports.c: $(HEADERS)
+ $(AWK) -f $(top_srcdir)/build/make_exports.awk $^ > $@
-export_vars.h:
- $(AWK) -f $(top_srcdir)/build/make_var_export.awk $(EXPORT_FILES) > $@
+export_vars.h: $(HEADERS)
+ $(AWK) -f $(top_srcdir)/build/make_var_export.awk $^ > $@
apr.exp: exports.c export_vars.h
@echo "#! lib@APR_LIBNAME@.so" > $@
@@ -142,6 +120,3 @@
# DO NOT REMOVE
docs: $(INCDIR)/*.h
-
-.PHONY: delete-lib delete-exports
-.NOTPARALLEL: delete-lib delete-exports
1.28 +3 -0 apr/buildconf
Index: buildconf
===================================================================
RCS file: /home/cvs/apr/buildconf,v
retrieving revision 1.27
retrieving revision 1.28
diff -u -u -r1.27 -r1.28
--- buildconf 15 Jan 2004 14:12:58 -0000 1.27
+++ buildconf 5 Feb 2004 10:16:20 -0000 1.28
@@ -118,4 +118,7 @@
# Remove autoconf 2.5x's cache directory
rm -rf autom4te*.cache
+echo "Generating 'make' outputs ..."
+build/gen-build.py make
+
exit 0
1.568 +12 -41 apr/configure.in
Index: configure.in
===================================================================
RCS file: /home/cvs/apr/configure.in,v
retrieving revision 1.567
retrieving revision 1.568
diff -u -u -r1.567 -r1.568
--- configure.in 1 Feb 2004 16:42:44 -0000 1.567
+++ configure.in 5 Feb 2004 10:16:20 -0000 1.568
@@ -178,15 +178,15 @@
[ use_libtool=$withval ], [ use_libtool="yes" ] )
if test "x$use_libtool" = "xyes"; then
- lt_compile='$(LIBTOOL) $(LTFLAGS) --mode=compile $(COMPILE) -c $< && touch $@'
+ lt_compile='$(LIBTOOL) $(LTFLAGS) --mode=compile $(COMPILE) -o $@ -c $< && touch $@'
LT_VERSION="-version-info `$get_version libtool $version_hdr APR`"
link="\$(LIBTOOL) \$(LTFLAGS) --mode=link \$(LT_LDFLAGS) \$(COMPILE) ${LT_VERSION} \$(ALL_LDFLAGS) -o \$@"
so_ext='lo'
- lib_target='-rpath $(libdir) $$objects'
- export_lib_target='-rpath \$(libdir) \$\$objects'
+ lib_target='-rpath $(libdir) $(OBJECTS)'
+ export_lib_target='-rpath \$(libdir) \$(OBJECTS)'
else
- lt_compile='$(COMPILE) -c $<'
- link='$(AR) cr $(TARGET_LIB) $$objects; $(RANLIB) $(TARGET_LIB)'
+ lt_compile='$(COMPILE) -o $@ -c $<'
+ link='$(AR) cr $(TARGET_LIB) $(OBJECTS); $(RANLIB) $(TARGET_LIB)'
so_ext='o'
lib_target=''
export_lib_target=''
@@ -1873,24 +1873,10 @@
AC_SUBST(LIBTOOL_LIBS)
echo "${nl}Construct Makefiles and header files."
-MAKEFILE1="Makefile strings/Makefile passwd/Makefile tables/Makefile build/Makefile"
-SUBDIRS="strings passwd tables "
-for dir in $apr_modules
-do
- test -d $dir || $MKDIR $dir
- if test -f $srcdir/$dir/$OSDIR/Makefile.in; then
- MAKEFILE2="$MAKEFILE2 $dir/$OSDIR/Makefile "
- SUBDIRS="$SUBDIRS $dir/$OSDIR "
- else
- MAKEFILE2="$MAKEFILE2 $dir/$DEFAULT_OSDIR/Makefile "
- SUBDIRS="$SUBDIRS $dir/$DEFAULT_OSDIR "
- fi
-done
-
+MAKEFILES="Makefile"
if test -d $srcdir/test; then
- MAKEFILE3="test/Makefile test/internal/Makefile"
+ MAKEFILES="$MAKEFILES test/Makefile test/internal/Makefile"
fi
-AC_SUBST(SUBDIRS)
#
# BSD/OS (BSDi) needs to use a different include syntax in the Makefiles
@@ -1900,16 +1886,20 @@
# Check whether they've installed GNU make
if make --version > /dev/null 2>&1; then
INCLUDE_RULES="include $apr_buildout/apr_rules.mk"
+ INCLUDE_OUTPUTS="include build-outputs.mk"
else
# BSDi make
INCLUDE_RULES=".include \"$apr_buildout/apr_rules.mk\""
+ INCLUDE_OUTPUTS=".include \"build-outputs.mk\""
fi
;;
*)
INCLUDE_RULES="include $apr_buildout/apr_rules.mk"
+ INCLUDE_OUTPUTS="include build-outputs.mk"
;;
esac
AC_SUBST(INCLUDE_RULES)
+AC_SUBST(INCLUDE_OUTPUTS)
SAVE_FILES="include/apr.h include/arch/unix/apr_private.h"
@@ -1921,7 +1911,7 @@
test -d $dir || $MKDIR $dir
AC_OUTPUT([
- $MAKEFILE1 $MAKEFILE2 $MAKEFILE3
+ $MAKEFILES
include/apr.h
build/apr_rules.mk
apr-config
@@ -1935,22 +1925,3 @@
done
chmod +x apr-config
])
-
-dnl ----------------------------- Fixup Makefiles for VPATH support
-
-changequote({,})
-
-if test -n "$USE_VPATH"; then
- for makefile in $MAKEFILE1 $MAKEFILE2 $MAKEFILE3; do
- cat $makefile | \
- sed \
- -e 's#-I\($(INCDIR[0-9]*)\)#-I\1 -I$(srcdir)/\1#g' \
- -e 's#-I\($(OSDIR[0-9]*)\)#-I\1 -I$(srcdir)/\1#g' \
- -e 's#-I\($(DEFOSDIR[0-9]*)\)#-I\1 -I$(srcdir)/\1#g' \
- > tmp
- cp tmp $makefile
- done
- rm -f tmp
-fi
-
-changequote([,])
1.1 apr/build.conf
Index: build.conf
===================================================================
#
# Configuration file for APR. Used by APR/build/gen-build.py
#
[options]
paths =
atomic/{platform}/*.c
dso/{platform}/*.c
file_io/{platform}/*.c
locks/{platform}/*.c
memory/{platform}/*.c
misc/{platform}/*.c
mmap/{platform}/*.c
network_io/{platform}/*.c
passwd/*.c
poll/{platform}/*.c
random/{platform}/*.c
shmem/{platform}/*.c
strings/*.c
support/{platform}/*.c
tables/*.c
threadproc/{platform}/*.c
time/{platform}/*.c
user/{platform}/*.c
headers = include/*.h
# aplibtool is manually built by the configure process
# build/aplibtool.c
# we have a recursive makefile for the test files (for now)
# test/*.c
1.2 +14 -7 apr/build/apr_rules.mk.in
Index: apr_rules.mk.in
===================================================================
RCS file: /home/cvs/apr/build/apr_rules.mk.in,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -u -r1.1 -r1.2
--- apr_rules.mk.in 4 Feb 2003 20:56:16 -0000 1.1
+++ apr_rules.mk.in 5 Feb 2004 10:16:21 -0000 1.2
@@ -140,9 +140,9 @@
all-recursive depend-recursive:
@otarget=`echo $@ | sed s/-recursive//`; \
- list='$(SUBDIRS)'; \
+ list='$(SOURCE_DIRS)'; \
for i in $$list; do \
- if test -d "$$i"; then \
+ if test -f "$$i/Makefile"; then \
target="$$otarget"; \
echo "Making $$target in $$i"; \
if test "$$i" = "."; then \
@@ -161,9 +161,9 @@
clean-recursive distclean-recursive extraclean-recursive:
@otarget=`echo $@ | sed s/-recursive//`; \
- list='$(SUBDIRS) $(CLEAN_SUBDIRS)'; \
+ list='$(CLEAN_SUBDIRS)'; \
for i in $$list; do \
- if test -d "$$i"; then \
+ if test -f "$$i/Makefile"; then \
target="$$otarget"; \
echo "Making $$target in $$i"; \
if test "$$i" = "."; then \
@@ -182,10 +182,17 @@
# autoconf 2.5x is creating a 'autom4te.cache' directory
# In case someone ran autoconf by hand, get rid of that directory
-# aswell.
+# as well.
local-clean: x-local-clean
- $(RM) -f *.o *.lo *.a *.la *.so *.obj $(CLEAN_TARGETS) $(PROGRAMS)
- $(RM) -rf .libs autom4te.cache
+ @list='. $(SOURCE_DIRS)'; \
+ for i in $$list; do \
+ echo $(RM) -f $$i/*.o $$i/*.lo $$i/*.a $$i/*.la $$i/*.so $$i/*.obj; \
+ $(RM) -f $$i/*.o $$i/*.lo $$i/*.a $$i/*.la $$i/*.so $$i/*.obj; \
+ echo $(RM) -rf $$i/.libs; \
+ $(RM) -rf $$i/.libs; \
+ done
+ $(RM) -f $(CLEAN_TARGETS) $(PROGRAMS)
+ $(RM) -rf autom4te.cache
local-distclean: local-clean x-local-distclean
$(RM) -f Makefile $(DISTCLEAN_TARGETS)
1.1 apr/build/gen-build.py
Index: gen-build.py
===================================================================
#!/usr/bin/env python
#
# USAGE: gen-build.py TYPE
#
# where TYPE is one of: make, dsp, vcproj
#
# It reads build.conf from the current directory, and produces its output
# into the current directory.
#
import os
import ConfigParser
import getopt
import string
import glob
import re
#import ezt
def main():
parser = ConfigParser.ConfigParser()
parser.read('build.conf')
dirs = { }
files = get_files(parser.get('options', 'paths'))
headers = get_files(parser.get('options', 'headers'))
# compute the relevant headers, along with the implied includes
legal_deps = map(os.path.basename, headers)
h_deps = { }
for fname in headers:
h_deps[os.path.basename(fname)] = extract_deps(fname, legal_deps)
resolve_deps(h_deps)
f = open('build-outputs.mk', 'w')
f.write('# DO NOT EDIT. AUTOMATICALLY GENERATED.\n\n')
objects = [ ]
for file in files:
assert file[-2:] == '.c'
obj = file[:-2] + '.lo'
objects.append(obj)
dirs[os.path.dirname(file)] = None
# what headers does this file include, along with the implied headers
deps = extract_deps(file, legal_deps)
for hdr in deps.keys():
deps.update(h_deps.get(hdr, {}))
f.write('%s: %s %s\n' % (obj, file, string.join(deps.keys(), ' ')))
f.write('\nOBJECTS = %s\n\n' % string.join(objects))
f.write('HEADERS = %s\n\n' % string.join(headers))
f.write('SOURCE_DIRS = %s\n\n' % string.join(dirs.keys()))
def extract_deps(fname, legal_deps):
"Extract the headers this file includes."
deps = { }
for line in open(fname).readlines():
if line[:8] != '#include':
continue
inc = _re_include.match(line).group(1)
if inc in legal_deps:
deps[inc] = None
return deps
_re_include = re.compile('#include *["<](.*)[">]')
def resolve_deps(header_deps):
"Alter the provided dictionary to flatten includes-of-includes."
altered = 1
while altered:
altered = 0
for hdr, deps in header_deps.items():
print hdr, deps
start = len(deps)
for dep in deps.keys():
deps.update(header_deps.get(dep, {}))
if len(deps) != start:
altered = 1
def get_files(patterns):
patterns = string.replace(patterns, '{platform}', get_platform())
patterns = string.split(string.strip(patterns))
files = [ ]
for pat in patterns:
files.extend(glob.glob(pat))
return files
def get_platform():
return 'unix'
if __name__ == '__main__':
main()
1.18 +1 -0 apr-util/.cvsignore
Index: .cvsignore
===================================================================
RCS file: /home/cvs/apr-util/.cvsignore,v
retrieving revision 1.17
retrieving revision 1.18
diff -u -u -r1.17 -r1.18
--- .cvsignore 12 Nov 2003 22:24:34 -0000 1.17
+++ .cvsignore 5 Feb 2004 10:16:25 -0000 1.18
@@ -33,3 +33,4 @@
*.sto
*.vcproj
autom4te.cache
+build-outputs.mk
1.79 +14 -39 apr-util/Makefile.in
Index: Makefile.in
===================================================================
RCS file: /home/cvs/apr-util/Makefile.in,v
retrieving revision 1.78
retrieving revision 1.79
diff -u -u -r1.78 -r1.79
--- Makefile.in 3 Feb 2004 09:56:01 -0000 1.78
+++ Makefile.in 5 Feb 2004 10:16:25 -0000 1.79
@@ -17,20 +17,23 @@
TARGET_LIB = lib@APRUTIL_LIBNAME@.la
INSTALL_SUBDIRS = @APR_XML_DIR@
-TARGETS = delete-lib $(TARGET_LIB) delete-exports aprutil.exp export_vars.h
+TARGETS = $(TARGET_LIB) aprutil.exp export_vars.h
# bring in rules.mk for standard functionality
@INCLUDE_RULES@
+@INCLUDE_OUTPUTS@
-SUBDIRS = buckets crypto dbm encoding hooks ldap uri xml misc strmatch xlate
-CLEAN_SUBDIRS = . test
+CLEAN_SUBDIRS = test
CLEAN_TARGETS = exports.c export_vars.h aprutil.exp
DISTCLEAN_TARGETS = config.cache config.log config.status libtool \
include/private/apu_config.h include/private/apu_private.h \
include/private/apu_select_dbm.h include/apr_ldap.h include/apu.h \
- export_vars.sh apu-config
-EXTRACLEAN_TARGETS = configure aclocal.m4 include/private/apu_config.h.in
+ export_vars.sh apu-config build/rules.mk
+EXTRACLEAN_TARGETS = configure aclocal.m4 include/private/apu_config.h.in \
+ exports.c export_vars.h uri/uri_delims.h build-outputs.mk \
+ build/apr_common.m4 build/find_apr.m4 build/install.sh \
+ build/config.guess build/config.sub
prefix=@prefix@
exec_prefix=@exec_prefix@
@@ -40,17 +43,6 @@
top_srcdir=@abs_srcdir@
top_blddir=@abs_builddir@
-EXPORT_FILES = $(top_srcdir)/include/*.h
-
-delete-lib:
- @if test -f $(TARGET_LIB); then \
- objects="`find $(SUBDIRS) -name expat -prune -o -name '*.@so_ext@' -a -newer $(TARGET_LIB) -print`" ; \
- if test -n "$$objects"; then \
- echo Found newer objects. Will relink $(TARGET_LIB). ; \
- echo $(RM) -f $(TARGET_LIB) ; \
- $(RM) -f $(TARGET_LIB) ; \
- fi; \
- fi
install: $(TARGET_LIB)
if [ ! -d $(DESTDIR)$(includedir) ]; then \
@@ -75,27 +67,14 @@
$(LIBTOOL) --mode=install cp apu-config $(DESTDIR)$(bindir)
chmod 755 $(DESTDIR)$(bindir)/apu-config
-$(TARGET_LIB):
- @objects="`find $(SUBDIRS) -name expat -prune -o -name 'gen_uri_delims.@so_ext@' -prune -o -name '*.@so_ext@' -print`"; \
- tmpcmd="$(LINK) @lib_target@ @EXTRA_OS_LINK@"; \
- echo $$tmpcmd; \
- $$tmpcmd && touch $@
-
-delete-exports:
- @if test -f aprutil.exp; then \
- headers="`find include/*.h -newer aprutil.exp -print`" ; \
- if test -n "$$headers"; then \
- echo Found newer headers. Will rebuild aprutil.exp. ; \
- echo $(RM) -f aprutil.exp exports.c export_vars.h ; \
- $(RM) -f aprutil.exp exports.c export_vars.h; \
- fi \
- fi
+$(TARGET_LIB): $(OBJECTS)
+ $(LINK) @lib_target@ $(ALL_LIBS)
-exports.c:
- $(AWK) -f @APR_SOURCE_DIR@/build/make_exports.awk $(EXPORT_FILES) > $@
+exports.c: $(HEADERS)
+ $(AWK) -f @APR_SOURCE_DIR@/build/make_exports.awk $^ > $@
-export_vars.h:
- $(AWK) -f @APR_SOURCE_DIR@/build/make_var_export.awk $(EXPORT_FILES) > $@
+export_vars.h: $(HEADERS)
+ $(AWK) -f @APR_SOURCE_DIR@/build/make_var_export.awk $^ > $@
aprutil.exp: exports.c export_vars.h
@echo "#! libaprutil.so" > $@
@@ -109,7 +88,3 @@
check: $(TARGET_LIB)
(cd test && $(MAKE) check)
-
-
-.PHONY: delete-lib delete-exports
-.NOTPARALLEL: delete-lib delete-exports
1.11 +13 -0 apr-util/buildconf
Index: buildconf
===================================================================
RCS file: /home/cvs/apr-util/buildconf,v
retrieving revision 1.10
retrieving revision 1.11
diff -u -u -r1.10 -r1.11
--- buildconf 3 Feb 2004 10:32:32 -0000 1.10
+++ buildconf 5 Feb 2004 10:16:25 -0000 1.11
@@ -59,6 +59,19 @@
fi
#
+# Generate the URI delimiter table
+#
+### this is so stupidly static, that I'm not sure why we generate it...
+echo "Generating uri_delims.h ..."
+build/gen-uri-delims.py > uri/uri_delims.h
+
+#
+# Generate build-outputs.mk for the build systme
+#
+echo "Generating 'make' outputs ..."
+$apr_src_dir/build/gen-build.py make
+
+#
# If Expat has been bundled, then go and configure the thing
#
if test -d xml/expat; then
1.72 +5 -1 apr-util/configure.in
Index: configure.in
===================================================================
RCS file: /home/cvs/apr-util/configure.in,v
retrieving revision 1.71
retrieving revision 1.72
diff -u -u -r1.71 -r1.72
--- configure.in 16 Nov 2003 23:00:45 -0000 1.71
+++ configure.in 5 Feb 2004 10:16:25 -0000 1.72
@@ -166,15 +166,19 @@
# Check whether they've installed GNU make
if make --version > /dev/null 2>&1; then
INCLUDE_RULES="include $abs_builddir/build/rules.mk"
+ INCLUDE_OUTPUTS="include build-outputs.mk"
else
INCLUDE_RULES=".include \"$abs_builddir/build/rules.mk\""
+ INCLUDE_OUTPUTS=".include \"build-outputs.mk\""
fi
;;
*)
INCLUDE_RULES="include $abs_builddir/build/rules.mk"
+ INCLUDE_OUTPUTS="include build-outputs.mk"
;;
esac
AC_SUBST(INCLUDE_RULES)
+AC_SUBST(INCLUDE_OUTPUTS)
if test -d ./test; then
test_Makefile="test/Makefile"
@@ -187,7 +191,7 @@
dnl
dnl everthing is done.
-MAKEFILES="Makefile buckets/Makefile crypto/Makefile dbm/Makefile dbm/sdbm/Makefile encoding/Makefile hooks/Makefile ldap/Makefile uri/Makefile xml/Makefile misc/Makefile strmatch/Makefile xlate/Makefile $test_Makefile"
+MAKEFILES="Makefile $test_Makefile"
AC_OUTPUT([
export_vars.sh
apu-config
1.1 apr-util/build.conf
Index: build.conf
===================================================================
#
# Configuration file for APRUTIL. Used by APR/build/gen-build.py
#
[options]
paths =
buckets/*.c
crypto/*.c
dbm/*.c
dbm/sdbm/*.c
encoding/*.c
hooks/*.c
ldap/*.c
misc/*.c
uri/apr_uri.c
xml/*.c
strmatch/*.c
xlate/*.c
headers = include/*.h
# gen_uri_delim.c
# we have a recursive makefile for the test files (for now)
# test/*.c
1.1 apr-util/build/gen-uri-delims.py
Index: gen-uri-delims.py
===================================================================
#!/usr/bin/env python
#
# generates a table of 256 values, where certain characters are
# marked "interesting" for the uri parsing process.
#
# USAGE:
# $ gen-uri-delims.py > uri/uri_delims.h
#
# typically invoked by the "buildconf" script
#
import sys
import string
write = sys.stdout.write
write('/* this file is automatically generated by gen-uri-delims.py, '
'do not edit */\n')
write('static const unsigned char uri_delims[256] = {')
values = [ '0' ] * 256
values[ord(':')] = 'T_COLON'
values[ord('/')] = 'T_SLASH'
values[ord('?')] = 'T_QUESTION'
values[ord('#')] = 'T_HASH'
values[0] = 'T_NUL'
while values:
write('\n %s' % string.join(values[:20], ','))
del values[:20]
if values:
write(',')
write('\n};\n')
Re: cvs commit: apr-util/xml Makefile.in
Posted by Greg Stein <gs...@lyra.org>.
On Thu, Feb 05, 2004 at 11:29:59AM +0000, Joe Orton wrote:
>...
> Very nice! It doesn't seem to work however :) The dependencies are
> missing "include/" in the header filenames in build-outputs.mk:
hehe... sorry about that. I put in the header dependency more or less "at
the last moment." It looked okay, so I committed. Obviously, I never did a
test build after that :-( (all the prior builds were going so well...)
>...
> something like this fixes it for me (and also the HEADERS definitions to
> fix exports.c generation in a VPATH build), maybe there is a prettier
> way to do it:
Good enough for now. Thanks! (not sure if there is anything better;
nothing immediately obvious)
Cheers,
-g
--
Greg Stein, http://www.lyra.org/
Re: cvs commit: apr-util/xml Makefile.in
Posted by Joe Orton <jo...@manyfish.co.uk>.
On Thu, Feb 05, 2004 at 09:40:30AM -0800, Justin Erenkrantz wrote:
> --On Thursday, February 5, 2004 11:29 AM +0000 Joe Orton
> <jo...@manyfish.co.uk> wrote:
>
> >something like this fixes it for me (and also the HEADERS definitions to
> >fix exports.c generation in a VPATH build), maybe there is a prettier
> >way to do it:
>
> *pfft* pretty. Works for me. Please commit. -- justin
:) 'tis done.
Re: cvs commit: apr-util/xml Makefile.in
Posted by Justin Erenkrantz <ju...@erenkrantz.com>.
--On Thursday, February 5, 2004 11:29 AM +0000 Joe Orton <jo...@manyfish.co.uk>
wrote:
> something like this fixes it for me (and also the HEADERS definitions to
> fix exports.c generation in a VPATH build), maybe there is a prettier
> way to do it:
*pfft* pretty. Works for me. Please commit. -- justin
Re: cvs commit: apr-util/xml Makefile.in
Posted by Joe Orton <jo...@manyfish.co.uk>.
On Thu, Feb 05, 2004 at 10:16:27AM -0000, Greg Stein wrote:
> gstein 2004/02/05 02:16:27
>
> Modified: . .cvsignore Makefile.in buildconf configure.in
> build apr_rules.mk.in
> . .cvsignore Makefile.in buildconf configure.in
> Added: . build.conf
> build gen-build.py
> . build.conf
> build gen-uri-delims.py
> Removed: atomic/os390 Makefile.in
> atomic/unix Makefile.in
> build Makefile.in
> dso/aix Makefile.in
Very nice! It doesn't seem to work however :) The dependencies are
missing "include/" in the header filenames in build-outputs.mk:
atomic/unix/apr_atomic.lo: atomic/unix/apr_atomic.c apr.h apr_general.h
something like this fixes it for me (and also the HEADERS definitions to
fix exports.c generation in a VPATH build), maybe there is a prettier
way to do it:
Index: build/gen-build.py
===================================================================
RCS file: /home/cvs/apr/build/gen-build.py,v
retrieving revision 1.1
diff -u -r1.1 gen-build.py
--- build/gen-build.py 5 Feb 2004 10:16:21 -0000 1.1
+++ build/gen-build.py 5 Feb 2004 11:26:48 -0000
@@ -50,10 +50,10 @@
for hdr in deps.keys():
deps.update(h_deps.get(hdr, {}))
- f.write('%s: %s %s\n' % (obj, file, string.join(deps.keys(), ' ')))
+ f.write('%s: %s include/%s\n' % (obj, file, string.join(deps.keys(), ' include/')))
f.write('\nOBJECTS = %s\n\n' % string.join(objects))
- f.write('HEADERS = %s\n\n' % string.join(headers))
+ f.write('HEADERS = $(top_srcdir)/%s\n\n' % string.join(headers, ' $(top_srcdir)/'))
f.write('SOURCE_DIRS = %s\n\n' % string.join(dirs.keys()))