1 |
commit: 5b3bd8ff50ff76c0c29c9b922658ef7c74aeffe7 |
2 |
Author: Sam James <sam <AT> gentoo <DOT> org> |
3 |
AuthorDate: Thu Apr 1 22:49:56 2021 +0000 |
4 |
Commit: Sam James <sam <AT> gentoo <DOT> org> |
5 |
CommitDate: Thu Apr 1 23:03:57 2021 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=5b3bd8ff |
7 |
|
8 |
media-libs/libsdl: fix (parallel) build with slibtool |
9 |
|
10 |
Patch is upstream for libsdl2 and will be for libsdl soon. |
11 |
|
12 |
Thanks-to: orbea <orbea <AT> riseup.net> |
13 |
Closes: https://bugs.gentoo.org/779445 |
14 |
Signed-off-by: Sam James <sam <AT> gentoo.org> |
15 |
|
16 |
.../libsdl/files/libsdl-1.2.15-slibtool.patch | 56 ++++++++++++++++++++++ |
17 |
media-libs/libsdl/libsdl-1.2.15_p20210224.ebuild | 1 + |
18 |
2 files changed, 57 insertions(+) |
19 |
|
20 |
diff --git a/media-libs/libsdl/files/libsdl-1.2.15-slibtool.patch b/media-libs/libsdl/files/libsdl-1.2.15-slibtool.patch |
21 |
new file mode 100644 |
22 |
index 00000000000..3066e9fc8b0 |
23 |
--- /dev/null |
24 |
+++ b/media-libs/libsdl/files/libsdl-1.2.15-slibtool.patch |
25 |
@@ -0,0 +1,56 @@ |
26 |
+https://bugs.gentoo.org/779445 |
27 |
+ |
28 |
+commit ed1030d9b6a98e06aa293d18c49da18169918b8b |
29 |
+Author: orbea <orbea@××××××.net> |
30 |
+Date: Tue Mar 30 18:57:37 2021 -0700 |
31 |
+ |
32 |
+ Fix the build with parallel make and slibtool. |
33 |
+ |
34 |
+ There is no dependency on the $(OBJECTS) files on the 'build' |
35 |
+ directory which causes slibtool to fail when the directory |
36 |
+ does not yet exist. GNU libtool avoids this by being slower |
37 |
+ than mkdir(1). |
38 |
+ |
39 |
+diff --git a/Makefile.in b/Makefile.in |
40 |
+index ab51035..90940d4 100644 |
41 |
+--- a/Makefile.in |
42 |
++++ b/Makefile.in |
43 |
+@@ -51,7 +51,7 @@ LT_RELEASE = @LT_RELEASE@ |
44 |
+ LT_REVISION = @LT_REVISION@ |
45 |
+ LT_LDFLAGS = -no-undefined -rpath $(DESTDIR)$(libdir) -release $(LT_RELEASE) -version-info $(LT_CURRENT):$(LT_REVISION):$(LT_AGE) |
46 |
+ |
47 |
+-all: $(srcdir)/configure Makefile $(objects) $(objects)/$(TARGET) $(objects)/$(SDLMAIN_TARGET) |
48 |
++all: $(srcdir)/configure Makefile $(objects)/$(TARGET) $(objects)/$(SDLMAIN_TARGET) |
49 |
+ |
50 |
+ $(srcdir)/configure: $(srcdir)/configure.in |
51 |
+ @echo "Warning, configure.in is out of date" |
52 |
+@@ -61,8 +61,9 @@ $(srcdir)/configure: $(srcdir)/configure.in |
53 |
+ Makefile: $(srcdir)/Makefile.in |
54 |
+ $(SHELL) config.status $@ |
55 |
+ |
56 |
+-$(objects): |
57 |
+- $(SHELL) $(auxdir)/mkinstalldirs $@ |
58 |
++$(objects)/.created: |
59 |
++ $(SHELL) $(auxdir)/mkinstalldirs $(objects) |
60 |
++ touch $@ |
61 |
+ |
62 |
+ .PHONY: all depend install install-bin install-hdrs install-lib install-data install-man uninstall uninstall-bin uninstall-hdrs uninstall-lib uninstall-data uninstall-man clean distclean dist |
63 |
+ depend: |
64 |
+@@ -71,6 +72,8 @@ depend: |
65 |
+ |
66 |
+ include $(depend) |
67 |
+ |
68 |
++$(OBJECTS) $(SDLMAIN_OBJECTS): $(objects)/.created |
69 |
++ |
70 |
+ $(objects)/$(TARGET): $(OBJECTS) |
71 |
+ $(LIBTOOL) --mode=link $(CC) -o $@ $^ $(LDFLAGS) $(EXTRA_LDFLAGS) $(LT_LDFLAGS) |
72 |
+ |
73 |
+@@ -88,7 +91,7 @@ install-hdrs: |
74 |
+ $(INSTALL) -m 644 $(srcdir)/include/$$file $(DESTDIR)$(includedir)/SDL/$$file; \ |
75 |
+ done |
76 |
+ $(INSTALL) -m 644 include/SDL_config.h $(DESTDIR)$(includedir)/SDL/SDL_config.h |
77 |
+-install-lib: $(objects) $(objects)/$(TARGET) $(objects)/$(SDLMAIN_TARGET) |
78 |
++install-lib: $(objects)/$(TARGET) $(objects)/$(SDLMAIN_TARGET) |
79 |
+ $(SHELL) $(auxdir)/mkinstalldirs $(DESTDIR)$(libdir) |
80 |
+ $(LIBTOOL) --mode=install $(INSTALL) $(objects)/$(TARGET) $(DESTDIR)$(libdir)/$(TARGET) |
81 |
+ $(LIBTOOL) --mode=install $(INSTALL) $(objects)/$(SDLMAIN_TARGET) $(DESTDIR)$(libdir)/$(SDLMAIN_TARGET) |
82 |
|
83 |
diff --git a/media-libs/libsdl/libsdl-1.2.15_p20210224.ebuild b/media-libs/libsdl/libsdl-1.2.15_p20210224.ebuild |
84 |
index 5e79c923cb0..4b61e3b581f 100644 |
85 |
--- a/media-libs/libsdl/libsdl-1.2.15_p20210224.ebuild |
86 |
+++ b/media-libs/libsdl/libsdl-1.2.15_p20210224.ebuild |
87 |
@@ -65,6 +65,7 @@ pkg_setup() { |
88 |
PATCHES=( |
89 |
"${FILESDIR}"/${PN}-$(ver_cut 1-3)-sdl-config.patch |
90 |
"${FILESDIR}"/${PN}-$(ver_cut 1-3)-gamma.patch |
91 |
+ "${FILESDIR}"/${PN}-$(ver_cut 1-3)-slibtool.patch |
92 |
) |
93 |
|
94 |
DOCS=( BUGS CREDITS README-SDL.txt TODO WhatsNew ) |