summaryrefslogtreecommitdiff
path: root/Rules.mak
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2006-01-13 08:52:26 +0000
committerMike Frysinger <vapier@gentoo.org>2006-01-13 08:52:26 +0000
commitd874cc673a85fe328b37d59e84d7f7716417a7e5 (patch)
tree9a65271cdd9e440f461bf714b238b26764bac6c3 /Rules.mak
parentf64bd7d9800a934c07c74ed4c70c7e53784b3603 (diff)
fix up ability to rename ldso
Diffstat (limited to 'Rules.mak')
-rw-r--r--Rules.mak39
1 files changed, 21 insertions, 18 deletions
diff --git a/Rules.mak b/Rules.mak
index c46affa8b..41cc0c22b 100644
--- a/Rules.mak
+++ b/Rules.mak
@@ -49,6 +49,22 @@ BUILD_CFLAGS = -O2 -Wall
# Nothing beyond this point should ever be touched by mere
# mortals. Unless you hang out with the gods, you should
# probably leave all this stuff alone.
+
+# Pull in the user's uClibc configuration
+ifeq ($(filter $(noconfig_targets),$(MAKECMDGOALS)),)
+-include $(top_builddir).config
+endif
+
+# Make certain these contain a final "/", but no "//"s.
+TARGET_ARCH:=$(shell grep -s '^TARGET_ARCH' $(top_builddir)/.config | sed -e 's/^TARGET_ARCH=//' -e 's/"//g')
+TARGET_ARCH:=$(strip $(subst ",, $(strip $(TARGET_ARCH))))
+RUNTIME_PREFIX:=$(strip $(subst //,/, $(subst ,/, $(subst ",, $(strip $(RUNTIME_PREFIX))))))
+DEVEL_PREFIX:=$(strip $(subst //,/, $(subst ,/, $(subst ",, $(strip $(DEVEL_PREFIX))))))
+KERNEL_SOURCE:=$(strip $(subst //,/, $(subst ,/, $(subst ",, $(strip $(KERNEL_SOURCE))))))
+export RUNTIME_PREFIX DEVEL_PREFIX KERNEL_SOURCE
+
+
+# Now config hard core
MAJOR_VERSION := 0
MINOR_VERSION := 9
SUBLEVEL := 28
@@ -59,7 +75,11 @@ export MAJOR_VERSION MINOR_VERSION SUBLEVEL VERSION LC_ALL
LIBC := libc
SHARED_MAJORNAME := $(LIBC).so.$(MAJOR_VERSION)
-UCLIBC_LDSO := ld-uClibc.so.$(MAJOR_VERSION)
+UCLIBC_LDSO_NAME := ld-uClibc
+ifeq ($(TARGET_ARCH),x86_64)
+UCLIBC_LDSO_NAME := ld64-uClibc
+endif
+UCLIBC_LDSO := $(UCLIBC_LDSO_NAME).so.$(MAJOR_VERSION)
NONSHARED_LIBNAME := uclibc_nonshared.a
libc := $(top_builddir)lib/$(SHARED_MAJORNAME)
interp := $(top_builddir)lib/interp.os
@@ -75,11 +95,6 @@ ifndef PREFIX
PREFIX = $(DESTDIR)
endif
-# Pull in the user's uClibc configuration
-ifeq ($(filter $(noconfig_targets),$(MAKECMDGOALS)),)
--include $(top_builddir).config
-endif
-
ifneq ($(HAVE_SHARED),y)
libc :=
endif
@@ -107,14 +122,6 @@ SECHO=-@false
SHELL_SET_X=set +x
endif
-# Make certain these contain a final "/", but no "//"s.
-TARGET_ARCH:=$(shell grep -s '^TARGET_ARCH' $(top_builddir)/.config | sed -e 's/^TARGET_ARCH=//' -e 's/"//g')
-TARGET_ARCH:=$(strip $(subst ",, $(strip $(TARGET_ARCH))))
-RUNTIME_PREFIX:=$(strip $(subst //,/, $(subst ,/, $(subst ",, $(strip $(RUNTIME_PREFIX))))))
-DEVEL_PREFIX:=$(strip $(subst //,/, $(subst ,/, $(subst ",, $(strip $(DEVEL_PREFIX))))))
-KERNEL_SOURCE:=$(strip $(subst //,/, $(subst ,/, $(subst ",, $(strip $(KERNEL_SOURCE))))))
-export RUNTIME_PREFIX DEVEL_PREFIX KERNEL_SOURCE
-
ARFLAGS:=cr
OPTIMIZATION:=
@@ -253,10 +260,6 @@ ifeq ($(TARGET_ARCH),frv)
UCLIBC_LDSO=ld.so.1
endif
-ifeq ($(TARGET_ARCH),x86_64)
- UCLIBC_LDSO := ld64-uClibc.so.$(MAJOR_VERSION)
-endif
-
# Keep the check_gcc from being needlessly executed
ifndef PIEFLAG
ifneq ($(UCLIBC_BUILD_PIE),y)