1 |
slyfox 12/03/03 17:49:34 |
2 |
|
3 |
Added: xmms2-scrobbler-0.4.0-ld-order.patch |
4 |
xmms2-scrobbler-0.4.0-libs.patch |
5 |
xmms2-scrobbler-0.4.0-ldflags.patch |
6 |
Log: |
7 |
Initial ebuild by Alexander Tsoy (bug #341939). I slightly cleaned it and added --as-needed fixes. |
8 |
|
9 |
(Portage version: 2.2.0_alpha89_p3/cvs/Linux x86_64) |
10 |
|
11 |
Revision Changes Path |
12 |
1.1 media-sound/xmms2-scrobbler/files/xmms2-scrobbler-0.4.0-ld-order.patch |
13 |
|
14 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/media-sound/xmms2-scrobbler/files/xmms2-scrobbler-0.4.0-ld-order.patch?rev=1.1&view=markup |
15 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/media-sound/xmms2-scrobbler/files/xmms2-scrobbler-0.4.0-ld-order.patch?rev=1.1&content-type=text/plain |
16 |
|
17 |
Index: xmms2-scrobbler-0.4.0-ld-order.patch |
18 |
=================================================================== |
19 |
commit 096ee717070bdde9c1adc29f02fcb537920daca9 |
20 |
Author: Sergei Trofimovich <slyfox@g.o> |
21 |
Date: Sat Mar 3 20:24:21 2012 +0300 |
22 |
|
23 |
Makefile: set proper link order for libraries |
24 |
|
25 |
'-Wl,--as-needed' enforces libraries to go in proper dependency order: |
26 |
|
27 |
$ x86_64-pc-linux-gnu-gcc -Wl,-O1 -Wl,--as-needed -Wl,--hash-style=gnu -Wl,--hash-style=gnu `pkg-config xmms2-client --libs` `pkg-config libcurl --libs` src/xmms2-scrobbler.o src/list.o src/queue.o src/strbuf.o src/md5.o src/submission.o -o bin/xmms2-scrobbler |
28 |
src/xmms2-scrobbler.o: In function `save_profile_submissions_queue': |
29 |
xmms2-scrobbler.c:(.text+0x281): undefined reference to `xmmsc_userconfdir_get' |
30 |
src/xmms2-scrobbler.o: In function `load_config': |
31 |
xmms2-scrobbler.c:(.text+0x3e2): undefined reference to `xmmsc_userconfdir_get' |
32 |
src/xmms2-scrobbler.o: In function `maybe_submit_to_profile': |
33 |
xmms2-scrobbler.c:(.text+0x7e3): undefined reference to `xmmsc_medialib_get_info' |
34 |
xmms2-scrobbler.c:(.text+0x7f7): undefined reference to `xmmsc_result_notifier_set' |
35 |
|
36 |
Signed-off-by: Sergei Trofimovich <slyfox@g.o> |
37 |
|
38 |
diff --git a/Makefile b/Makefile |
39 |
index 7693bd2..4207cda 100644 |
40 |
--- a/Makefile |
41 |
+++ b/Makefile |
42 |
@@ -36,7 +36,7 @@ install: $(BINARY) |
43 |
install -m 755 $(BINARY) $(DESTDIR)$(PREFIX)/bin |
44 |
|
45 |
$(BINARY): $(OBJECTS) bin |
46 |
- $(QUIET_LINK)$(CC) $(OBJECTS) $(LDFLAGS) $(XMMS_LDFLAGS) $(CURL_LDFLAGS) -o $@ $(LIBS) |
47 |
+ $(QUIET_LINK)$(CC) $(OBJECTS) -o $@ $(LDFLAGS) $(XMMS_LDFLAGS) $(CURL_LDFLAGS) $(LIBS) |
48 |
|
49 |
src/%.o : src/%.c |
50 |
$(QUIET_CC)$(CC) $(CFLAGS) $(XMMS_CFLAGS) $(CURL_CFLAGS) $(ENDIAN_CFLAGS) -o $@ -c $< |
51 |
|
52 |
|
53 |
|
54 |
1.1 media-sound/xmms2-scrobbler/files/xmms2-scrobbler-0.4.0-libs.patch |
55 |
|
56 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/media-sound/xmms2-scrobbler/files/xmms2-scrobbler-0.4.0-libs.patch?rev=1.1&view=markup |
57 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/media-sound/xmms2-scrobbler/files/xmms2-scrobbler-0.4.0-libs.patch?rev=1.1&content-type=text/plain |
58 |
|
59 |
Index: xmms2-scrobbler-0.4.0-libs.patch |
60 |
=================================================================== |
61 |
diff --git a/Makefile b/Makefile |
62 |
index 3331e30..7693bd2 100644 |
63 |
--- a/Makefile |
64 |
+++ b/Makefile |
65 |
@@ -1,4 +1,5 @@ |
66 |
CFLAGS += -std=gnu99 -Wall -Wwrite-strings -pthread |
67 |
+LIBS = -lrt -lpthread |
68 |
ENDIAN_CFLAGS= |
69 |
PREFIX ?= /usr/local |
70 |
|
71 |
@@ -35,7 +36,7 @@ install: $(BINARY) |
72 |
install -m 755 $(BINARY) $(DESTDIR)$(PREFIX)/bin |
73 |
|
74 |
$(BINARY): $(OBJECTS) bin |
75 |
- $(QUIET_LINK)$(CC) $(OBJECTS) $(LDFLAGS) $(XMMS_LDFLAGS) $(CURL_LDFLAGS) -o $@ |
76 |
+ $(QUIET_LINK)$(CC) $(OBJECTS) $(LDFLAGS) $(XMMS_LDFLAGS) $(CURL_LDFLAGS) -o $@ $(LIBS) |
77 |
|
78 |
src/%.o : src/%.c |
79 |
$(QUIET_CC)$(CC) $(CFLAGS) $(XMMS_CFLAGS) $(CURL_CFLAGS) $(ENDIAN_CFLAGS) -o $@ -c $< |
80 |
|
81 |
|
82 |
|
83 |
1.1 media-sound/xmms2-scrobbler/files/xmms2-scrobbler-0.4.0-ldflags.patch |
84 |
|
85 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/media-sound/xmms2-scrobbler/files/xmms2-scrobbler-0.4.0-ldflags.patch?rev=1.1&view=markup |
86 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/media-sound/xmms2-scrobbler/files/xmms2-scrobbler-0.4.0-ldflags.patch?rev=1.1&content-type=text/plain |
87 |
|
88 |
Index: xmms2-scrobbler-0.4.0-ldflags.patch |
89 |
=================================================================== |
90 |
commit 8b97319c1a03acecc21b5608516859daaf5bca75 |
91 |
Author: James Le Cuirot <chewi@××××××××××××××.uk> |
92 |
Date: Fri Mar 26 20:10:54 2010 +0100 |
93 |
|
94 |
Fixed the build if the --as-needed linker option is enabled. |
95 |
|
96 |
diff --git a/Makefile b/Makefile |
97 |
index dad3fcb..3331e30 100644 |
98 |
--- a/Makefile |
99 |
+++ b/Makefile |
100 |
@@ -35,7 +35,7 @@ install: $(BINARY) |
101 |
install -m 755 $(BINARY) $(DESTDIR)$(PREFIX)/bin |
102 |
|
103 |
$(BINARY): $(OBJECTS) bin |
104 |
- $(QUIET_LINK)$(CC) $(LDFLAGS) $(XMMS_LDFLAGS) $(CURL_LDFLAGS) $(OBJECTS) -o $@ |
105 |
+ $(QUIET_LINK)$(CC) $(OBJECTS) $(LDFLAGS) $(XMMS_LDFLAGS) $(CURL_LDFLAGS) -o $@ |
106 |
|
107 |
src/%.o : src/%.c |
108 |
$(QUIET_CC)$(CC) $(CFLAGS) $(XMMS_CFLAGS) $(CURL_CFLAGS) $(ENDIAN_CFLAGS) -o $@ -c $< |