summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Makefile6
-rw-r--r--ldso/Makefile22
2 files changed, 14 insertions, 14 deletions
diff --git a/Makefile b/Makefile
index 82aa64ab3..52c6b3400 100644
--- a/Makefile
+++ b/Makefile
@@ -43,7 +43,7 @@ $(LIBNAME): subdirs
shared: $(LIBNAME)
@rm -rf tmp
@mkdir tmp
- @$(MAKE) -C ld.so-1 d-link
+ @$(MAKE) -C ld.so-1 ldso
@(cd tmp; CC=$(CC) /bin/sh ../extra/scripts/get-needed-libgcc-objects.sh)
if [ -s ./tmp/libgcc-need.a ] ; then \
$(CC) -g $(LDFLAGS) -shared -o $(SHARED_FULLNAME) \
@@ -60,7 +60,6 @@ shared: $(LIBNAME)
ln -sf $(SHARED_MAJORNAME) libc.so
@$(MAKE) -C crypt shared
@$(MAKE) -C ld.so-1
- echo "Using $(LDSO) for the shared library loader"
done: $(LIBNAME) $(DO_SHARED)
@echo
@@ -155,7 +154,8 @@ install_dev:
install_ldso:
ifeq ($(strip $(DO_SHARED)),shared)
- @$(MAKE) -C ld.so-1 install
+ $(MAKE) -C ld.so-1 install
+ install -d $(INSTALL_DIR)/etc
$(TOPDIR)ld.so-1/util/ldconfig
else
@echo "Skipping shared library support"
diff --git a/ldso/Makefile b/ldso/Makefile
index 314d22522..bfff102d2 100644
--- a/ldso/Makefile
+++ b/ldso/Makefile
@@ -5,22 +5,22 @@ SUBDIRS = util d-link libdl # man
all:
- @if [ -d d-link/$(TARGET_ARCH) ] ; then \
+ @if [ -d $(TOPDIR)ld.so-1/d-link/$(TARGET_ARCH) ] ; then \
set -e ; for d in $(SUBDIRS) ; do $(MAKE) -C $$d ; done \
fi;
install: all
- @if [ -d d-link/$(TARGET_ARCH) ] ; then \
- install -d $(INSTALL_DIR)/lib
- install -d $(INSTALL_DIR)/etc
- install -m 755 ./d-link/$(DLINKER).$(LDSO_VMAJOR) $(INSTALL_DIR)/lib/
- install -m 644 ./libdl/$(LIBDL).$(LDSO_VMAJOR) $(INSTALL_DIR)/lib/
- (cd $(INSTALL_DIR)/lib/;ln -sf $(DLINKER).$(LDSO_VMAJOR) $(DLINKER))
- (cd $(INSTALL_DIR)/lib/;ln -sf $(LIBDL).$(LDSO_VMAJOR) $(LIBDL))
+ if [ -d $(TOPDIR)ld.so-1/d-link/$(TARGET_ARCH) ] ; then \
+ install -d $(INSTALL_DIR)/lib $(INSTALL_DIR)/etc ; \
+ install -m 755 $(TOPDIR)ld.so-1/d-link/$(DLINKER).$(LDSO_VMAJOR) $(INSTALL_DIR)/lib/ ; \
+ install -m 644 $(TOPDIR)ld.so-1/libdl/$(LIBDL).$(LDSO_VMAJOR) $(INSTALL_DIR)/lib/ ; \
+ (cd $(INSTALL_DIR)/lib/;ln -sf $(DLINKER).$(LDSO_VMAJOR) $(DLINKER)) ; \
+ (cd $(INSTALL_DIR)/lib/;ln -sf $(LIBDL).$(LDSO_VMAJOR) $(LIBDL)) ; \
fi;
-d-link:
- @if [ -d d-link/$(TARGET_ARCH) ] ; then \
- do $(MAKE) -C d-link ; done \
+
+ldso:
+ @if [ -d $(TOPDIR)ld.so-1/d-link/$(TARGET_ARCH) ] ; then \
+ $(MAKE) -C d-link; \
fi;
clean: