]> rtime.felk.cvut.cz Git - coffee/buildroot.git/blob - package/libcap/0002-libcap-split-install-into-install-shared-install-sta.patch
lrzsz: install symlinks for XMODEM and YMODEM
[coffee/buildroot.git] / package / libcap / 0002-libcap-split-install-into-install-shared-install-sta.patch
1 From af21635665ab568f3333ff9fe8b474f4950e5acb Mon Sep 17 00:00:00 2001
2 From: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
3 Date: Sun, 6 Mar 2016 22:53:24 +0100
4 Subject: [PATCH] libcap: split install into install-shared/install-static
5
6 In order to support static only builds, split the install target into
7 install-shared and install-static targets.
8
9 Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
10 [yann.morin.1998@free.fr: install the .pc file in the common rule]
11 Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
12
13 diff --git a/libcap/Makefile b/libcap/Makefile
14 index d189777..44ddb27 100644
15 --- a/libcap/Makefile
16 +++ b/libcap/Makefile
17 @@ -62,19 +62,25 @@ $(MINLIBNAME): $(OBJS)
18  cap_text.o: cap_text.c $(USE_GPERF_OUTPUT) $(INCLS)
19         $(CC) $(CFLAGS) $(IPATH) $(INCLUDE_GPERF_OUTPUT) -c $< -o $@
20  
21 -install: all
22 +install: install-shared install-static
23 +
24 +install-common:
25         mkdir -p -m 0755 $(FAKEROOT)$(INCDIR)/sys
26         install -m 0644 include/sys/capability.h $(FAKEROOT)$(INCDIR)/sys
27 +       mkdir -p -m 0755 $(FAKEROOT)$(PKGCONFIGDIR)
28 +       install -m 0644 libcap.pc $(FAKEROOT)$(PKGCONFIGDIR)/libcap.pc
29 +
30 +install-static: $(STALIBNAME) install-common
31         mkdir -p -m 0755 $(FAKEROOT)$(LIBDIR)
32         install -m 0644 $(STALIBNAME) $(FAKEROOT)$(LIBDIR)/$(STALIBNAME)
33 +
34 +install-shared: $(MINLIBNAME) install-common
35         install -m 0644 $(MINLIBNAME) $(FAKEROOT)$(LIBDIR)/$(MINLIBNAME)
36         ln -sf $(MINLIBNAME) $(FAKEROOT)$(LIBDIR)/$(MAJLIBNAME)
37         ln -sf $(MAJLIBNAME) $(FAKEROOT)$(LIBDIR)/$(LIBNAME)
38  ifeq ($(FAKEROOT),)
39         -/sbin/ldconfig
40  endif
41 -       mkdir -p -m 0755 $(FAKEROOT)$(PKGCONFIGDIR)
42 -       install -m 0644 libcap.pc $(FAKEROOT)$(PKGCONFIGDIR)/libcap.pc
43  
44  clean:
45         $(LOCALCLEAN)
46 -- 
47 1.9.1
48