diff options
author | Brad Bishop <bradleyb@fuzziesquirrel.com> | 2016-05-26 10:47:17 -0400 |
---|---|---|
committer | Stewart Smith <stewart@linux.vnet.ibm.com> | 2016-07-12 11:15:13 +1000 |
commit | 9d63bf7589cd9c488e4060703942d4ec2d0302da (patch) | |
tree | 3ba1bb59005bbd65a9c9dae9205978304b4c14f2 | |
parent | 3c94e203cd9cb5cdaa8cae2a1d210976fc45b6a7 (diff) | |
download | skiboot-9d63bf7589cd9c488e4060703942d4ec2d0302da.zip skiboot-9d63bf7589cd9c488e4060703942d4ec2d0302da.tar.gz skiboot-9d63bf7589cd9c488e4060703942d4ec2d0302da.tar.bz2 |
external: Create shared rules.mk
Building a dynamically linked pflash will need the shared library
name. Export it here.
Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
Signed-off-by: Stewart Smith <stewart@linux.vnet.ibm.com>
(cherry picked from commit 45e548176e16ad8ba9540fcd75131ba4993e42b7)
Signed-off-by: Stewart Smith <stewart@linux.vnet.ibm.com>
-rw-r--r-- | external/shared/Makefile | 9 | ||||
-rw-r--r-- | external/shared/rules.mk | 1 |
2 files changed, 5 insertions, 5 deletions
diff --git a/external/shared/Makefile b/external/shared/Makefile index b96c662..c643666 100644 --- a/external/shared/Makefile +++ b/external/shared/Makefile @@ -1,13 +1,12 @@ .DEFAULT_GOAL := all GET_ARCH = ../../external/common/get_arch.sh include ../../external/common/rules.mk +include rules.mk PREFIX ?= /usr/local/ LIBDIR = $(PREFIX)/lib INCDIR = $(PREFIX)/include/libflash -VERSION = $(shell ../../make_version.sh) - ifneq ($(ARCH), ARCH_ARM) CFLAGS += -m64 endif @@ -30,11 +29,11 @@ distclean: clean rm -f ccan libflash common all: links arch_links $(OBJS) - $(CC) -shared -Wl,-soname,libflash.so -o libflash.so.$(VERSION) $(OBJS) + $(CC) -shared -Wl,-soname,libflash.so -o $(SHARED_NAME) $(OBJS) install-lib: all - install -D -m 0755 libflash.so.$(VERSION) $(LIBDIR)/libflash.so.$(VERSION) - ln -sf libflash.so.$(VERSION) $(LIBDIR)/libflash.so + install -D -m 0755 $(SHARED_NAME) $(LIBDIR)/$(SHARED_NAME) + ln -sf $(SHARED_NAME) $(LIBDIR)/libflash.so install-dev: links arch_links mkdir -p $(INCDIR) diff --git a/external/shared/rules.mk b/external/shared/rules.mk new file mode 100644 index 0000000..a4976a1 --- /dev/null +++ b/external/shared/rules.mk @@ -0,0 +1 @@ +SHARED_NAME=libflash.so.$(shell ../../make_version.sh) |