mailarchive of the ptxdist mailing list
 help / color / mirror / Atom feed
* [ptxdist] [PATCH 1/5 v2] [rt-tests] Use CFLAGS specified by ptxdist platformconfig
@ 2012-03-13 21:32 Remy Bohmer
  2012-03-13 21:32 ` [ptxdist] [PATCH 2/5 v2] [x86_64] Add some support for multilib detection in the toolchain Remy Bohmer
                   ` (4 more replies)
  0 siblings, 5 replies; 10+ messages in thread
From: Remy Bohmer @ 2012-03-13 21:32 UTC (permalink / raw)
  To: ptxdist

The platformconfig can specify some valuable global flags for each
package in the configuration to build, for example:
* CPU optimisations (-march= and friends)
* multilib toolchain selection between x86_64 and ia32 such as used for
 the Sourcery Codebench compiler toolchains as specified here:
 https://sourcery.mentor.com/sgpp/lite/ia32/portal/doc12648/getting-started.pdf
 (chapter 3.2 Library configurations)

Signed-off-by: Remy Bohmer <linux@bohmer.net>
---
 v2: Reworked review comments from Michael Olbrich

 patches/rt-tests-0.73/add-extra-cflags.patch |   32 ++++++++++++++++++++++++++
 patches/rt-tests-0.73/series                 |    1 +
 rules/rt-tests.make                          |    1 +
 3 files changed, 34 insertions(+), 0 deletions(-)
 create mode 100644 patches/rt-tests-0.73/add-extra-cflags.patch

diff --git a/patches/rt-tests-0.73/add-extra-cflags.patch b/patches/rt-tests-0.73/add-extra-cflags.patch
new file mode 100644
index 0000000..fc869c6
--- /dev/null
+++ b/patches/rt-tests-0.73/add-extra-cflags.patch
@@ -0,0 +1,32 @@
+CFLAGS are specified in environment as well
+
+If the environment already has specified CFLAGS we shall
+not overwrite them
+
+Signed-off-by: Remy Bohmer <linux@bohmer.net>
+---
+ Makefile |    4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+Index: rt-tests-0.73/Makefile
+===================================================================
+--- rt-tests-0.73.orig/Makefile
++++ rt-tests-0.73/Makefile
+@@ -6,7 +6,7 @@ sources = cyclictest.c signaltest.c pi_s
+ 
+ TARGETS = $(sources:.c=)
+ 
+-LIBS 	= -lrt -lpthread
++LIBS	= $(LDFLAGS) -lrt -lpthread
+ EXTRA_LIBS ?= -ldl	# for get_cpu
+ DESTDIR	?=
+ prefix  ?= /usr/local
+@@ -14,7 +14,7 @@ bindir  ?= $(prefix)/bin
+ mandir	?= $(prefix)/share/man
+ srcdir	?= $(prefix)/src
+ 
+-CFLAGS = -D_GNU_SOURCE -Wall -Wno-nonnull -Isrc/include
++CFLAGS := $(CPPFLAGS) -D_GNU_SOURCE -Wall -Wno-nonnull -Isrc/include $(CFLAGS)
+ 
+ PYLIB  := $(shell python -c 'import distutils.sysconfig;  print distutils.sysconfig.get_python_lib()')
+ 
diff --git a/patches/rt-tests-0.73/series b/patches/rt-tests-0.73/series
index 74fbce0..caf1a74 100644
--- a/patches/rt-tests-0.73/series
+++ b/patches/rt-tests-0.73/series
@@ -1 +1,2 @@
 fix_3_0_issue.diff
+add-extra-cflags.patch
diff --git a/rules/rt-tests.make b/rules/rt-tests.make
index 3bc6568..1880beb 100644
--- a/rules/rt-tests.make
+++ b/rules/rt-tests.make
@@ -34,6 +34,7 @@ RT_TESTS_DIR		:= $(BUILDDIR)/$(RT_TESTS)
 
 RT_TESTS_CONF_TOOL	:= NO
 RT_TESTS_MAKE_OPT	:= $(CROSS_ENV_CC) prefix=/usr
+RT_TESTS_MAKE_ENV	:= $(CROSS_ENV_FLAGS)
 RT_TESTS_INSTALL_OPT	:= $(RT_TESTS_MAKE_OPT) install
 
 # ----------------------------------------------------------------------------
-- 
1.7.5.4


-- 
ptxdist mailing list
ptxdist@pengutronix.de

^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2012-03-15 11:52 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-03-13 21:32 [ptxdist] [PATCH 1/5 v2] [rt-tests] Use CFLAGS specified by ptxdist platformconfig Remy Bohmer
2012-03-13 21:32 ` [ptxdist] [PATCH 2/5 v2] [x86_64] Add some support for multilib detection in the toolchain Remy Bohmer
2012-03-13 21:32 ` [ptxdist] [PATCH 3/5 v2] [busybox] Pass extra platform CFLAGS to busybox make Remy Bohmer
2012-03-14 10:42   ` Michael Olbrich
2012-03-14 10:45     ` Michael Olbrich
2012-03-14 11:38       ` Remy Bohmer
2012-03-13 21:32 ` [ptxdist] [PATCH 4/5 v2] [x86_64, glibc] on multilib do not put all dynamic linkers in /lib Remy Bohmer
2012-03-13 21:32 ` [ptxdist] [PATCH 5/5 v2] [x86_64, glibc] Link /usr/lib/libdl.so is not needed and wrong on x86_64 Remy Bohmer
2012-03-15 10:31 ` [ptxdist] [PATCH 1/5 v2] [rt-tests] Use CFLAGS specified by ptxdist platformconfig Michael Olbrich
2012-03-15 11:52   ` Remy Bohmer

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox