summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorneal <neal>2008-02-21 15:09:03 +0000
committerneal <neal>2008-02-21 15:09:03 +0000
commitd715d88364b61de9c84d8ebdaa83a5b725b48bfb (patch)
tree213846394ed7b1bcd0f725d29cd6b37bbc37b9bf
parent951c9b8f6c475b21d191a9f0b44da14effb34aee (diff)
/
2008-02-21 Neal H. Walfield <neal@gnu.org> * configure.ac (CFLAGS): Remove variable. (USER_CFLAGS): New variable. (USER_CPPFLAGS): Likewise. (USER_LDFLAGS): Likewise. (USER_LDADD): Likewise. (KERNEL_CFLAGS): Likewise. (KERNEL_CPPFLAGS): Likewise. * Makefile.am (SUBDIRS): Build . after building laden and viengoos. hieronymus/ 2008-02-21 Neal H. Walfield <neal@gnu.org> * Makefile.am (AM_CPPFLAGS): Remove variable. (AM_LDFLAGS): Likewise. (hieronymus_CPPFLAGS): New variable. (hieronymus_CFLAGS): Likewise. (hieronymus_LDFLAGS): Likewise. (hieronymus_LDADD): Don't include libc.a directly, use the value of $(USER_LDADD) instead. hurd/ 2008-02-21 Neal H. Walfield <neal@gnu.org> * Makefile.am (COMMON_CPPFLAGS): Remove variable. (t_addr_CPPFLAGS): Replace use of $(COMMON_CPPFLAGS) with use of $(CHECK_CPPFLAGS). (t_addr_trans_CPPFLAGS): Likewise. (t_rpc_CPPFLAGS): Likewise. libc-parts/ 2008-02-21 Neal H. Walfield <neal@gnu.org> * Makefile.am (COMMON_CPPFLAGS): Remove variable. (libc_parts_a_CPPFLAGS): Set to $(USER_CPPFLAGS). (libc_parts_a_CFLAGS): New variable. (libc_kernel_a_CPPFLAGS): Set to $(KERNEL_CPPFLAGS). (libc_kernel_a_CFLAGS): New variable. (t_setjmp_CPPFLAGS): Remove use of $(COMMON_CPPFLAGS) with $(CHECK_CPPFLAGS). libhurd-btree/ 2008-02-21 Neal H. Walfield <neal@gnu.org> * Makefile.am (COMMON_CPPFLAGS): Remove variable. (libhurd_btree_a_CPPFLAGS): Replace use of above with $(USER_CPPFLAGS). (libhurd_btree_a_CFLAGS): New variable. (btree_test_CPPFLAGS): Replace use $(COMMON_CPPFLAGS) with $(CHECK_CPPFLAGS). libhurd-ihash/ 2008-02-21 Neal H. Walfield <neal@gnu.org> * Makefile.am (AM_CPPFLAGS): Remove variable. (AM_CFLAGS): Likewise. (libhurd_ihash_a_CPPFLAGS): New variable. (libhurd_ihash_a_CFLAGS): Likewise. (libhurd_ihash_nomalloc_a_CPPFLAGS): Replace use of $(AM_CPPFLAGS) with $(USER_CPPFLAGS). (libhurd_ihash_nomalloc_a_CFLAGS): New variable. (t_ihash_CPPFLAGS): Remove use of $(AM_CPPFLAGS). (t_ihash64_CPPFLAGS): Likewise. (t_ihash_CFLAGS): New variable. (t_ihash64_CFLAGS): Likewise. * ihash.c: Don't include <hurd/ihash.h> but "ihash.h". libhurd-mm/ 2008-02-21 Neal H. Walfield <neal@gnu.org> * Makefile.am (COMMON_CPPFLAGS): Remove variable. (libhurd_mm_a_CPPFLAGS): Replace use of above with $(USER_CPPFLAGS). (libhurd_mm_a_CFLAGS): New variable. libpthread/ 2008-02-21 Neal H. Walfield <neal@gnu.org> * Makefile.am (AM_CPPFLAGS): Replace use of includes with $(USER_CPPFLAGS). (AM_CFLAGS): New variable. newlib/ 2008-02-21 Neal H. Walfield <neal@gnu.org> * Makefile.am (patch_files): Add 05-newlib-newlib-libc-include-machine-setjmp-h.patch, 06-newlib-newlib-libc-machine-i386-i386mach-h.patch, and 07-newlib-newlib-libm-machine-i386-i386mach-h.patch. (ccheaders): Remove variable. (SYSINCLUDES): Likewise. (newlib-build/libc.a newlib-build/libm.a): Set TARGET_CFLAGS to "$(USER_CPPFLAGS) $(USER_CFLAGS) $(USER_LDFLAGS)". * newlib/patches/05-newlib-newlib-libc-include-machine-setjmp-h.patch: New file. * newlib/patches/06-newlib-newlib-libc-machine-i386-i386mach-h.patch: New file. * newlib/patches/07-newlib-newlib-libm-machine-i386-i386mach-h.patch: New file. ruth/ 2008-02-21 Neal H. Walfield <neal@gnu.org> * Makefile.am (COMMON_CPPFLAGS): Remove variable. (ruth_CPPFLAGS): Set to $(USER_CPPFLAGS). (ruth_CFLAGS): New variable. (ruth_LDFLAGS): Set to $(USER_LDFLAGS). (ruth_LDADD): Set to $(USER_LDADD). viengoos/ 2008-02-21 Neal H. Walfield <neal@gnu.org> * Makefile.am (COMMON_CPPFLAGS): Remove variable. (viengoos_CPPFLAGS): Set to $(KERNEL_CPPFLAGS). (viengoos_CFLAGS): New variable. (libhurd_cap_a_CPPFLAGS): Set to $(USER_CPPFLAGS). (libhurd_cap_a_CFLAGS): New variable. (t_as_CFLAGS): New variable. (t_activity_CFLAGS): Likewise. (t_link_CFLAGS): Likewise.
-rw-r--r--ChangeLog13
-rw-r--r--Makefile.am2
-rw-r--r--configure.ac32
-rw-r--r--hieronymus/ChangeLog10
-rw-r--r--hieronymus/Makefile.am9
-rw-r--r--hurd/ChangeLog8
-rw-r--r--hurd/Makefile.am9
-rw-r--r--libc-parts/ChangeLog10
-rw-r--r--libc-parts/Makefile.am11
-rw-r--r--libhurd-btree/ChangeLog9
-rw-r--r--libhurd-btree/Makefile.am7
-rw-r--r--libhurd-ihash/ChangeLog15
-rw-r--r--libhurd-ihash/Makefile.am14
-rw-r--r--libhurd-ihash/ihash.c2
-rw-r--r--libhurd-mm/ChangeLog7
-rw-r--r--libhurd-mm/Makefile.am6
-rw-r--r--libpthread/ChangeLog6
-rw-r--r--libpthread/Makefile.am9
-rw-r--r--newlib/ChangeLog17
-rw-r--r--newlib/Makefile.am16
-rw-r--r--newlib/patches/05-newlib-newlib-libc-include-machine-setjmp-h.patch17
-rw-r--r--newlib/patches/06-newlib-newlib-libc-machine-i386-i386mach-h.patch17
-rw-r--r--newlib/patches/07-newlib-newlib-libm-machine-i386-i386mach-h.patch17
-rw-r--r--ruth/ChangeLog8
-rw-r--r--ruth/Makefile.am14
-rw-r--r--viengoos/ChangeLog11
-rw-r--r--viengoos/Makefile.am13
27 files changed, 243 insertions, 66 deletions
diff --git a/ChangeLog b/ChangeLog
index 9e03ea5..e54883f 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,16 @@
+2008-02-21 Neal H. Walfield <neal@gnu.org>
+
+ * configure.ac (CFLAGS): Remove variable.
+ (USER_CFLAGS): New variable.
+ (USER_CPPFLAGS): Likewise.
+ (USER_LDFLAGS): Likewise.
+ (USER_LDADD): Likewise.
+ (KERNEL_CFLAGS): Likewise.
+ (KERNEL_CPPFLAGS): Likewise.
+
+ * Makefile.am (SUBDIRS): Build . after building laden and
+ viengoos.
+
2008-02-16 Neal H. Walfield <neal@gnu.org>
* Makefile.am (all-local): Depend on libc-stmp.
diff --git a/Makefile.am b/Makefile.am
index e7e3b3a..f7ea212 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -37,8 +37,8 @@ SUBDIRS = libl4 platform \
libpthread \
libhurd-mm \
libc-parts \
- . \
laden viengoos \
+ . \
ruth \
hieronymus \
doc
diff --git a/configure.ac b/configure.ac
index 779e4e9..8adb8b8 100644
--- a/configure.ac
+++ b/configure.ac
@@ -33,9 +33,6 @@ maintainer_mode=${enable_maintainer_mode-no}
# Checks for programs.
AC_PROG_CC
-# FIXME: We should support setting the CFLAGS by the user. But
-# -std=gnu99 and -O1 are required.
-CFLAGS="-std=gnu99 -Wall -g -O2 -fno-stack-protector $CFLAGS"
AM_PROG_AS
AC_PROG_RANLIB
AC_CHECK_TOOL([AR], [ar], :)
@@ -183,6 +180,35 @@ fi
AC_SUBST([LIBC_A])
AC_SUBST([LIBC_M])
+# Compute some variables that we need everywhere.
+
+# Ripped from glibc.
+ccheaders = $(${CC} -print-file-name=include)
+SYSINCLUDES = -nostdinc -isystem ${ccheaders} -isystem ${ccheaders}-fixed
+
+USER_CFLAGS="-std=gnu99 -Wall -g -O2 -fno-stack-protector"
+USER_CPPFLAGS="-U__linux -U__linux__ -U__gnu_linux__ -Ulinux -D__GNU__ \
+ -D_GNU_SOURCE ${SYSINCLUDES} -I${LIBC}/include \
+ -I${ABS_BUILDDIR}/include -I${ABS_SRCDIR}/libc-parts"
+USER_LDFLAGS="-u_start -e_start -nostdlib"
+USER_LDADD="${ABS_BUILDDIR}/libc.a"
+
+KERNEL_CFLAGS="-std=gnu99 -Wall -g -O2 -fno-stack-protector"
+KERNEL_CPPFLAGS="-U__linux -U__linux__ -U__gnu_linux__ -Ulinux -D__GNU__ \
+ -D_GNU_SOURCE -DRM_INTERN $SYSINCLUDES -I${ABS_BUILDDIR}/include \
+ -I${ABS_SRCDIR}/libc-parts"
+
+CHECK_CPPFLAGS="-I${ABS_BUILDDIR}/include -I${ABS_SRCDIR}/libc-parts"
+
+AC_SUBST(USER_CFLAGS)
+AC_SUBST(USER_CPPFLAGS)
+AC_SUBST(USER_LDFLAGS)
+AC_SUBST(USER_LDADD)
+AC_SUBST(KERNEL_CFLAGS)
+AC_SUBST(KERNEL_CPPFLAGS)
+AC_SUBST(CHECK_CPPFLAGS)
+
+
if test "x$missing_progs" != "x"; then
AC_MSG_ERROR([The following programs were not found:$missing_progs])
fi
diff --git a/hieronymus/ChangeLog b/hieronymus/ChangeLog
index 311ffa1..b03c3b6 100644
--- a/hieronymus/ChangeLog
+++ b/hieronymus/ChangeLog
@@ -1,3 +1,13 @@
+2008-02-21 Neal H. Walfield <neal@gnu.org>
+
+ * Makefile.am (AM_CPPFLAGS): Remove variable.
+ (AM_LDFLAGS): Likewise.
+ (hieronymus_CPPFLAGS): New variable.
+ (hieronymus_CFLAGS): Likewise.
+ (hieronymus_LDFLAGS): Likewise.
+ (hieronymus_LDADD): Don't include libc.a directly, use the value
+ of $(USER_LDADD) instead.
+
2008-02-13 Neal H. Walfield <neal@gnu.org>
* hieronymus.c (activity_alloc): Update user of storage_alloc to
diff --git a/hieronymus/Makefile.am b/hieronymus/Makefile.am
index 10ce9ba..bec16d6 100644
--- a/hieronymus/Makefile.am
+++ b/hieronymus/Makefile.am
@@ -20,13 +20,12 @@
bootdir = $(prefix)/boot
boot_PROGRAMS = hieronymus
-AM_CPPFLAGS = -Wall -g -std=gnu99 -D_GNU_SOURCE -I$(srcdir) \
- -I$@LIBC@/include -I$(top_builddir)/include \
- -I$(top_srcdir)/libc-parts
-AM_LDFLAGS = -u_start -e_start -nostdlib
+hieronymus_CPPFLAGS = $(USER_CPPFLAGS)
+hieronymus_CFLAGS = $(USER_CFLAGS)
+hieronymus_LDFLAGS = $(USER_LDFLAGS)
+hieronymus_LDADD = $(USER_LDADD) $(addsuffix .o, $(files))
hieronymus_SOURCES = hieronymus.c modules.h
-hieronymus_LDADD = $(top_builddir)/libc.a $(addsuffix .o, $(files))
# List of modules to load followed by their priority, share, and then
# command line. Each component is separated by a !
diff --git a/hurd/ChangeLog b/hurd/ChangeLog
index e33a0ea..df2234a 100644
--- a/hurd/ChangeLog
+++ b/hurd/ChangeLog
@@ -1,3 +1,11 @@
+2008-02-21 Neal H. Walfield <neal@gnu.org>
+
+ * Makefile.am (COMMON_CPPFLAGS): Remove variable.
+ (t_addr_CPPFLAGS): Replace use of $(COMMON_CPPFLAGS)
+ with use of $(CHECK_CPPFLAGS).
+ (t_addr_trans_CPPFLAGS): Likewise.
+ (t_rpc_CPPFLAGS): Likewise.
+
2008-02-20 Neal H. Walfield <neal@gnu.org>
* cap.h (RM_object_discarded_clear): Define.
diff --git a/hurd/Makefile.am b/hurd/Makefile.am
index 5c457fa..5283eb9 100644
--- a/hurd/Makefile.am
+++ b/hurd/Makefile.am
@@ -17,9 +17,6 @@
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
-COMMON_CPPFLAGS = -I$(srcdir) -I$(top_builddir)/include \
- -I$(top_srcdir)/libc-parts -D_GNU_SOURCE -Wall -std=gnu99 -g
-
includehurddir = $(includedir)/hurd
includehurd_HEADERS = rpc.h startup.h stddef.h types.h addr.h \
addr-trans.h cap.h folio.h exceptions.h thread.h activity.h \
@@ -28,12 +25,12 @@ includehurd_HEADERS = rpc.h startup.h stddef.h types.h addr.h \
TESTS = t-addr t-addr-trans t-rpc
check_PROGRAMS = $(TESTS)
-t_addr_CPPFLAGS = $(COMMON_CPPFLAGS) -DS_PRINTF=printf
+t_addr_CPPFLAGS = $(CHECK_CPPFLAGS) -DS_PRINTF=printf
t_addr_SOURCES = t-addr.c
-t_addr_trans_CPPFLAGS = $(COMMON_CPPFLAGS) -DS_PRINTF=printf
+t_addr_trans_CPPFLAGS = $(CHECK_CPPFLAGS) -DS_PRINTF=printf
t_addr_trans_SOURCES = t-addr-trans.c
-t_rpc_CPPFLAGS = $(COMMON_CPPFLAGS) -DS_PRINTF=printf
+t_rpc_CPPFLAGS = $(CHECK_CPPFLAGS) -DS_PRINTF=printf
t_rpc_SOURCES = t-rpc.c
diff --git a/libc-parts/ChangeLog b/libc-parts/ChangeLog
index fa9deb1..b401e64 100644
--- a/libc-parts/ChangeLog
+++ b/libc-parts/ChangeLog
@@ -1,3 +1,13 @@
+2008-02-21 Neal H. Walfield <neal@gnu.org>
+
+ * Makefile.am (COMMON_CPPFLAGS): Remove variable.
+ (libc_parts_a_CPPFLAGS): Set to $(USER_CPPFLAGS).
+ (libc_parts_a_CFLAGS): New variable.
+ (libc_kernel_a_CPPFLAGS): Set to $(KERNEL_CPPFLAGS).
+ (libc_kernel_a_CFLAGS): New variable.
+ (t_setjmp_CPPFLAGS): Remove use of $(COMMON_CPPFLAGS) with
+ $(CHECK_CPPFLAGS).
+
2008-02-20 Thomas Schwinge <tschwinge@gnu.org>
* alloca.h: New file, from today's glibc CVS HEAD.
diff --git a/libc-parts/Makefile.am b/libc-parts/Makefile.am
index e94e019..aa00334 100644
--- a/libc-parts/Makefile.am
+++ b/libc-parts/Makefile.am
@@ -24,9 +24,6 @@ if ARCH_IA32
ARCH_KERNEL_SOURCES =
endif
-COMMON_CPPFLAGS = -I$(srcdir) -I$(top_builddir)/include \
- -I$(top_srcdir)/libc-parts -D_GNU_SOURCE -Wall -std=gnu99 -g
-
noinst_LIBRARIES = libc-parts.a libc-kernel.a
common_sources = assert.h \
@@ -36,14 +33,16 @@ common_sources = assert.h \
elf.h loader.h loader.c \
process-spawn.h process-spawn.c
-libc_parts_a_CPPFLAGS = -I$(LIBC)/include $(COMMON_CPPFLAGS)
+libc_parts_a_CPPFLAGS = $(USER_CPPFLAGS)
+libc_parts_a_CFLAGS = $(USER_CFLAGS)
libc_parts_a_SOURCES = \
$(ARCH_COMMON_SOURCES) $(ARCH_USER_SOURCES) \
ctype.h c-ctype.h c-ctype.c \
getpagesize.c \
$(common_sources)
-libc_kernel_a_CPPFLAGS = $(COMMON_CPPFLAGS) -DRM_INTERN
+libc_kernel_a_CPPFLAGS = $(KERNEL_CPPFLAGS)
+libc_kernel_a_CFLAGS = $(KERNEL_CFLAGS)
libc_kernel_a_SOURCES = \
$(ARCH_COMMON_SOURCES) $(ARCH_KERNEL_SOURCES) \
errno.h errno.c \
@@ -52,5 +51,5 @@ libc_kernel_a_SOURCES = \
TESTS = t-setjmp
check_PROGRAMS = $(TESTS)
-t_setjmp_CPPFLAGS = $(COMMON_CPPFLAGS) -DS_PRINTF=printf
+t_setjmp_CPPFLAGS = $(CHECK_CPPFLAGS) -DS_PRINTF=printf
t_setjmp_SOURCES = t-setjmp.c setjmp.h ia32-setjmp.S
diff --git a/libhurd-btree/ChangeLog b/libhurd-btree/ChangeLog
index 996fabc..c75cce5 100644
--- a/libhurd-btree/ChangeLog
+++ b/libhurd-btree/ChangeLog
@@ -1,3 +1,12 @@
+2008-02-21 Neal H. Walfield <neal@gnu.org>
+
+ * Makefile.am (COMMON_CPPFLAGS): Remove variable.
+ (libhurd_btree_a_CPPFLAGS): Replace use of above with
+ $(USER_CPPFLAGS).
+ (libhurd_btree_a_CFLAGS): New variable.
+ (btree_test_CPPFLAGS): Replace use $(COMMON_CPPFLAGS) with
+ $(CHECK_CPPFLAGS).
+
2008-02-15 Neal H. Walfield <neal@gnu.org>
* btree.h (BTREE_(check_tree_internal)) [!NDEBUG && !NCHECKS]:
diff --git a/libhurd-btree/Makefile.am b/libhurd-btree/Makefile.am
index e34ddd7..f4a85d8 100644
--- a/libhurd-btree/Makefile.am
+++ b/libhurd-btree/Makefile.am
@@ -24,14 +24,13 @@ lib_LIBRARIES = libhurd-btree.a
includehurddir = $(includedir)/hurd
includehurd_HEADERS = btree.h
-COMMON_CPPFLAGS = -I$(top_builddir)/include -I$(top_srcdir)/libc-parts \
- -D_GNU_SOURCE
-libhurd_btree_a_CPPFLAGS = $(COMMON_CPPFLAGS) -DNCHECKS
+libhurd_btree_a_CPPFLAGS = $(USER_CPPFLAGS) -DNCHECKS
+libhurd_btree_a_CFLAGS = $(USER_CFLAGS)
libhurd_btree_a_SOURCES = btree.h btree.c
TESTS = btree-test
check_PROGRAMS = btree-test
btree_test_SOURCES = btree-test.c btree.h btree.c
-btree_test_CPPFLAGS = -DS_PRINTF=printf $(COMMON_CPPFLAGS)
+btree_test_CPPFLAGS = $(CHECK_CPPFLAGS) -DS_PRINTF=printf
diff --git a/libhurd-ihash/ChangeLog b/libhurd-ihash/ChangeLog
index 3f2af53..cdb656b 100644
--- a/libhurd-ihash/ChangeLog
+++ b/libhurd-ihash/ChangeLog
@@ -1,3 +1,18 @@
+2008-02-21 Neal H. Walfield <neal@gnu.org>
+
+ * Makefile.am (AM_CPPFLAGS): Remove variable.
+ (AM_CFLAGS): Likewise.
+ (libhurd_ihash_a_CPPFLAGS): New variable.
+ (libhurd_ihash_a_CFLAGS): Likewise.
+ (libhurd_ihash_nomalloc_a_CPPFLAGS): Replace use of $(AM_CPPFLAGS)
+ with $(USER_CPPFLAGS).
+ (libhurd_ihash_nomalloc_a_CFLAGS): New variable.
+ (t_ihash_CPPFLAGS): Remove use of $(AM_CPPFLAGS).
+ (t_ihash64_CPPFLAGS): Likewise.
+ (t_ihash_CFLAGS): New variable.
+ (t_ihash64_CFLAGS): Likewise.
+ * ihash.c: Don't include <hurd/ihash.h> but "ihash.h".
+
2008-02-20 Neal H. Walfield <neal@gnu.org>
* ihash.c (hurd_ihash_init_with_buffer): Set size to the largest
diff --git a/libhurd-ihash/Makefile.am b/libhurd-ihash/Makefile.am
index 72a0e56..1a2f8ac 100644
--- a/libhurd-ihash/Makefile.am
+++ b/libhurd-ihash/Makefile.am
@@ -26,20 +26,22 @@ includehurd_HEADERS = ihash.h
# FIXME: Build a special libhurd-ihash.a using libc-parts for the rootservers,
# and a normal for everybody else.
-AM_CPPFLAGS = -I$(LIBC)/include -I$(top_builddir)/include \
- -I$(top_srcdir)/libc-parts
-AM_CFLAGS = -std=gnu99
+libhurd_ihash_a_CPPFLAGS = $(USER_CPPFLAGS)
+libhurd_ihash_a_CFLAGS = $(USER_CFLAGS)
libhurd_ihash_a_SOURCES = ihash.h ihash.c
-libhurd_ihash_nomalloc_a_CPPFLAGS = $(AM_CPPFLAGS) -DNO_MALLOC
+libhurd_ihash_nomalloc_a_CPPFLAGS = $(USER_CPPFLAGS) -DNO_MALLOC
+libhurd_ihash_nomalloc_a_CFLAGS = $(USER_CFLAGS)
libhurd_ihash_nomalloc_a_SOURCES = ihash.h ihash.c
TESTS = t-ihash t-ihash64
check_PROGRAMS = t-ihash t-ihash64
t_ihash_SOURCES = t-ihash.c ihash.h ihash.c
-t_ihash_CPPFLAGS = -DTEST_LARGE=false -DS_PRINTF=printf $(AM_CPPFLAGS)
+t_ihash_CPPFLAGS = -DTEST_LARGE=false -DS_PRINTF=printf
+t_ihash_CFLAGS=-std=gnu99
t_ihash64_SOURCES = t-ihash.c ihash.h ihash.c
-t_ihash64_CPPFLAGS = -DTEST_LARGE=true -DS_PRINTF=printf $(AM_CPPFLAGS)
+t_ihash64_CPPFLAGS = -DTEST_LARGE=true -DS_PRINTF=printf
+t_ihash64_CFLAGS=-std=gnu99
diff --git a/libhurd-ihash/ihash.c b/libhurd-ihash/ihash.c
index c34ec74..0803bc3 100644
--- a/libhurd-ihash/ihash.c
+++ b/libhurd-ihash/ihash.c
@@ -31,7 +31,7 @@
#include <stdint.h>
#include <assert.h>
-#include <hurd/ihash.h>
+#include "ihash.h"
/* The prime numbers of the form 4 * i + 3 for some i, all greater
diff --git a/libhurd-mm/ChangeLog b/libhurd-mm/ChangeLog
index 5ddf704..f2d9f3a 100644
--- a/libhurd-mm/ChangeLog
+++ b/libhurd-mm/ChangeLog
@@ -1,3 +1,10 @@
+2008-02-21 Neal H. Walfield <neal@gnu.org>
+
+ * Makefile.am (COMMON_CPPFLAGS): Remove variable.
+ (libhurd_mm_a_CPPFLAGS): Replace use of above with
+ $(USER_CPPFLAGS).
+ (libhurd_mm_a_CFLAGS): New variable.
+
2008-02-20 Neal H. Walfield <neal@gnu.org>
* anonymous.h: Include <hurd/exceptions.h> and <l4/thread.h>.
diff --git a/libhurd-mm/Makefile.am b/libhurd-mm/Makefile.am
index f31e97c..29c7f79 100644
--- a/libhurd-mm/Makefile.am
+++ b/libhurd-mm/Makefile.am
@@ -27,10 +27,8 @@ lib_LIBRARIES = libhurd-mm.a
includehurddir = $(includedir)/hurd
includehurd_HEADERS = mm.h storage.h as.h
-COMMON_CPPFLAGS = -I$(LIBC)/include -I$(top_builddir)/include \
- -I$(top_srcdir)/libc-parts -D_GNU_SOURCE -Wall -std=gnu99 \
- -g -O2 -mpreferred-stack-boundary=2
-libhurd_mm_a_CPPFLAGS = $(COMMON_CPPFLAGS)
+libhurd_mm_a_CPPFLAGS = $(USER_CPPFLAGS)
+libhurd_mm_a_CFLAGS = $(USER_CFLAGS) -mpreferred-stack-boundary=2
libhurd_mm_a_SOURCES = mm.h \
capalloc.h capalloc.c \
storage.h storage.c \
diff --git a/libpthread/ChangeLog b/libpthread/ChangeLog
index 0c3a8cf..b647379 100644
--- a/libpthread/ChangeLog
+++ b/libpthread/ChangeLog
@@ -1,3 +1,9 @@
+2008-02-21 Neal H. Walfield <neal@gnu.org>
+
+ * Makefile.am (AM_CPPFLAGS): Replace use of includes with
+ $(USER_CPPFLAGS).
+ (AM_CFLAGS): New variable.
+
2008-02-16 Neal H. Walfield <neal@gnu.org>
* sysdeps/l4/hurd/ia32/pt-setup.c (stack_setup): Add correct casts
diff --git a/libpthread/Makefile.am b/libpthread/Makefile.am
index d9cc423..df146df 100644
--- a/libpthread/Makefile.am
+++ b/libpthread/Makefile.am
@@ -38,10 +38,9 @@ SYSDEP_PATH = $(srcdir)/sysdeps/l4/hurd/${arch} \
$(srcdir)/include
vpath %.c $(SYSDEP_PATH)
-AM_CPPFLAGS = -std=gnu99 -Wall -g -O3 -I$(LIBC)/include \
--I$(top_builddir)/include -D_GNU_SOURCE=1 -I$(srcdir)/pthread \
--I$(top_srcdir)/libc-parts $(addprefix -I, $(SYSDEP_PATH)) -imacros \
-$(srcdir)/include/libc-symbols.h
+AM_CPPFLAGS = $(USER_CPPFLAGS) -I$(srcdir)/pthread \
+ $(addprefix -I, $(SYSDEP_PATH)) -imacros $(srcdir)/include/libc-symbols.h
+AM_CFLAGS = $(USER_CFLAGS)
# Sources.
SYSDEPS := lockfile.c
@@ -130,4 +129,4 @@ libpthread_a_SOURCES = pt-attr.c pt-attr-destroy.c pt-attr-getdetachstate.c \
pt-getschedparam.c pt-setschedparam.c pt-setschedprio.c \
sem-close.c sem-init.c sem-timedwait.c sem-wait.c \
sem-destroy.c sem-open.c sem-trywait.c sem-getvalue.c \
- sem-post.c sem-unlink.c \ No newline at end of file
+ sem-post.c sem-unlink.c
diff --git a/newlib/ChangeLog b/newlib/ChangeLog
index 429cf20..c741b15 100644
--- a/newlib/ChangeLog
+++ b/newlib/ChangeLog
@@ -1,3 +1,20 @@
+2008-02-21 Neal H. Walfield <neal@gnu.org>
+
+ * Makefile.am (patch_files): Add
+ 05-newlib-newlib-libc-include-machine-setjmp-h.patch,
+ 06-newlib-newlib-libc-machine-i386-i386mach-h.patch, and
+ 07-newlib-newlib-libm-machine-i386-i386mach-h.patch.
+ (ccheaders): Remove variable.
+ (SYSINCLUDES): Likewise.
+ (newlib-build/libc.a newlib-build/libm.a): Set TARGET_CFLAGS to
+ "$(USER_CPPFLAGS) $(USER_CFLAGS) $(USER_LDFLAGS)".
+ * newlib/patches/05-newlib-newlib-libc-include-machine-setjmp-h.patch:
+ New file.
+ * newlib/patches/06-newlib-newlib-libc-machine-i386-i386mach-h.patch:
+ New file.
+ * newlib/patches/07-newlib-newlib-libm-machine-i386-i386mach-h.patch:
+ New file.
+
2008-02-13 Neal H. Walfield <neal@gnu.org>
* addon/newlib/libc/sys/hurd/getreent.c (slab_alloc): Update use
diff --git a/newlib/Makefile.am b/newlib/Makefile.am
index 109b8c2..c957804 100644
--- a/newlib/Makefile.am
+++ b/newlib/Makefile.am
@@ -25,7 +25,10 @@ patch_files = 00-newlib-configure-ac.patch \
01-newlib-libc-sys-configure-in.patch \
02-newlib-newlib-libc-string-makefile-am.patch \
03-newlib-newlib-configure-host.patch \
- 04-newlib-newlib-configure-ac.patch
+ 04-newlib-newlib-configure-ac.patch \
+ 05-newlib-newlib-libc-include-machine-setjmp-h.patch \
+ 06-newlib-newlib-libc-machine-i386-i386mach-h.patch \
+ 07-newlib-newlib-libm-machine-i386-i386mach-h.patch
# Files to link into newlib's source tree (relative to $(srcdir)/addon)
addon = newlib/libc/sys/hurd/configure.ac \
@@ -129,19 +132,10 @@ newlib-configure-stamp: $(addsuffix -applied,$(patch_files)) \
--build=$(build_alias) --host=$(host_alias))
touch newlib-configure-stamp
-# Ripped from glibc.
-ccheaders := $(shell $(CC) -print-file-name=include)
-SYSINCLUDES := -nostdinc -isystem $(ccheaders) -isystem $(ccheaders)-fixed
-
newlib-build/libc.a newlib-build/libm.a: newlib-configure-stamp
cd newlib-build && \
make \
- TARGET_CFLAGS='\
- -I$(abs_top_builddir)/include \
- -I$(abs_top_srcdir)/libc-parts \
- $(SYSINCLUDES) \
- -nostdlib \
- -fno-stack-protector' \
+ TARGET_CFLAGS='$(USER_CPPFLAGS) $(USER_CFLAGS) $(USER_LDFLAGS)' \
all install
libc.a: newlib-build/libc.a
diff --git a/newlib/patches/05-newlib-newlib-libc-include-machine-setjmp-h.patch b/newlib/patches/05-newlib-newlib-libc-include-machine-setjmp-h.patch
new file mode 100644
index 0000000..ab34594
--- /dev/null
+++ b/newlib/patches/05-newlib-newlib-libc-include-machine-setjmp-h.patch
@@ -0,0 +1,17 @@
+#! /bin/sh
+patch -p1 -f $* < $0
+exit $?
+
+Enable sigjmp_buf.
+
+--- newlib/newlib/libc/include/machine/setjmp.h~ 2007-11-07 22:42:24.000000000 +0100
++++ newlib/newlib/libc/include/machine/setjmp.h 2008-02-20 23:46:12.000000000 +0100
+@@ -251,7 +251,7 @@
+
+ _END_STD_C
+
+-#if defined(__CYGWIN__) || defined(__rtems__)
++#if 1 || defined(__CYGWIN__) || defined(__rtems__)
+ #include <signal.h>
+
+ #ifdef __cplusplus
diff --git a/newlib/patches/06-newlib-newlib-libc-machine-i386-i386mach-h.patch b/newlib/patches/06-newlib-newlib-libc-machine-i386-i386mach-h.patch
new file mode 100644
index 0000000..c07bd3f
--- /dev/null
+++ b/newlib/patches/06-newlib-newlib-libc-machine-i386-i386mach-h.patch
@@ -0,0 +1,17 @@
+#! /bin/sh
+patch -p1 -f $* < $0
+exit $?
+
+Bug fix.
+
+--- newlib/newlib/libc/machine/i386/i386mach.h~ 2000-08-28 19:50:06.000000000 +0200
++++ newlib/newlib/libc/machine/i386/i386mach.h 2008-02-21 14:55:52.000000000 +0100
+@@ -25,7 +25,7 @@
+
+ /* Use the right prefix for registers. */
+
+-#define REG(x) CONCAT1(__REG_PREFIX__, x)
++#define REG(x) __REG_PREFIX__ x
+
+ #define eax REG(eax)
+ #define ebx REG(ebx)
diff --git a/newlib/patches/07-newlib-newlib-libm-machine-i386-i386mach-h.patch b/newlib/patches/07-newlib-newlib-libm-machine-i386-i386mach-h.patch
new file mode 100644
index 0000000..ac110da
--- /dev/null
+++ b/newlib/patches/07-newlib-newlib-libm-machine-i386-i386mach-h.patch
@@ -0,0 +1,17 @@
+#! /bin/sh
+patch -p1 -f $* < $0
+exit $?
+
+Bug fix.
+
+--- newlib/newlib/libm/machine/i386/i386mach.h~ 2001-12-14 00:50:11.000000000 +0100
++++ newlib/newlib/libm/machine/i386/i386mach.h 2008-02-21 15:07:36.000000000 +0100
+@@ -25,7 +25,7 @@
+
+ /* Use the right prefix for registers. */
+
+-#define REG(x) CONCAT1(__REG_PREFIX__, x)
++#define REG(x) __REG_PREFIX__ x
+
+ #define eax REG(eax)
+ #define ebx REG(ebx)
diff --git a/ruth/ChangeLog b/ruth/ChangeLog
index 93f6125..50ca015 100644
--- a/ruth/ChangeLog
+++ b/ruth/ChangeLog
@@ -1,3 +1,11 @@
+2008-02-21 Neal H. Walfield <neal@gnu.org>
+
+ * Makefile.am (COMMON_CPPFLAGS): Remove variable.
+ (ruth_CPPFLAGS): Set to $(USER_CPPFLAGS).
+ (ruth_CFLAGS): New variable.
+ (ruth_LDFLAGS): Set to $(USER_LDFLAGS).
+ (ruth_LDADD): Set to $(USER_LDADD).
+
2008-02-20 Neal H. Walfield <neal@gnu.org>
* ruth.c: Include <hurd/anonymous.h>, <stdlib.h> and <l4.h>.
diff --git a/ruth/Makefile.am b/ruth/Makefile.am
index 06a13a5..c57dd7c 100644
--- a/ruth/Makefile.am
+++ b/ruth/Makefile.am
@@ -21,13 +21,9 @@
bootdir = $(prefix)/boot
boot_PROGRAMS = ruth
-COMMON_CPPFLAGS = -Wall -g -std=gnu99 -D_GNU_SOURCE -I$(srcdir) \
- -I$@LIBC@/include -I$(top_builddir)/include \
- -I$(top_srcdir)/libc-parts
+ruth_CPPFLAGS = $(USER_CPPFLAGS)
+ruth_CFLAGS = $(USER_CFLAGS)
+ruth_LDFLAGS = $(USER_LDFLAGS)
+ruth_LDADD = $(USER_LDADD)
-ruth_CPPFLAGS = $(COMMON_CPPFLAGS)
-ruth_SOURCES = ruth.h ruth.c
-
-ruth_LDFLAGS = -u_start -e_start -nostdlib
-
-ruth_LDADD = $(top_builddir)/libc.a
+ruth_SOURCES = ruth.c
diff --git a/viengoos/ChangeLog b/viengoos/ChangeLog
index 2c3d0d4..987a470 100644
--- a/viengoos/ChangeLog
+++ b/viengoos/ChangeLog
@@ -1,3 +1,14 @@
+2008-02-21 Neal H. Walfield <neal@gnu.org>
+
+ * Makefile.am (COMMON_CPPFLAGS): Remove variable.
+ (viengoos_CPPFLAGS): Set to $(KERNEL_CPPFLAGS).
+ (viengoos_CFLAGS): New variable.
+ (libhurd_cap_a_CPPFLAGS): Set to $(USER_CPPFLAGS).
+ (libhurd_cap_a_CFLAGS): New variable.
+ (t_as_CFLAGS): New variable.
+ (t_activity_CFLAGS): Likewise.
+ (t_link_CFLAGS): Likewise.
+
2008-02-20 Neal H. Walfield <neal@gnu.org>
* server.c (server_loop): Implement object_discarded_clear method.
diff --git a/viengoos/Makefile.am b/viengoos/Makefile.am
index 21e0cda..4851f91 100644
--- a/viengoos/Makefile.am
+++ b/viengoos/Makefile.am
@@ -25,11 +25,9 @@ endif
bootdir = $(prefix)/boot
boot_PROGRAMS = viengoos
-COMMON_CPPFLAGS = -I$(srcdir) -I$(top_builddir)/include \
- -I$(top_srcdir)/libc-parts -D_GNU_SOURCE -Wall -std=gnu99 -g
-
# We need the libc headers for errno.h -I$(LIBC)/include
-viengoos_CPPFLAGS = $(COMMON_CPPFLAGS) -DRM_INTERN
+viengoos_CPPFLAGS = $(KERNEL_CPPFLAGS)
+viengoos_CFLAGS = $(KERNEL_CFLAGS)
viengoos_SOURCES = $(ARCH_SOURCES) \
output.h output.c output-none.c \
debug.h debug.c \
@@ -65,6 +63,7 @@ TESTS = t-as t-activity t-link t-guard
check_PROGRAMS = $(TESTS)
t_as_CPPFLAGS = $(viengoos_CPPFLAGS) -include $(srcdir)/t-environment.h
+t_as_CFLAGS = $(viengoos_CFLAGS)
t_as_SOURCES = t-as.c \
zalloc.h zalloc.c \
memory.h memory.c \
@@ -80,6 +79,7 @@ t_as_SOURCES = t-as.c \
t_as_LDADD = $(viengoos_LDADD)
t_activity_CPPFLAGS = $(viengoos_CPPFLAGS) -include $(srcdir)/t-environment.h
+t_activity_CFLAGS = $(viengoos_CFLAGS)
t_activity_SOURCES = t-activity.c \
zalloc.h zalloc.c \
memory.h memory.c \
@@ -95,15 +95,18 @@ t_activity_SOURCES = t-activity.c \
t_activity_LDADD = $(viengoos_LDADD)
t_link_CPPFLAGS = $(viengoos_CPPFLAGS) -include $(srcdir)/t-environment.h
+t_link_CFLAGS = $(viengoos_CFLAGS)
t_link_SOURCES = t-link.c list.h \
output.h output.c output-stdio.c panic.c shutdown.h shutdown.c
t_guard_CPPFLAGS = $(viengoos_CPPFLAGS) -include $(srcdir)/t-environment.h
+t_guard_CFLAGS = $(viengoos_CFLAGS) -include $(srcdir)/t-environment.h
t_guard_SOURCES = t-guard.c \
output.h output.c output-stdio.c panic.c shutdown.h shutdown.c
lib_LIBRARIES = libhurd-cap.a
# Use a small stack alignment to decrease stack usage.
-libhurd_cap_a_CPPFLAGS = $(COMMON_CPPFLAGS) -mpreferred-stack-boundary=2
+libhurd_cap_a_CPPFLAGS = $(USER_CPPFLAGS)
+libhurd_cap_a_CFLAGS = $(USER_CFLAGS) -mpreferred-stack-boundary=2
libhurd_cap_a_SOURCES = cap-lookup.c as.c as.h as-custom.c