You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@subversion.apache.org by Kevin Pilch-Bisson <ke...@pilch-bisson.net> on 2001/09/01 12:48:55 UTC
Re: Build System fixes
On Fri, Aug 31, 2001 at 02:23:30PM -0700, Greg Stein wrote:
> On Fri, Aug 31, 2001 at 11:21:26AM -0400, Kevin Pilch-Bisson wrote:
> >...
> > 1) I used my previously explained approach, which gstein expressed discomfort
> > about. Is that a veto-ing discomfort or should I check it in?
>
> I never saw a patch, so it is hard to know...
See the end of this mail for a patch.
>
> > 2) With Berkeley DB 3.3.11, the build db in tree doesn't work without changing
> > the libs line in ac-helpers/berkeley-db.m4 to:
> > LIBS="$LIBS -L$dbdir/.libs -ldb-3.3"
> > from
> > LIBS="$LIBS -L$dbdir -ldb"
> >
> > This is because libdb.so is not created until install time. Is this change
> > okay with everyone?
>
> Nope :-) ... link against the .la file, rather than using -ldb. Peeking into
> the .libs directory is troublesome.
>
> Hmm. But then again, libtool 1.3 is kinda busted in that respect. I'd say to
> go ahead with the above, but leave a comment in there about fixing it when
> we move to libtool 1.4.
>
I haven't tried putting the .la on the command line. More specifically I was
talking about the fact that the 3.3 was explicitly included on the command line.
--
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Kevin Pilch-Bisson http://www.pilch-bisson.net
"Historically speaking, the presences of wheels in Unix
has never precluded their reinvention." - Larry Wall
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Index: Makefile.in
===================================================================
--- SVN/text-base/Makefile.in Fri Aug 31 09:50:56 2001
+++ Makefile.in Fri Aug 31 13:54:51 2001
@@ -21,8 +21,11 @@
prefix = @prefix@
exec_prefix = @exec_prefix@
libdir = @libdir@
+fs_libdir= @libdir@
sbindir = @sbindir@
+fs_sbindir=@sbindir@
bindir = @bindir@
+fs_bindir=@bindir@
includedir = @includedir@
### should search for these...
@@ -50,6 +53,11 @@
APACHE_TARGET = @APACHE_TARGET@
INSTALL_APACHE_RULE = @INSTALL_APACHE_RULE@
+INSTALL_RULES = @INSTALL_RULES@
+
+TEST_DEPS = $(NON_FS_TEST_DEPS) @FS_TEST_DEPS@
+TEST_PROGRAMS = $(NON_FS_TEST_PROGRAMS) @FS_TEST_PROGRAMS@
+
MKDIR = @MKDIR@
CFLAGS = @CFLAGS@
@@ -65,8 +73,11 @@
INSTALL = @INSTALL@
INSTALL_LIB = $(LIBTOOL) --mode=install $(INSTALL)
+INSTALL_FS_LIB = $(INSTALL_LIB)
INSTALL_BIN = $(LIBTOOL) --mode=install $(INSTALL)
+INSTALL_FS_BIN = $(INSTALL_BIN)
INSTALL_SBIN = $(LIBTOOL) --mode=install $(INSTALL)
+INSTALL_FS_SBIN = $(INSTALL_SBIN)
INSTALL_INCLUDE = $(INSTALL) -m 644
INSTALL_MOD_SHARED = @APXS@ -i -a
INSTALL_MOD_STATIC = $(INSTALL) -m 644
@@ -81,7 +92,7 @@
@INCLUDE_OUTPUTS@
-local-all: libs programs @FS_RULES@ @BUILD_APACHE_RULE@
+local-all: @BUILD_RULES@ @BUILD_APACHE_RULE@
local-clean: doc-clean
@list='$(BUILD_DIRS)'; for i in $$list; do \
@@ -100,7 +111,7 @@
ac-helpers/libtool.m4 ac-helpers/ltconfig \
ac-helpers/ltmain.sh
-local-install: install-lib install-include install-bin $(INSTALL_APACHE_RULE)
+local-install: $(INSTALL_RULES) $(INSTALL_APACHE_RULE)
### the chmod really sucks, but some repository files don't have it like
### they should ...
@@ -149,14 +160,19 @@
echo "------ completed $$target in $$i"; \
done;
-### temporary hack. Neon does not have an "extraclean"
+### temporary hack. Neon does not have an "extraclean" and neither does db
+### If we don't have extraclean -- do the next best thing.
external-extraclean:
@list='$(EXTERNAL_PROJECT_DIRS)'; \
for i in $$list; do \
- if test "$$i" != "neon"; then \
- echo "------ making extraclean in $$i"; \
- (cd $$i && $(MAKE) extraclean) || exit 1; \
- echo "------ completed extraclean in $$i"; \
+ if test "$$i" != "neon" && test "$$i" != "db/dist"; then \
+ echo "------ making extraclean in $$i"; \
+ (cd $$i && $(MAKE) extraclean) || exit 1; \
+ echo "------ completed extraclean in $$i"; \
+ else \
+ echo "------ making distclean(no extraclean) in $$i"; \
+ (cd $$i && $(MAKE) distclean) || exit 1; \
+ echo "------ completed distclean(no extraclean) in $$i"; \
fi; \
done;
Index: build.conf
===================================================================
--- SVN/text-base/build.conf Fri Aug 31 09:50:56 2001
+++ build.conf Fri Aug 31 10:03:00 2001
@@ -25,6 +25,9 @@
subversion/tests/clients/cmdline/xmltests/*.sh
# bourne: test target condensation in libsvn_subr
subversion/tests/libsvn_subr/target-test.sh
+
+[fs-test-scripts]
+paths =
# C: test both external and internal APIs of libsvn_fs
subversion/tests/libsvn_fs/run-fs-tests.sh
# C: test svn_repos_update() in libsvn_repos
@@ -41,7 +44,6 @@
subversion/tests/clients/cmdline/svnadmin_tests.py
-
# ----------------------------------------------------------------------------
#
# BUILD TARGETS
@@ -51,7 +53,6 @@
[svn]
type = exe
path = subversion/clients/cmdline
-group = programs
libs = libsvn_client libsvn_wc libsvn_ra libsvn_delta libsvn_subr
$(SVN_APR_LIBS) libexpat
@@ -59,40 +60,37 @@
[svnadmin]
type = exe
path = subversion/svnadmin
-group = fs-programs
+install = fs-bin
libs = libsvn_repos libsvn_fs libsvn_delta libsvn_subr $(SVN_APR_LIBS) libexpat
# The subversion repository inspection tool
[svnlook]
type = exe
path = subversion/svnlook
-group = fs-programs
+install = fs-bin
libs = libsvn_repos libsvn_fs libsvn_delta libsvn_subr $(SVN_APR_LIBS) libexpat
# Library needed by all subversion clients
[libsvn_client]
type = lib
path = subversion/libsvn_client
-group = libs
# Routines for binary diffing and tree-deltas
[libsvn_delta]
type = lib
path = subversion/libsvn_delta
-group = libs
# The repository filesystem library
[libsvn_fs]
type = lib
path = subversion/libsvn_fs
-group = fs-libs
+install = fs-lib
libs = $(SVN_DB_LIBS)
# General API for accessing repositories
[libsvn_ra]
type = lib
path = subversion/libsvn_ra
-group = libs
# conditionally link in some more libs
libs = $(SVN_RA_LIB_LINK)
# conditionally add more dependencies
@@ -102,7 +100,6 @@
[libsvn_ra_dav]
type = lib
path = subversion/libsvn_ra_dav
-group = libs
### hack to deal with libtool's busted intra-library dependencies
libs = -L$(abs_builddir)/neon/src/.libs -lneon
@@ -110,32 +107,29 @@
[libsvn_ra_local]
type = lib
path = subversion/libsvn_ra_local
-group = fs-libs
+install = fs-lib
libs = libsvn_repos libsvn_fs libsvn_delta libsvn_subr
# Routines built on top of libsvn_fs
[libsvn_repos]
type = lib
path = subversion/libsvn_repos
-group = fs-libs
+install = fs-lib
# Low-level grab bag of utilities
[libsvn_subr]
type = lib
path = subversion/libsvn_subr
-group = libs
# Working copy management lib
[libsvn_wc]
type = lib
path = subversion/libsvn_wc
-group = libs
# Subversion plugin for Apache's mod_dav
[libmod_dav_svn]
type = lib
path = subversion/mod_dav_svn
-group = apache-mods
libs = libsvn_repos libsvn_fs libsvn_delta libsvn_subr
# we don't need the .so version stuff for an Apache module, so avoid them
link-flags = -avoid-version
@@ -147,7 +141,6 @@
[libexpat]
type = lib
path = expat-lite
-group = libs
# there are some .c files included by others, so *.c isn't appropriate
sources = hashtable.c xmlparse.c xmlrole.c xmltok.c
@@ -162,23 +155,20 @@
path = subversion/tests
sources = svn_tests_main.c svn_test_editor.c
install = test
-group = libs
# shared utils for writing fs tests
[libsvn_test_fs]
type = lib
path = subversion/tests
sources = fs-helpers.c
-install = test
-group = fs-libs
+install = fs-test
# tests for *public* fs API (svn_fs.h)
[fs-test]
type = exe
path = subversion/tests/libsvn_fs
sources = fs-test.c
-install = test
-group = fs-programs
+install = fs-test
libs = libsvn_test libsvn_test_fs libsvn_fs libsvn_delta libsvn_subr
$(SVN_APR_LIBS) libexpat
# run-fs-tests.sh will run this for us
@@ -189,8 +179,7 @@
type = exe
path = subversion/tests/libsvn_fs
sources = skel-test.c
-install = test
-group = fs-programs
+install = fs-test
libs = libsvn_test libsvn_fs libsvn_delta libsvn_subr $(SVN_APR_LIBS) libexpat
# run-fs-tests.sh will run this for us
testing = skip
@@ -200,8 +189,7 @@
type = exe
path = subversion/tests/libsvn_fs
sources = key-test.c
-install = test
-group = fs-programs
+install = fs-test
libs = libsvn_test libsvn_fs libsvn_delta libsvn_subr $(SVN_APR_LIBS) libexpat
# run-fs-tests.sh will run this for us
testing = skip
@@ -211,8 +199,7 @@
type = exe
path = subversion/tests/libsvn_fs
sources = strings-reps-test.c
-install = test
-group = fs-programs
+install = fs-test
libs = libsvn_test libsvn_test_fs libsvn_fs libsvn_delta libsvn_subr
$(SVN_APR_LIBS) libexpat
# run-fs-tests.sh will run this for us
@@ -222,7 +209,6 @@
[md5args]
type = exe
path = subversion/tests/libsvn_repos
-group = programs
sources = md5args.c
install = test
libs = libsvn_subr $(SVN_APR_LIBS) libexpat
@@ -234,8 +220,7 @@
type = exe
path = subversion/tests/libsvn_repos
sources = repos-test.c dir-delta-editor.c
-install = test
-group = fs-programs
+install = fs-test
libs = libsvn_test libsvn_test_fs libsvn_repos libsvn_fs libsvn_delta
libsvn_subr $(SVN_APR_LIBS) libexpat
# run-repos-tests.sh will run this for us
@@ -247,7 +232,6 @@
path = subversion/tests/libsvn_subr
sources = hashdump-test.c
install = test
-group = programs
libs = libsvn_test libsvn_delta libsvn_subr $(SVN_APR_LIBS) libexpat
# test svn_stringbuf_t utilities
@@ -256,7 +240,6 @@
path = subversion/tests/libsvn_subr
sources = stringtest.c
install = test
-group = programs
libs = libsvn_test libsvn_delta libsvn_subr $(SVN_APR_LIBS) libexpat
# test path library
@@ -265,7 +248,6 @@
path = subversion/tests/libsvn_subr
sources = path-test.c
install = test
-group = programs
libs = libsvn_test libsvn_delta libsvn_subr $(SVN_APR_LIBS) libexpat
@@ -276,8 +258,7 @@
type = exe
path = subversion/tests/libsvn_ra_local
sources = ra-local-test.c
-install = test
-group = fs-programs
+install = fs-test
libs = libsvn_test libsvn_ra libsvn_fs libsvn_delta libsvn_subr
$(SVN_APR_LIBS) libexpat
# disabled for now, BROKEN.
@@ -292,7 +273,6 @@
path = subversion/tests/libsvn_delta
sources = random-test.c
install = test
-group = programs
libs = libsvn_delta libsvn_subr $(SVN_APR_LIBS) libexpat
# test svn_path_condense_targets()
@@ -301,7 +281,6 @@
path = subversion/tests/libsvn_subr
sources = target-test.c
install = test
-group = programs
libs = libsvn_subr $(SVN_APR_LIBS) libexpat
# target-test.sh will run this for us
testing = skip
@@ -312,7 +291,6 @@
path = subversion/tests/libsvn_delta
sources = xml-output-test.c
install = test
-group = programs
libs = libsvn_delta libsvn_subr $(SVN_APR_LIBS) libexpat
# this is really redundant with our XML svn-test*.sh tests.
testing = skip
@@ -323,7 +301,6 @@
path = subversion/tests/libsvn_wc
sources = checkout-test.c
install = test
-group = programs
libs = libsvn_wc libsvn_delta libsvn_subr $(SVN_APR_LIBS) libexpat
# this is really redundant with our XML svn-test*.sh tests.
testing = skip
@@ -334,7 +311,6 @@
path = subversion/tests/libsvn_wc
sources = commit-test.c
install = test
-group = programs
libs = libsvn_test libsvn_wc libsvn_delta libsvn_subr $(SVN_APR_LIBS) libexpat
# this is really redundant with our XML svn-test*.sh tests.
testing = skip
@@ -348,7 +324,6 @@
path = subversion/tests/libsvn_delta
sources = deltaparse-test.c
install = test
-group = programs
libs = libsvn_test libsvn_delta libsvn_subr $(SVN_APR_LIBS) libexpat
testing = skip
@@ -362,7 +337,6 @@
path = subversion/tests/libsvn_delta
sources = svndiff-test.c
install = test
-group = programs
libs = libsvn_delta libsvn_subr $(SVN_APR_LIBS) libexpat
testing = skip
@@ -372,7 +346,6 @@
path = subversion/tests/libsvn_delta
sources = vdelta-test.c
install = test
-group = programs
libs = libsvn_delta libsvn_subr $(SVN_APR_LIBS) libexpat
testing = skip
@@ -385,7 +358,7 @@
#[svn-design]
#type = doc
#path = doc
-#group = docs
+#install = doc
#sources = svn-design.texi
#deps = ...
Index: configure.in
===================================================================
--- SVN/text-base/configure.in Fri Aug 31 09:50:55 2001
+++ configure.in Fri Aug 31 13:15:45 2001
@@ -151,12 +151,22 @@
SVN_LIB_BERKELEY_DB($SVN_FS_WANT_DB_MAJOR, $SVN_FS_WANT_DB_MINOR,
$SVN_FS_WANT_DB_PATCH)
+INSTALL_RULES="install-lib install-bin"
+BUILD_RULES="lib bin test"
if test "$svn_lib_berkeley_db" = "yes"; then
- FS_RULES="fs-libs fs-programs"
+ BUILD_RULES="lib fs-lib bin fs-bin test fs-test"
+ INSTALL_RULES="install-lib install-fs-lib install-bin install-fs-bin"
+ FS_TEST_DEPS="\$(FS_TEST_DEPS)"
+ FS_TEST_PROGRAMS="\$(FS_TEST_PROGRAMS)"
fi
-AC_SUBST(FS_RULES)
+AC_SUBST(BUILD_RULES)
+AC_SUBST(INSTALL_RULES)
+AC_SUBST(FS_TEST_DEPS)
+AC_SUBST(FS_TEST_PROGRAMS)
AC_SUBST(SVN_DB_INCLUDES)
AC_SUBST(SVN_DB_LIBS)
AC_DEFINE_UNQUOTED(SVN_FS_WANT_DB_MAJOR, $SVN_FS_WANT_DB_MAJOR,
[The desired major version for the Berkeley DB])
Index: gen-make.py
===================================================================
--- SVN/text-base/gen-make.py Fri Aug 31 09:50:53 2001
+++ gen-make.py Fri Aug 31 11:53:28 2001
@@ -27,10 +27,11 @@
errors = 0
targets = { }
- groups = { } # group name -> targets
install = { } # install area name -> targets
test_progs = [ ]
test_deps = [ ]
+ fs_test_progs = [ ]
+ fs_test_deps = [ ]
file_deps = [ ]
target_dirs = { }
@@ -50,12 +51,6 @@
targets[target] = target_ob
- group = parser.get(target, 'group')
- if groups.has_key(group):
- groups[group].append(target_ob.output)
- else:
- groups[group] = [ target_ob.output ]
-
itype = target_ob.install
if install.has_key(itype):
install[itype].append(target_ob)
@@ -83,6 +78,11 @@
if parser.get(target, 'testing') != 'skip':
test_progs.append(tpath)
+ if target_ob.install == 'fs-test' and bldtype == 'exe':
+ fs_test_deps.append(tpath)
+ if parser.get(target, 'testing') != 'skip':
+ fs_test_progs.append(tpath)
+
pats = parser.get(target, 'sources')
if not pats:
pats = _default_sources[bldtype]
@@ -148,8 +149,12 @@
% (src[:-2], objext, src))
ofile.write('\n')
- for g_name, g_targets in groups.items():
- ofile.write('%s: %s\n\n' % (g_name, string.join(g_targets)))
+ for g_name, g_targets in install.items():
+ target_names = [ ]
+ for i in g_targets:
+ target_names.append(i.output)
+
+ ofile.write('%s: %s\n\n' % (g_name, string.join(target_names)))
ofile.write('BUILD_DIRS = %s\n' % string.join(target_dirs.keys()))
@@ -205,15 +210,15 @@
os.path.basename(file))))
ofile.write('\n')
- elif area != 'test':
+ elif area != 'test' and area != 'fs-test':
ofile.write('install-%s: %s\n'
'\t$(MKDIR) $(%sdir)\n'
- % (area, string.join(files), area))
+ % (area, string.join(files), string.replace(area, '-', '_')))
for file in files:
ofile.write('\t$(INSTALL_%s) %s %s\n'
- % (string.upper(area), file,
- os.path.join('$(%sdir)' % area,
- os.path.basename(file))))
+ % (string.replace(string.upper(area), '-', '_'), file,
+ string.replace(os.path.join('$(%sdir)' % area,
+ os.path.basename(file)), '-', '_')))
ofile.write('\n')
includes, i_errors = _collect_paths(parser.get('includes', 'paths'))
@@ -235,8 +240,15 @@
scripts, s_errors = _collect_paths(parser.get('test-scripts', 'paths'))
errors = errors or s_errors
- ofile.write('TEST_DEPS = %s\n\n' % string.join(test_deps + scripts))
- ofile.write('TEST_PROGRAMS = %s\n\n' % string.join(test_progs + scripts))
+ fs_scripts, fs_errors = _collect_paths(parser.get('fs-test-scripts', 'paths'))
+ errors = errors or fs_errors
+
+ ofile.write('FS_TEST_DEPS = %s\n\n' % string.join(fs_test_deps + fs_scripts))
+ ofile.write('FS_TEST_PROGRAMS = %s\n\n' %
+ string.join(fs_test_progs + fs_scripts))
+ ofile.write('NON_FS_TEST_DEPS = %s\n\n' % string.join(test_deps + scripts))
+ ofile.write('NON_FS_TEST_PROGRAMS = %s\n\n' %
+ string.join(test_progs + scripts))
if not skip_depends:
#
@@ -321,6 +333,7 @@
'includes',
'static-apache',
'test-scripts',
+ 'fs-test-scripts',
]
def _filter_targets(t):
Index: ac-helpers/berkeley-db.m4
===================================================================
--- ac-helpers/SVN/text-base/berkeley-db.m4 Fri Aug 31 09:53:18 2001
+++ ac-helpers/berkeley-db.m4 Sat Sep 1 08:26:39 2001
@@ -95,8 +95,10 @@
if test "$status" = "builtin"; then
# Use the include and lib files in the build dir.
dbdir=`cd db/dist ; pwd`
- CPPFLAGS="$CPPFLAGS -I$dbdir"
- LIBS="$LIBS -L$dbdir -ldb"
+ SVN_DB_INCLUDES="-I$dbdir"
+ # Note that once we upgrade to libtool 1.4 this should be changed to
+ # SVN_DB_LIBS="$dbdir/libdb-3.3.la"
+ SVN_DB_LIBS="-L$dbdir/.libs -ldb-3.3"
svn_lib_berkeley_db=yes
elif test "$status" = "skip"; then
svn_lib_berkeley_db=no
Index: ac-helpers/svn-apache.m4
===================================================================
--- ac-helpers/SVN/text-base/svn-apache.m4 Fri Aug 31 09:53:18 2001
+++ ac-helpers/svn-apache.m4 Fri Aug 31 09:57:32 2001
@@ -100,7 +100,7 @@
echo " --with-apxs or --with-apache must be used"
echo "=================================================================="
else
- BUILD_APACHE_RULE=apache-mods
+ BUILD_APACHE_RULE=apache-mod
fi
AC_SUBST(APACHE_TARGET)
AC_SUBST(APACHE_INCLUDES)