summaryrefslogtreecommitdiffstats
path: root/backends
diff options
context:
space:
mode:
authorOmar Sandoval <osandov@fb.com>2019-08-26 10:51:44 -0700
committerMark Wielaard <mark@klomp.org>2019-08-28 21:29:18 +0200
commit4fcb7ec9d788d09f1525a506e1cbe8a39fc1b8eb (patch)
treee148e7f62ceb2b792d668c43023f211dda2bc142 /backends
parent3a409a89fd0f4e2e125dc8dba73757928087252c (diff)
libcpu: merge libcpu_{i386,x86_64,bpf} into one library
In preparation for combining the libebl backend modules, combine all of the libcpu backends into libcpu.a. Signed-off-by: Omar Sandoval <osandov@fb.com>
Diffstat (limited to 'backends')
-rw-r--r--backends/ChangeLog4
-rw-r--r--backends/Makefile.am12
2 files changed, 7 insertions, 9 deletions
diff --git a/backends/ChangeLog b/backends/ChangeLog
index f1eaf14b..91790bb9 100644
--- a/backends/ChangeLog
+++ b/backends/ChangeLog
@@ -1,3 +1,7 @@
+2019-07-05 Omar Sandoval <osandov@fb.com>
+
+ * Makefile.am: Replace libcpu_{i386,x86_64,bpf}.a with libcpu.a.
+
2019-07-13 Mao Han <han_mao@c-sky.com>
* Makefile.am: Add C-SKY.
diff --git a/backends/Makefile.am b/backends/Makefile.am
index 175468f6..6470a313 100644
--- a/backends/Makefile.am
+++ b/backends/Makefile.am
@@ -44,6 +44,7 @@ noinst_LIBRARIES = $(libebl_pic)
noinst_DATA = $(libebl_pic:_pic.a=.so)
+libcpu = ../libcpu/libcpu.a
libelf = ../libelf/libelf.so
libdw = ../libdw/libdw.so
libeu = ../lib/libeu.a
@@ -51,7 +52,6 @@ libeu = ../lib/libeu.a
i386_SRCS = i386_init.c i386_symbol.c i386_corenote.c i386_cfi.c \
i386_retval.c i386_regs.c i386_auxv.c i386_syscall.c \
i386_initreg.c i386_unwind.c
-cpu_i386 = ../libcpu/libcpu_i386.a
libebl_i386_pic_a_SOURCES = $(i386_SRCS)
am_libebl_i386_pic_a_OBJECTS = $(i386_SRCS:.c=.os)
@@ -62,7 +62,6 @@ am_libebl_sh_pic_a_OBJECTS = $(sh_SRCS:.c=.os)
x86_64_SRCS = x86_64_init.c x86_64_symbol.c x86_64_corenote.c x86_64_cfi.c \
x86_64_retval.c x86_64_regs.c i386_auxv.c x86_64_syscall.c \
x86_64_initreg.c x86_64_unwind.c x32_corenote.c
-cpu_x86_64 = ../libcpu/libcpu_x86_64.a
libebl_x86_64_pic_a_SOURCES = $(x86_64_SRCS)
am_libebl_x86_64_pic_a_OBJECTS = $(x86_64_SRCS:.c=.os)
@@ -128,7 +127,6 @@ am_libebl_m68k_pic_a_OBJECTS = $(m68k_SRCS:.c=.os)
m68k_corenote_no_Wpacked_not_aligned = yes
bpf_SRCS = bpf_init.c bpf_regs.c bpf_symbol.c
-cpu_bpf = ../libcpu/libcpu_bpf.a
libebl_bpf_pic_a_SOURCES = $(bpf_SRCS)
am_libebl_bpf_pic_a_OBJECTS = $(bpf_SRCS:.c=.os)
@@ -142,20 +140,16 @@ csky_SRCS = csky_attrs.c csky_init.c csky_symbol.c csky_cfi.c \
libebl_csky_pic_a_SOURCES = $(csky_SRCS)
am_libebl_csky_pic_a_OBJECTS = $(csky_SRCS:.c=.os)
-libebl_%.so libebl_%.map: libebl_%_pic.a $(libelf) $(libdw) $(libeu)
+libebl_%.so libebl_%.map: libebl_%_pic.a $(libcpu) $(libelf) $(libdw) $(libeu)
@rm -f $(@:.so=.map)
$(AM_V_at)echo 'ELFUTILS_$(PACKAGE_VERSION) { global: $*_init; local: *; };' \
> $(@:.so=.map)
$(AM_V_CCLD)$(LINK) $(dso_LDFLAGS) -o $(@:.map=.so) \
- -Wl,--whole-archive $< $(cpu_$*) -Wl,--no-whole-archive \
+ -Wl,--whole-archive $< $(libcpu) -Wl,--no-whole-archive \
-Wl,--version-script,$(@:.so=.map),--no-undefined \
-Wl,--as-needed $(libelf) $(libdw) $(libeu)
@$(textrel_check)
-libebl_i386.so: $(cpu_i386)
-libebl_x86_64.so: $(cpu_x86_64)
-libebl_bpf.so: $(cpu_bpf)
-
install: install-am install-ebl-modules
install-ebl-modules:
$(mkinstalldirs) $(DESTDIR)$(libdir)/$(LIBEBL_SUBDIR)