[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Patch to support building outside the srcdir.

From: Mo DeJong <mdejong_at_cygnus.com>
Date: 2000-12-16 07:39:57 CET

The attached patch allows one to build subversion
outside of the srcdir. This is really handy since
you can create builds for multiple CPU types or
with different optimizations levels from the same
source tree.

apr CVS has already been fixed to support this and
a patch to has been posted to the neon mailing list.
So while it does not work right now, it will work soon.

Mo DeJong
Red Hat Inc

Index: configure.in
===================================================================
RCS file: /cvs/subversion/configure.in,v
retrieving revision 1.44
diff -u -r1.44 configure.in
--- configure.in 2000/11/26 15:20:15 1.44
+++ configure.in 2000/12/16 06:28:38
@@ -37,8 +37,14 @@
   enable_subdir_config=yes)
 
 if test "$enable_subdir_config" = "yes"; then
+ # FIXME: This mkdir is a hack to work around a problem
+ # with the RUN_SUBDIR_CONFIG_NOW macro. It expects the
+ # srcdir to be the top of the apr directory. It fails
+ # if the $1 argument is not a directory in the build dir.
+ test -d apr || mkdir apr
   RUN_SUBDIR_CONFIG_NOW(apr)
   expat_absdir=`cd $srcdir/expat-lite ; pwd`
+ test -d neon || mkdir neon
   RUN_SUBDIR_CONFIG_NOW(neon, --with-expat=$expat_absdir/libexpat.la)
 fi
 
Index: subversion/client/Makefile.am
===================================================================
RCS file: /cvs/subversion/subversion/client/Makefile.am,v
retrieving revision 1.13
diff -u -r1.13 Makefile.am
--- subversion/client/Makefile.am 2000/11/16 21:23:41 1.13
+++ subversion/client/Makefile.am 2000/12/16 06:28:38
@@ -7,7 +7,8 @@
               update-cmd.c propget-cmd.c propset-cmd.c
 
 ## Flags needed when compiling:
-INCLUDES = -I. -I../include -I../../apr/include -I../../expat-lite
+INCLUDES = -I$(top_srcdir)/apr/include -I$(top_builddir)/apr/include \
+-I$(top_srcdir)/expat-lite -I$(srcdir)/../include -I$(srcdir)
 
 ## Libraries this binary depends upon:
 svn_LDADD = ../libsvn_client/libsvn_client.la \
Index: subversion/libsvn_client/Makefile.am
===================================================================
RCS file: /cvs/subversion/subversion/libsvn_client/Makefile.am,v
retrieving revision 1.9
diff -u -r1.9 Makefile.am
--- subversion/libsvn_client/Makefile.am 2000/12/14 18:48:15 1.9
+++ subversion/libsvn_client/Makefile.am 2000/12/16 06:28:38
@@ -16,7 +16,8 @@
 ## Build flags ---------
 
 ## These should be variables, no? (from autoconf?)
-INCLUDES = -I../include -I../../apr/include -I../../expat-lite
+INCLUDES = -I$(top_srcdir)/apr/include -I$(top_builddir)/apr/include \
+-I$(top_srcdir)/expat-lite -I$(srcdir)/../include
 
 
 ## Put `tests' after `.' when we have a tests directory.
Index: subversion/libsvn_delta/Makefile.am
===================================================================
RCS file: /cvs/subversion/subversion/libsvn_delta/Makefile.am,v
retrieving revision 1.14
diff -u -r1.14 Makefile.am
--- subversion/libsvn_delta/Makefile.am 2000/10/26 20:02:25 1.14
+++ subversion/libsvn_delta/Makefile.am 2000/12/16 06:28:38
@@ -14,8 +14,8 @@
 ## Build flags ---------
 
 ## These should be variables, no? (from autoconf?)
-INCLUDES = -I../include -I../../apr/include -I../../expat-lite
-
+INCLUDES = -I$(top_srcdir)/apr/include -I$(top_builddir)/apr/include \
+-I$(top_srcdir)/expat-lite -I$(srcdir)/../include
 
 ## Build *this* directory first, *then* the test subdirectory!
 SUBDIRS = . tests
Index: subversion/libsvn_delta/tests/Makefile.am
===================================================================
RCS file: /cvs/subversion/subversion/libsvn_delta/tests/Makefile.am,v
retrieving revision 1.12
diff -u -r1.12 Makefile.am
--- subversion/libsvn_delta/tests/Makefile.am 2000/10/25 15:58:07 1.12
+++ subversion/libsvn_delta/tests/Makefile.am 2000/12/16 06:28:38
@@ -9,7 +9,8 @@
 svndiff_test_SOURCES = svndiff-test.c
 
 ## Flags needed when compiling:
-INCLUDES = -I../../include -I../../../apr/include -I../../../expat-lite
+INCLUDES = -I$(top_srcdir)/apr/include -I$(top_builddir)/apr/include \
+-I$(top_srcdir)/expat-lite -I$(srcdir)/../../include
 
 ## Libraries this binary depends upon:
 deltaparse_test_LDADD = ../libsvn_delta.la \
Index: subversion/libsvn_ra_dav/Makefile.am
===================================================================
RCS file: /cvs/subversion/subversion/libsvn_ra_dav/Makefile.am,v
retrieving revision 1.4
diff -u -r1.4 Makefile.am
--- subversion/libsvn_ra_dav/Makefile.am 2000/09/11 09:21:50 1.4
+++ subversion/libsvn_ra_dav/Makefile.am 2000/12/16 06:28:38
@@ -5,7 +5,8 @@
 
 libsvn_ra_dav_la_SOURCES = session.c fetch.c commit.c
 
-INCLUDES = -I../include -I../../apr/include -I../../neon/src
+INCLUDES = -I$(top_srcdir)/apr/include -I$(top_builddir)/apr/include \
+-I$(top_srcdir)/neon/src -I$(srcdir)/../include
 
 SUBDIRS = . tests
 
Index: subversion/libsvn_ra_dav/tests/Makefile.am
===================================================================
RCS file: /cvs/subversion/subversion/libsvn_ra_dav/tests/Makefile.am,v
retrieving revision 1.12
diff -u -r1.12 Makefile.am
--- subversion/libsvn_ra_dav/tests/Makefile.am 2000/12/03 13:52:49 1.12
+++ subversion/libsvn_ra_dav/tests/Makefile.am 2000/12/16 06:28:40
@@ -6,7 +6,8 @@
 ra_commit_SOURCES = ra-commit.c
 
 ## Flags needed when compiling:
-INCLUDES = -I../../include -I../../../apr/include
+INCLUDES = -I$(top_srcdir)/apr/include -I$(top_builddir)/apr/include \
+-I$(srcdir)/../../include
 
 ## Libraries this binary depends upon:
 ra_dav_test_LDADD = ../libsvn_ra_dav.la \
Index: subversion/libsvn_subr/Makefile.am
===================================================================
RCS file: /cvs/subversion/subversion/libsvn_subr/Makefile.am,v
retrieving revision 1.12
diff -u -r1.12 Makefile.am
--- subversion/libsvn_subr/Makefile.am 2000/11/05 01:01:35 1.12
+++ subversion/libsvn_subr/Makefile.am 2000/12/16 06:28:40
@@ -15,7 +15,8 @@
 ## Build flags ---------
 
 ## These should be variables, no? (from autoconf?)
-INCLUDES = -I../include -I../../apr/include -I../../expat-lite
+INCLUDES = -I$(top_srcdir)/apr/include -I$(top_builddir)/apr/include \
+-I$(top_srcdir)/expat-lite -I$(srcdir)/../include
 
 
 ## Build *this* directory first, *then* the test subdirectory!
Index: subversion/libsvn_subr/tests/Makefile.am
===================================================================
RCS file: /cvs/subversion/subversion/libsvn_subr/tests/Makefile.am,v
retrieving revision 1.11
diff -u -r1.11 Makefile.am
--- subversion/libsvn_subr/tests/Makefile.am 2000/10/25 15:58:08 1.11
+++ subversion/libsvn_subr/tests/Makefile.am 2000/12/16 06:28:40
@@ -5,7 +5,8 @@
 stringtest_SOURCES = stringtest.c
 
 ## Flags needed when compiling:
-INCLUDES = -I../../include -I../../../apr/include
+INCLUDES = -I$(top_srcdir)/apr/include -I$(top_builddir)/apr/include \
+-I$(srcdir)/../../include
 
 ## Libraries this binary depends upon:
 hashdump_test_LDADD = ../../tests-common/libsvn_tests_main.la \
Index: subversion/libsvn_wc/Makefile.am
===================================================================
RCS file: /cvs/subversion/subversion/libsvn_wc/Makefile.am,v
retrieving revision 1.24
diff -u -r1.24 Makefile.am
--- subversion/libsvn_wc/Makefile.am 2000/11/12 21:29:35 1.24
+++ subversion/libsvn_wc/Makefile.am 2000/12/16 06:28:40
@@ -18,8 +18,10 @@
 ## Build flags ---------
 
 ## These should be variables, no? (from autoconf?)
-INCLUDES = -I../include -I../../apr/include -I../../expat-lite -I../../
+INCLUDES = -I$(top_srcdir)/apr/include -I$(top_builddir)/apr/include \
+-I$(top_srcdir)/expat-lite -I$(srcdir)/../include
 
+# -I../../
 
 ## Build *this* directory first, *then* the test subdirectory!
 SUBDIRS = . tests
Index: subversion/libsvn_wc/tests/Makefile.am
===================================================================
RCS file: /cvs/subversion/subversion/libsvn_wc/tests/Makefile.am,v
retrieving revision 1.12
diff -u -r1.12 Makefile.am
--- subversion/libsvn_wc/tests/Makefile.am 2000/10/25 15:58:08 1.12
+++ subversion/libsvn_wc/tests/Makefile.am 2000/12/16 06:28:40
@@ -7,7 +7,8 @@
 
 
 ## Flags needed when compiling:
-INCLUDES = -I../../include -I../../../apr/include -I../../../expat-lite
+INCLUDES = -I$(top_srcdir)/apr/include -I$(top_builddir)/apr/include \
+-I$(top_srcdir)/expat-lite -I$(srcdir)/../../include
 
 ## Libraries this binary depends upon:
 checkout_test_LDADD = ../libsvn_wc.la \
Index: subversion/tests-common/Makefile.am
===================================================================
RCS file: /cvs/subversion/subversion/tests-common/Makefile.am,v
retrieving revision 1.7
diff -u -r1.7 Makefile.am
--- subversion/tests-common/Makefile.am 2000/10/25 15:58:08 1.7
+++ subversion/tests-common/Makefile.am 2000/12/16 06:28:40
@@ -5,8 +5,8 @@
 libsvn_test_editor_la_SOURCES = svn_test_editor.c
 
 ## Flags needed when compiling:
-INCLUDES = -I../../apr/include -I../include
-
+INCLUDES = -I$(top_srcdir)/apr/include -I$(top_builddir)/apr/include \
+-I$(srcdir)/../include
 
 ## Make libtool be quiet
 LIBTOOL = @LIBTOOL@ --silent
Received on Sat Oct 21 14:36:17 2006

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.