aboutsummaryrefslogtreecommitdiff
path: root/elf/Makefile
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>1999-07-07 18:39:33 +0000
committerUlrich Drepper <drepper@redhat.com>1999-07-07 18:39:33 +0000
commit94e365c61202e2472c8aea42c7c95ce40f5b843c (patch)
tree15cf6a02604ab91d5aa1feeaeb338f0fc6b91f34 /elf/Makefile
parent2556bfe6fdb5ccb4864e0249d5fdd475e4100c71 (diff)
downloadglibc-94e365c61202e2472c8aea42c7c95ce40f5b843c.tar
glibc-94e365c61202e2472c8aea42c7c95ce40f5b843c.tar.gz
glibc-94e365c61202e2472c8aea42c7c95ce40f5b843c.tar.bz2
glibc-94e365c61202e2472c8aea42c7c95ce40f5b843c.zip
Update.
* sysdeps/gnu/Makefile (libdl-routines): Add eval. 1999-07-06 Zack Weinberg <zack@rabi.columbia.edu> * dlfcn: New directory. Move the following files from elf: dladdr.c, dlclose.c, dlerror.c, dlfcn.h, dlopen.c, dlopenold.c, dlsym.c, dlvsym.c. * dlfcn/Makefile: New file. * dlfcn/Versions: New file. * dlfcn/dlsym.c: All ELF-specific code split out to new function _dl_sym. * dlfcn/dlvsym.c: All ELF-specific code split out to new function _dl_vsym. * elf/dl-sym.c: New file. _dl_sym and _dl_vsym are implemented here. * dlfcn/dladdr.c: Remove all references to ELF data structures or headers. * dlfcn/dlclose.c: Likewise. * dlfcn/dlerror.c: Likewise. * dlfcn/dlopen.c: Likewise. * dlfcn/dlopenold.c: Likewise. * Makeconfig (dlfcn): New variable - set to `dlfcn' if elf is yes, empty otherwise. (libdl): Set to dlfcn/libdl.so or libdl.a if elf is yes, depending on build-shared. (subdirs): Add $(dlfcn). (rpath-dirs): Add dlfcn. * elf/Makefile: Remove all references to libdl or its components, except the ones relating to the test cases. (routines): Add dl-sym. * elf/Versions (libc): Add _dl_sym and _dl_vsym for GLIBC_2.2. (libdl): Delete. * elf/dl-close.c (_dl_close): Change argument to void *. * elf/dl-open.c (_dl_open): Change return type to void *. * elf/eval.c: Removed. * elf/ldsodefs.h: Move prototypes of _dl_catch_error, _dlerror_run, _dl_open, _dl_close, _dl_addr, and _dl_mcount_wrapper_check to include/dlfcn.h. Delete _CALL_DL_FCT macro. * include/dlfcn.h: Also prototype _dl_sym and _dl_vsym here. Include real header from dlfcn directory. * include/ldsodefs.h: Removed. * grp/initgroups.c: Use DL_CALL_FCT not _CALL_DL_FCT. * nss/getXXbyYY_r.c: Likewise. * nss/getXXent_r.c: Likewise. * iconv/gconv.c: Likewise. Don't include ldsodefs.h. * iconv/gconv_db.c: Likewise. Don't include ldsodefs.h. * iconv/skeleton.c: Don't include ldsodefs.h. * nss/nsswitch.h: Don't include ldsodefs.h. Include dlfcn.h. 1999-07-07 Ulrich Drepper <drepper@cygnus.com>
Diffstat (limited to 'elf/Makefile')
-rw-r--r--elf/Makefile47
1 files changed, 11 insertions, 36 deletions
diff --git a/elf/Makefile b/elf/Makefile
index b5145ea025..48012ee0c4 100644
--- a/elf/Makefile
+++ b/elf/Makefile
@@ -22,7 +22,7 @@ subdir := elf
headers = elf.h bits/elfclass.h bits/dlfcn.h link.h dlfcn.h
routines = $(dl-routines) dl-open dl-close dl-symbol dl-support \
- dl-addr enbl-secure dl-profstub dl-origin dl-libc
+ dl-addr enbl-secure dl-profstub dl-origin dl-libc dl-sym
# The core dynamic linking functions are in libc for the static and
# profiled libraries.
@@ -35,24 +35,16 @@ elide-routines.os = $(dl-routines) dl-support enbl-secure
# ld.so uses those routines, plus some special stuff for being the program
# interpreter and operating independent of libc.
rtld-routines := rtld $(dl-routines) dl-sysdep dl-environ dl-minimal
-distribute = $(rtld-routines:=.c) dynamic-link.h do-rel.h dl-machine.h \
- dl-hash.h soinit.c sofini.c ldd.bash.in eval.c \
- genrtldtbl.awk atomicity.h dl-procinfo.h ldsodefs.h \
- dl-librecon.h interp.c sln.c dl-dst.h hp-timing.h \
- testobj1.c testobj2.c testobj3.c testobj4.c testobj5.c \
- testobj6.c testobj1_1.c failobj.c do-lookup.h \
- gen-trusted-dirs.awk
+distribute := $(rtld-routines:=.c) dynamic-link.h do-rel.h dl-machine.h \
+ dl-hash.h soinit.c sofini.c ldd.bash.in \
+ genrtldtbl.awk atomicity.h dl-procinfo.h ldsodefs.h \
+ dl-librecon.h interp.c sln.c dl-dst.h hp-timing.h \
+ do-lookup.h sprof.c gen-trusted-dirs.awk \
+ testobj1.c testobj2.c testobj3.c testobj4.c testobj5.c \
+ testobj6.c testobj1_1.c failobj.c
include ../Makeconfig
-extra-libs = libdl
-extra-libs-others = $(extra-libs)
-libdl-routines := dlopen dlclose dlsym dlvsym dlerror dladdr
-ifeq ($(versioning),yes)
-libdl-routines += dlopenold
-libdl-shared-only-routines := dlopenold
-endif
-
before-compile = $(objpfx)trusted-dirs.h
ifeq ($(versioning),yes)
@@ -60,7 +52,7 @@ ld-map = $(common-objpfx)ld.so.map
endif
ifeq (yes,$(build-shared))
-extra-objs = $(rtld-routines:=.os) soinit.os sofini.os eval.os interp.os
+extra-objs = $(rtld-routines:=.os) soinit.os sofini.os interp.os
generated = librtld.os dl-allobjs.os ld.so trusted-dirs.h trusted-dirs.st
install-others = $(inst_slibdir)/$(rtld-installed-name)
install-bin = ldd
@@ -85,15 +77,8 @@ modules-names = testobj1 testobj2 testobj3 testobj4 testobj5 testobj6 \
testobj1_1 failobj
extra-objs += $(modules-names:=.os)
-ifeq ($(build-shared),yes)
-libdl = $(objpfx)libdl.so$(libdl.so-version)
-else
-libdl = $(objpfx)libdl.a
-endif
-
include ../Rules
-
ifeq (yes,$(build-shared))
# Make sure these things are built in the `make lib' pass so they can be used
# to run programs during the `make others' pass.
@@ -163,10 +148,6 @@ $(objpfx)trusted-dirs.st: Makefile $(..)Makeconfig
CPPFLAGS-dl-load.c = -I$(objpfx).
CFLAGS-dl-load.c += -Wno-uninitialized
-# Specify the dependencies of libdl.so; its commands come from the generic
-# rule to build a shared library.
-$(objpfx)libdl.so: $(objpfx)libdl_pic.a $(common-objpfx)libc.so $(objpfx)ld.so
-
ifeq (yes,$(build-shared))
$(inst_slibdir)/$(rtld-version-installed-name): $(objpfx)ld.so $(+force)
$(do-install-program)
@@ -209,9 +190,8 @@ $(objpfx)ldd: ldd.bash.in $(common-objpfx)soversions.mk \
chmod 555 $@.new
mv -f $@.new $@
-
$(objpfx)sprof: $(libdl)
-
+
test-modules = $(addprefix $(objpfx),$(addsuffix .so,$(modules-names)))
generated += $(addsuffix .so,$(modules-names))
@@ -251,14 +231,9 @@ $(objpfx)loadfail.out: $(objpfx)failobj.so
$(objpfx)multiload: $(libdl)
LDFLAGS-multiload = -rdynamic
-CFLAGS-multiload.c = -DOBJDIR=\"$(elf-objpfx)\"
+CFLAGS-multiload.c = -DOBJDIR=\"$(objpfx)\"
$(objpfx)multiload.out: $(objpfx)testobj1.so
$(objpfx)origtest: $(libdl)
$(objpfx)origtest.out: $(objpfx)testobj1.so
-
-# muwahaha
-
-LDFLAGS-dl.so = -Wl,-dynamic-linker,$(slibdir)/$(rtld-installed-name)
-$(objpfx)libdl.so: $(objpfx)eval.os