summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--libhurd-btree/ChangeLog5
-rw-r--r--libhurd-btree/Makefile.am8
-rw-r--r--libhurd-btree/headers.m48
-rw-r--r--libhurd-ihash/ChangeLog5
-rw-r--r--libhurd-ihash/Makefile.am13
-rw-r--r--libhurd-ihash/headers.m48
6 files changed, 43 insertions, 4 deletions
diff --git a/libhurd-btree/ChangeLog b/libhurd-btree/ChangeLog
index 46d1533..b87a8a6 100644
--- a/libhurd-btree/ChangeLog
+++ b/libhurd-btree/ChangeLog
@@ -1,5 +1,10 @@
2008-05-29 Thomas Schwinge <tschwinge@gnu.org>
+ * headers.m4: Link files into `sysroot/include/' instead of `include/'.
+ Create symbolic link to package's library in `sysroot/lib/'.
+ * Makefile.am: When building package's libraries, differentiate between
+ [ENABLE_TESTS] with respect to build flags.
+
* Makefile.am (btree_test_CPPFLAGS): Remove special `printf' handling.
2008-02-21 Neal H. Walfield <neal@gnu.org>
diff --git a/libhurd-btree/Makefile.am b/libhurd-btree/Makefile.am
index bd0f699..ffd6656 100644
--- a/libhurd-btree/Makefile.am
+++ b/libhurd-btree/Makefile.am
@@ -24,8 +24,14 @@ lib_LIBRARIES = libhurd-btree.a
includehurddir = $(includedir)/hurd
includehurd_HEADERS = btree.h
-libhurd_btree_a_CPPFLAGS = $(USER_CPPFLAGS) -DNCHECKS
+libhurd_btree_a_CPPFLAGS = -DNCHECKS
+if ENABLE_TESTS
+libhurd_btree_a_CPPFLAGS += $(CHECK_CPPFLAGS)
+libhurd_btree_a_CFLAGS = $(CHECK_CFLAGS)
+else
+libhurd_btree_a_CPPFLAGS += $(USER_CPPFLAGS)
libhurd_btree_a_CFLAGS = $(USER_CFLAGS)
+endif
libhurd_btree_a_SOURCES = btree.h btree.c
TESTS = btree-test
diff --git a/libhurd-btree/headers.m4 b/libhurd-btree/headers.m4
index 15bb7f9..6f37c5f 100644
--- a/libhurd-btree/headers.m4
+++ b/libhurd-btree/headers.m4
@@ -10,4 +10,10 @@
# WITHOUT ANY WARRANTY, to the extent permitted by law; without even the
# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
-AC_CONFIG_LINKS([include/hurd/btree.h:libhurd-btree/btree.h])
+AC_CONFIG_LINKS([sysroot/include/hurd/btree.h:libhurd-btree/btree.h])
+
+AC_CONFIG_COMMANDS_POST([
+ mkdir -p sysroot/lib libhurd-btree &&
+ ln -sf ../../libhurd-btree/libhurd-btree.a sysroot/lib/ &&
+ touch libhurd-btree/libhurd-btree.a
+])
diff --git a/libhurd-ihash/ChangeLog b/libhurd-ihash/ChangeLog
index bb7e30b..3aa2812 100644
--- a/libhurd-ihash/ChangeLog
+++ b/libhurd-ihash/ChangeLog
@@ -1,5 +1,10 @@
2008-05-29 Thomas Schwinge <tschwinge@gnu.org>
+ * headers.m4: Link files into `sysroot/include/' instead of `include/'.
+ Create symbolic link to package's library in `sysroot/lib/'.
+ * Makefile.am: When building package's libraries, differentiate between
+ [ENABLE_TESTS] with respect to build flags.
+
* Makefile.am (t_ihash_CPPFLAGS, t_ihash64_CPPFLAGS): Remove special
`printf' handling.
diff --git a/libhurd-ihash/Makefile.am b/libhurd-ihash/Makefile.am
index 07bd8aa..31351dd 100644
--- a/libhurd-ihash/Makefile.am
+++ b/libhurd-ihash/Makefile.am
@@ -27,12 +27,23 @@ includehurd_HEADERS = ihash.h
# FIXME: Build a special libhurd-ihash.a using libc-parts for the rootservers,
# and a normal for everybody else.
+if ENABLE_TESTS
+libhurd_ihash_a_CPPFLAGS = $(CHECK_CPPFLAGS)
+libhurd_ihash_a_CFLAGS = $(CHECK_CFLAGS)
+else
libhurd_ihash_a_CPPFLAGS = $(USER_CPPFLAGS)
libhurd_ihash_a_CFLAGS = $(USER_CFLAGS)
+endif
libhurd_ihash_a_SOURCES = ihash.h ihash.c
-libhurd_ihash_nomalloc_a_CPPFLAGS = $(USER_CPPFLAGS) -DNO_MALLOC
+libhurd_ihash_nomalloc_a_CPPFLAGS = -DNO_MALLOC
+if ENABLE_TESTS
+libhurd_ihash_nomalloc_a_CPPFLAGS += $(CHECK_CPPFLAGS)
+libhurd_ihash_nomalloc_a_CFLAGS = $(CHECK_CFLAGS)
+else
+libhurd_ihash_nomalloc_a_CPPFLAGS += $(USER_CPPFLAGS)
libhurd_ihash_nomalloc_a_CFLAGS = $(USER_CFLAGS)
+endif
libhurd_ihash_nomalloc_a_SOURCES = ihash.h ihash.c
TESTS = t-ihash t-ihash64
diff --git a/libhurd-ihash/headers.m4 b/libhurd-ihash/headers.m4
index 021d9c0..ab2b5d2 100644
--- a/libhurd-ihash/headers.m4
+++ b/libhurd-ihash/headers.m4
@@ -10,4 +10,10 @@
# WITHOUT ANY WARRANTY, to the extent permitted by law; without even the
# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
-AC_CONFIG_LINKS([include/hurd/ihash.h:libhurd-ihash/ihash.h])
+AC_CONFIG_LINKS([sysroot/include/hurd/ihash.h:libhurd-ihash/ihash.h])
+
+AC_CONFIG_COMMANDS_POST([
+ mkdir -p sysroot/lib libhurd-ihash &&
+ ln -sf ../../libhurd-ihash/libhurd-ihash.a sysroot/lib/ &&
+ touch libhurd-ihash/libhurd-ihash.a
+])