summaryrefslogtreecommitdiffstats
path: root/meta/recipes-bsp/pciutils/pciutils-3.1.5/lib-build-fix.patch
diff options
context:
space:
mode:
authorRichard Purdie <rpurdie@linux.intel.com>2010-08-27 15:14:24 +0100
committerRichard Purdie <rpurdie@linux.intel.com>2010-08-27 15:29:45 +0100
commit29d6678fd546377459ef75cf54abeef5b969b5cf (patch)
tree8edd65790e37a00d01c3f203f773fe4b5012db18 /meta/recipes-bsp/pciutils/pciutils-3.1.5/lib-build-fix.patch
parentda49de6885ee1bc424e70bc02f21f6ab920efb55 (diff)
downloadpoky-29d6678fd546377459ef75cf54abeef5b969b5cf.tar.gz
Major layout change to the packages directory
Having one monolithic packages directory makes it hard to find things and is generally overwhelming. This commit splits it into several logical sections roughly based on function, recipes.txt gives more information about the classifications used. The opportunity is also used to switch from "packages" to "recipes" as used in OpenEmbedded as the term "packages" can be confusing to people and has many different meanings. Not all recipes have been classified yet, this is just a first pass at separating things out. Some packages are moved to meta-extras as they're no longer actively used or maintained. Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
Diffstat (limited to 'meta/recipes-bsp/pciutils/pciutils-3.1.5/lib-build-fix.patch')
-rw-r--r--meta/recipes-bsp/pciutils/pciutils-3.1.5/lib-build-fix.patch92
1 files changed, 92 insertions, 0 deletions
diff --git a/meta/recipes-bsp/pciutils/pciutils-3.1.5/lib-build-fix.patch b/meta/recipes-bsp/pciutils/pciutils-3.1.5/lib-build-fix.patch
new file mode 100644
index 0000000000..1e81f8401b
--- /dev/null
+++ b/meta/recipes-bsp/pciutils/pciutils-3.1.5/lib-build-fix.patch
@@ -0,0 +1,92 @@
1Link directly to lib/libpci.so.3.1.5 will hard code this versioned
2string into lspci and other utilities, which is not desirable and
3won't work. In the other hand, linking to a symbolic link lib/libpci.so
4doesn't have this issue.
5
67/30/2010 - created by Qing He <qing.he@intel.com>
7
8diff --git a/Makefile b/Makefile
9index 1b48e18..21af4b3 100644
10--- a/Makefile
11+++ b/Makefile
12@@ -51,9 +51,9 @@ PCIINC_INS=lib/config.h lib/header.h lib/pci.h lib/types.h
13
14 export
15
16-all: lib/$(PCILIB) lspci setpci example lspci.8 setpci.8 pcilib.7 update-pciids update-pciids.8 $(PCI_IDS) pcimodules pcimodules.8
17+all: lib/$(PCILIB_DEV) lspci setpci example lspci.8 setpci.8 pcilib.7 update-pciids update-pciids.8 $(PCI_IDS) pcimodules pcimodules.8
18
19-lib/$(PCILIB): $(PCIINC) force
20+lib/$(PCILIB) lib/$(PCILIB_DEV): $(PCIINC) force
21 $(MAKE) -C lib all
22
23 force:
24@@ -61,9 +61,9 @@ force:
25 lib/config.h lib/config.mk:
26 cd lib && ./configure
27
28-pcimodules: pcimodules.o common.o lib/$(PCILIB)
29-lspci: lspci.o ls-vpd.o ls-caps.o ls-ecaps.o ls-kernel.o ls-tree.o ls-map.o common.o lib/$(PCILIB)
30-setpci: setpci.o common.o lib/$(PCILIB)
31+pcimodules: pcimodules.o common.o lib/$(PCILIB_DEV)
32+lspci: lspci.o ls-vpd.o ls-caps.o ls-ecaps.o ls-kernel.o ls-tree.o ls-map.o common.o lib/$(PCILIB_DEV)
33+setpci: setpci.o common.o lib/$(PCILIB_DEV)
34
35 pcimodules.o: pcimodules.c pciutils.h
36 LSPCIINC=lspci.h pciutils.h $(PCIINC)
37@@ -83,7 +83,7 @@ update-pciids: update-pciids.sh
38 chmod +x $@
39
40 # The example of use of libpci
41-example: example.o lib/$(PCILIB)
42+example: example.o lib/$(PCILIB_DEV)
43 example.o: example.c $(PCIINC)
44
45 %: %.o
46diff --git a/lib/Makefile b/lib/Makefile
47index 1eb06a5..a8dab56 100644
48--- a/lib/Makefile
49+++ b/lib/Makefile
50@@ -42,7 +42,7 @@ ifdef PCI_HAVE_PM_NBSD_LIBPCI
51 OBJS += nbsd-libpci
52 endif
53
54-all: $(PCILIB) $(PCILIBPC)
55+all: $(PCILIB_DEV) $(PCILIBPC)
56
57 ifeq ($(SHARED),no)
58 $(PCILIB): $(addsuffix .o,$(OBJS))
59@@ -53,6 +53,9 @@ else
60 CFLAGS += -fPIC -fvisibility=hidden
61 $(PCILIB): $(addsuffix .o,$(OBJS))
62 $(CC) -shared $(LDFLAGS) $(SONAME) -Wl,--version-script=libpci.ver -o $@ $^ $(LIB_LDLIBS)
63+
64+$(PCILIB_DEV): $(PCILIB)
65+ ln -s $< $@
66 endif
67
68 $(PCILIBPC): libpci.pc.in
69diff --git a/lib/configure b/lib/configure
70index eec225a..4318b05 100755
71--- a/lib/configure
72+++ b/lib/configure
73@@ -174,16 +193,18 @@ fi
74 echo "Checking whether to build a shared library... $SHARED (set manually)"
75 if [ "$SHARED" = no ] ; then
76 echo >>$m 'PCILIB=$(LIBNAME).a'
77+ echo >>$m 'PCILIB_DEV=$(LIBNAME).a'
78 echo >>$m 'LDLIBS=$(WITH_LIBS)'
79 echo >>$m 'LIB_LDLIBS='
80 else
81 echo >>$m 'PCILIB=$(LIBNAME).so.$(VERSION)'
82+ echo >>$m 'PCILIB_DEV=$(LIBNAME).so'
83 # We link the dependencies _to_ the library, so we do not need explicit deps in .pc
84 echo >>$m 'LDLIBS='
85 echo >>$m 'LIB_LDLIBS=$(WITH_LIBS)'
86 echo >>$c '#define PCI_SHARED_LIB'
87 if [ "$SHARED" = yes ] ; then
88- echo >>$m 'SONAME=-Wl,-soname,$(LIBNAME).so$(ABI_VERSION)'
89+ echo >>$m 'SONAME=-Wl,-soname -Wl,$(LIBNAME).so$(ABI_VERSION)'
90 fi
91 fi
92 echo >>$m 'PCILIBPC=$(LIBNAME).pc'