* [PATCH 1/3] configure: move toolchain init to a function
@ 2012-12-16 22:09 Mike Frysinger
2012-12-16 22:09 ` [PATCH 2/3] lib: include the Config file too Mike Frysinger
2012-12-16 22:09 ` [PATCH 3/3] configure: pull AR from the env too Mike Frysinger
0 siblings, 2 replies; 4+ messages in thread
From: Mike Frysinger @ 2012-12-16 22:09 UTC (permalink / raw)
To: stephen.hemminger, netdev; +Cc: jengelh
The layout of this file uses functions to update Config. Move the
toolchain logic to the same style to fix setting the vars in Config.
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
---
configure | 12 +++++++++---
1 file changed, 9 insertions(+), 3 deletions(-)
diff --git a/configure b/configure
index 9912114..ea1038d 100755
--- a/configure
+++ b/configure
@@ -2,14 +2,19 @@
# This is not an autconf generated configure
#
INCLUDE=${1:-"$PWD/include"}
-: ${PKG_CONFIG:=pkg-config}
-: ${CC=gcc}
-echo "PKG_CONFIG:=${PKG_CONFIG}" >>Config
# Make a temp directory in build tree.
TMPDIR=$(mktemp -d config.XXXXXX)
trap 'status=$?; rm -rf $TMPDIR; exit $status' EXIT HUP INT QUIT TERM
+check_toolchain()
+{
+: ${PKG_CONFIG:=pkg-config}
+: ${CC=gcc}
+echo "CC:=${CC}" >>Config
+echo "PKG_CONFIG:=${PKG_CONFIG}" >>Config
+}
+
check_atm()
{
cat >$TMPDIR/atmtest.c <<EOF
@@ -224,6 +229,7 @@ rm -f $TMPDIR/ipsettest.c $TMPDIR/ipsettest
}
echo "# Generated config based on" $INCLUDE >Config
+check_toolchain
echo "TC schedulers"
--
1.8.0
^ permalink raw reply related [flat|nested] 4+ messages in thread
* [PATCH 2/3] lib: include the Config file too
2012-12-16 22:09 [PATCH 1/3] configure: move toolchain init to a function Mike Frysinger
@ 2012-12-16 22:09 ` Mike Frysinger
2012-12-16 22:09 ` [PATCH 3/3] configure: pull AR from the env too Mike Frysinger
1 sibling, 0 replies; 4+ messages in thread
From: Mike Frysinger @ 2012-12-16 22:09 UTC (permalink / raw)
To: stephen.hemminger, netdev; +Cc: jengelh
The lib makefile doesn't include Config which means it misses
setting up toolchain vars that it includes.
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
---
lib/Makefile | 2 ++
1 file changed, 2 insertions(+)
diff --git a/lib/Makefile b/lib/Makefile
index bfbe672..a42b885 100644
--- a/lib/Makefile
+++ b/lib/Makefile
@@ -1,3 +1,5 @@
+include ../Config
+
CFLAGS += -fPIC
UTILOBJ=utils.o rt_names.o ll_types.o ll_proto.o ll_addr.o inet_proto.o
--
1.8.0
^ permalink raw reply related [flat|nested] 4+ messages in thread
* [PATCH 3/3] configure: pull AR from the env too
2012-12-16 22:09 [PATCH 1/3] configure: move toolchain init to a function Mike Frysinger
2012-12-16 22:09 ` [PATCH 2/3] lib: include the Config file too Mike Frysinger
@ 2012-12-16 22:09 ` Mike Frysinger
2012-12-17 17:14 ` Stephen Hemminger
1 sibling, 1 reply; 4+ messages in thread
From: Mike Frysinger @ 2012-12-16 22:09 UTC (permalink / raw)
To: stephen.hemminger, netdev; +Cc: jengelh
This matches the existing CC behavior.
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
---
configure | 2 ++
1 file changed, 2 insertions(+)
diff --git a/configure b/configure
index ea1038d..7c2db9b 100755
--- a/configure
+++ b/configure
@@ -10,7 +10,9 @@ trap 'status=$?; rm -rf $TMPDIR; exit $status' EXIT HUP INT QUIT TERM
check_toolchain()
{
: ${PKG_CONFIG:=pkg-config}
+: ${AR=ar}
: ${CC=gcc}
+echo "AR:=${AR}" >>Config
echo "CC:=${CC}" >>Config
echo "PKG_CONFIG:=${PKG_CONFIG}" >>Config
}
--
1.8.0
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH 3/3] configure: pull AR from the env too
2012-12-16 22:09 ` [PATCH 3/3] configure: pull AR from the env too Mike Frysinger
@ 2012-12-17 17:14 ` Stephen Hemminger
0 siblings, 0 replies; 4+ messages in thread
From: Stephen Hemminger @ 2012-12-17 17:14 UTC (permalink / raw)
To: Mike Frysinger; +Cc: stephen.hemminger, netdev, jengelh
On Sun, 16 Dec 2012 17:09:17 -0500
Mike Frysinger <vapier@gentoo.org> wrote:
> This matches the existing CC behavior.
>
> Signed-off-by: Mike Frysinger <vapier@gentoo.org>
> ---
> configure | 2 ++
> 1 file changed, 2 insertions(+)
>
> diff --git a/configure b/configure
> index ea1038d..7c2db9b 100755
> --- a/configure
> +++ b/configure
> @@ -10,7 +10,9 @@ trap 'status=$?; rm -rf $TMPDIR; exit $status' EXIT HUP INT QUIT TERM
> check_toolchain()
> {
> : ${PKG_CONFIG:=pkg-config}
> +: ${AR=ar}
> : ${CC=gcc}
> +echo "AR:=${AR}" >>Config
> echo "CC:=${CC}" >>Config
> echo "PKG_CONFIG:=${PKG_CONFIG}" >>Config
> }
All applied
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2012-12-17 17:15 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-12-16 22:09 [PATCH 1/3] configure: move toolchain init to a function Mike Frysinger
2012-12-16 22:09 ` [PATCH 2/3] lib: include the Config file too Mike Frysinger
2012-12-16 22:09 ` [PATCH 3/3] configure: pull AR from the env too Mike Frysinger
2012-12-17 17:14 ` Stephen Hemminger
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.