1 |
commit: 93fbed6e982f91eb32076fbf42c017cfcdd6c7ac |
2 |
Author: Maciej Barć <xgqt <AT> gentoo <DOT> org> |
3 |
AuthorDate: Fri Dec 31 00:11:18 2021 +0000 |
4 |
Commit: Maciej Barć <xgqt <AT> gentoo <DOT> org> |
5 |
CommitDate: Fri Dec 31 00:31:22 2021 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=93fbed6e |
7 |
|
8 |
app-shells/scsh: build only on 32bit arches; tests; format |
9 |
|
10 |
libcrypt/GCC not being 32bit/multilib bugs: |
11 |
- https://bugs.gentoo.org/589122 |
12 |
- https://bugs.gentoo.org/710570 |
13 |
- https://bugs.gentoo.org/830282 |
14 |
|
15 |
Thanks for patches: |
16 |
- SCSH_LIB_DIRS environment variable: |
17 |
adam <AT> michalik.es |
18 |
https://bugs.gentoo.org/413791#c0 |
19 |
- scheme48vm-prelude (for tests) |
20 |
https://bugs.gentoo.org/299414#c2 |
21 |
|
22 |
Closes: https://bugs.gentoo.org/299414 |
23 |
Closes: https://bugs.gentoo.org/413791 |
24 |
Closes: https://bugs.gentoo.org/589122 |
25 |
Closes: https://bugs.gentoo.org/710570 |
26 |
Closes: https://bugs.gentoo.org/722442 |
27 |
Closes: https://bugs.gentoo.org/830282 |
28 |
Signed-off-by: Maciej Barć <xgqt <AT> gentoo.org> |
29 |
|
30 |
app-shells/scsh/files/0.6.7-Makefile.in-AR.patch | 26 ++++++++++ |
31 |
...0.6.7-scheme48vm-prelude.h-SMALL_MULTIPLY.patch | 11 ++++ |
32 |
app-shells/scsh/scsh-0.6.7-r2.ebuild | 47 ------------------ |
33 |
app-shells/scsh/scsh-0.6.7-r3.ebuild | 58 ++++++++++++++++++++++ |
34 |
profiles/arch/amd64/no-multilib/package.mask | 1 + |
35 |
5 files changed, 96 insertions(+), 47 deletions(-) |
36 |
|
37 |
diff --git a/app-shells/scsh/files/0.6.7-Makefile.in-AR.patch b/app-shells/scsh/files/0.6.7-Makefile.in-AR.patch |
38 |
new file mode 100644 |
39 |
index 000000000000..b5dfea96b998 |
40 |
--- /dev/null |
41 |
+++ b/app-shells/scsh/files/0.6.7-Makefile.in-AR.patch |
42 |
@@ -0,0 +1,26 @@ |
43 |
+--- a/Makefile.in |
44 |
++++ b/Makefile.in |
45 |
+@@ -259,12 +259,12 @@ $(VM): c/main.o $(OBJS) $(UNIX_OBJS) $(LIBOBJS) $(EXTERNAL_OBJECTS) |
46 |
+ $(LIBCIG): c/main.o $(OBJS) |
47 |
+ # $(CC) -r -o $@ main.o $(OBJS) |
48 |
+ $(RM) $@ |
49 |
+- $(AR) $@ c/main.o $(OBJS) |
50 |
++ $(AR) qc $@ c/main.o $(OBJS) |
51 |
+ $(RANLIB) $@ |
52 |
+ |
53 |
+ $(LIBSCSHVM): c/smain.o $(OBJS) |
54 |
+ $(RM) $@ |
55 |
+- $(AR) $@ c/smain.o $(OBJS) |
56 |
++ $(AR) qc $@ c/smain.o $(OBJS) |
57 |
+ $(RANLIB) $@ |
58 |
+ |
59 |
+ $(LIBSCSH): $(OBJS) $(UNIX_OBJS) $(LIBOBJS) $(EXTERNAL_OBJECTS) |
60 |
+@@ -274,7 +274,7 @@ $(LIBSCSH): $(OBJS) $(UNIX_OBJS) $(LIBOBJS) $(EXTERNAL_OBJECTS) |
61 |
+ $(EXTERNAL_INITIALIZERS) && \ |
62 |
+ $(CC) -c $(CFLAGS) -o /tmp/s48_external_$$$$.o \ |
63 |
+ /tmp/s48_external_$$$$.c && \ |
64 |
+- $(AR) $@ $(OBJS) $(UNIX_OBJS) $(LIBOBJS) $(EXTERNAL_OBJECTS) \ |
65 |
++ $(AR) qc $@ $(OBJS) $(UNIX_OBJS) $(LIBOBJS) $(EXTERNAL_OBJECTS) \ |
66 |
+ /tmp/s48_external_$$$$.o && \ |
67 |
+ $(RANLIB) $@ && \ |
68 |
+ rm -f /tmp/s48_external_$$$$.c /tmp/s48_external_$$$$.o |
69 |
|
70 |
diff --git a/app-shells/scsh/files/0.6.7-scheme48vm-prelude.h-SMALL_MULTIPLY.patch b/app-shells/scsh/files/0.6.7-scheme48vm-prelude.h-SMALL_MULTIPLY.patch |
71 |
new file mode 100644 |
72 |
index 000000000000..98c904a67e9f |
73 |
--- /dev/null |
74 |
+++ b/app-shells/scsh/files/0.6.7-scheme48vm-prelude.h-SMALL_MULTIPLY.patch |
75 |
@@ -0,0 +1,11 @@ |
76 |
+--- a/c/scheme48vm-prelude.h |
77 |
++++ b/c/scheme48vm-prelude.h |
78 |
+@@ -5,7 +5,7 @@ |
79 |
+ #include "c-mods.h" |
80 |
+ #include "write-barrier.h" |
81 |
+ |
82 |
+-#define SMALL_MULTIPLY(x,y) ((x) * (y)) |
83 |
++#define SMALL_MULTIPLY(x,y) ((long)((unsigned long)(x) * (unsigned long)(y))) |
84 |
+ |
85 |
+ #define NO_ERRORS 0 /* extension to errno.h */ |
86 |
+ |
87 |
|
88 |
diff --git a/app-shells/scsh/scsh-0.6.7-r2.ebuild b/app-shells/scsh/scsh-0.6.7-r2.ebuild |
89 |
deleted file mode 100644 |
90 |
index 170f8f2f1eac..000000000000 |
91 |
--- a/app-shells/scsh/scsh-0.6.7-r2.ebuild |
92 |
+++ /dev/null |
93 |
@@ -1,47 +0,0 @@ |
94 |
-# Copyright 1999-2017 Gentoo Foundation |
95 |
-# Distributed under the terms of the GNU General Public License v2 |
96 |
- |
97 |
-EAPI=6 |
98 |
- |
99 |
-inherit multilib |
100 |
- |
101 |
-MY_PV="${PV%*.*}" |
102 |
- |
103 |
-DESCRIPTION="Unix shell embedded in Scheme" |
104 |
-HOMEPAGE="http://www.scsh.net/" |
105 |
-SRC_URI="ftp://ftp.scsh.net/pub/scsh/${MY_PV}/${P}.tar.gz" |
106 |
- |
107 |
-LICENSE="BSD" |
108 |
-SLOT="0" |
109 |
-KEYWORDS="amd64 ppc sparc x86" |
110 |
- |
111 |
-DEPEND="!dev-scheme/scheme48" |
112 |
-RDEPEND="${DEPEND}" |
113 |
- |
114 |
-PATCHES=( |
115 |
- "${FILESDIR}/${PV}-Makefile.in-doc-dir-gentoo.patch" |
116 |
- "${FILESDIR}/${PV}-Makefile.in-LDFLAGS.patch" |
117 |
- "${FILESDIR}/${PV}-Missing-includes.patch" |
118 |
-) |
119 |
- |
120 |
-RESTRICT="test" # some tests don't pass. |
121 |
- |
122 |
-src_prepare() { |
123 |
- default |
124 |
-} |
125 |
- |
126 |
-src_configure() { |
127 |
- use amd64 && multilib_toolchain_setup x86 |
128 |
- SCSH_LIB_DIRS="/usr/$(get_libdir)/${PN}" |
129 |
- econf \ |
130 |
- --libdir=/usr/$(get_libdir) \ |
131 |
- --includedir=/usr/include \ |
132 |
- --with-lib-dirs-list=${SCSH_LIB_DIRS} |
133 |
-} |
134 |
- |
135 |
-src_install() { |
136 |
- emake -j1 DESTDIR="${D}" install |
137 |
- local ENVD="${T}/50scsh" |
138 |
- echo "SCSH_LIB_DIRS=\"${SCSH_LIB_DIRS}\"" > "${ENVD}" || die |
139 |
- doenvd "${ENVD}" |
140 |
-} |
141 |
|
142 |
diff --git a/app-shells/scsh/scsh-0.6.7-r3.ebuild b/app-shells/scsh/scsh-0.6.7-r3.ebuild |
143 |
new file mode 100644 |
144 |
index 000000000000..26d0d047d90b |
145 |
--- /dev/null |
146 |
+++ b/app-shells/scsh/scsh-0.6.7-r3.ebuild |
147 |
@@ -0,0 +1,58 @@ |
148 |
+# Copyright 1999-2021 Gentoo Authors |
149 |
+# Distributed under the terms of the GNU General Public License v2 |
150 |
+ |
151 |
+# NOTICE: SCSH 0.6.7 is 32bit only |
152 |
+# https://bugs.gentoo.org/589122#c6 |
153 |
+ |
154 |
+EAPI=8 |
155 |
+ |
156 |
+inherit multilib |
157 |
+ |
158 |
+MY_PV="${PV%*.*}" |
159 |
+ |
160 |
+DESCRIPTION="Unix shell embedded in Scheme" |
161 |
+HOMEPAGE="https://www.scsh.net/" |
162 |
+SRC_URI="ftp://ftp.scsh.net/pub/scsh/${MY_PV}/${P}.tar.gz" |
163 |
+ |
164 |
+LICENSE="BSD" |
165 |
+SLOT="0" |
166 |
+KEYWORDS="amd64 ppc sparc x86" |
167 |
+ |
168 |
+RDEPEND=" |
169 |
+ !dev-scheme/scheme48 |
170 |
+ virtual/libcrypt:= |
171 |
+ amd64? ( virtual/libcrypt:=[abi_x86_32] ) |
172 |
+" |
173 |
+DEPEND="${RDEPEND}" |
174 |
+ |
175 |
+PATCHES=( |
176 |
+ "${FILESDIR}"/${PV}-Makefile.in-AR.patch |
177 |
+ "${FILESDIR}"/${PV}-Makefile.in-LDFLAGS.patch |
178 |
+ "${FILESDIR}"/${PV}-Makefile.in-doc-dir-gentoo.patch |
179 |
+ "${FILESDIR}"/${PV}-Missing-includes.patch |
180 |
+ "${FILESDIR}"/${PV}-scheme48vm-prelude.h-SMALL_MULTIPLY.patch |
181 |
+) |
182 |
+ |
183 |
+src_configure() { |
184 |
+ use amd64 && multilib_toolchain_setup x86 |
185 |
+ |
186 |
+ export SCSH_LIB_DIRS="/usr/$(get_libdir)/${PN}" |
187 |
+ |
188 |
+ local myconf=( |
189 |
+ --includedir=/usr/include |
190 |
+ --libdir=/usr/$(get_libdir) |
191 |
+ --with-lib-dirs-list=${SCSH_LIB_DIRS} |
192 |
+ ) |
193 |
+ econf "${myconf[@]}" |
194 |
+} |
195 |
+ |
196 |
+src_install() { |
197 |
+ emake -j1 DESTDIR="${D}" install |
198 |
+ |
199 |
+ # Fix doc install dir |
200 |
+ mv "${ED}/usr/share/doc/${PN}-${PV}" "${ED}/usr/share/doc/${PF}" || die |
201 |
+ |
202 |
+ local ENVD="${T}/50scsh" |
203 |
+ echo "SCSH_LIB_DIRS='\"${SCSH_LIB_DIRS}\"'" > "${ENVD}" || die |
204 |
+ doenvd "${ENVD}" |
205 |
+} |
206 |
|
207 |
diff --git a/profiles/arch/amd64/no-multilib/package.mask b/profiles/arch/amd64/no-multilib/package.mask |
208 |
index e4411cb89cb1..8ceefa57faa7 100644 |
209 |
--- a/profiles/arch/amd64/no-multilib/package.mask |
210 |
+++ b/profiles/arch/amd64/no-multilib/package.mask |
211 |
@@ -31,6 +31,7 @@ app-emulation/crossover-bin |
212 |
app-emulation/protontricks |
213 |
app-emulation/q4wine |
214 |
app-emulation/winetricks |
215 |
+<=app-shells/scsh-0.6.9 |
216 |
dev-embedded/libftd2xx |
217 |
dev-embedded/openocd |
218 |
dev-util/android-ndk |