1 | #!/bin/sh |
---|
2 | |
---|
3 | # Copyright 2006, 2008, 2009, 2010, 2011, 2012, 2013, 2014, 2015, 2016 Patrick J. Volkerding, Sebeka, MN, USA |
---|
4 | # All rights reserved. |
---|
5 | # |
---|
6 | # Redistribution and use of this script, with or without modification, is |
---|
7 | # permitted provided that the following conditions are met: |
---|
8 | # |
---|
9 | # 1. Redistributions of this script must retain the above copyright |
---|
10 | # notice, this list of conditions and the following disclaimer. |
---|
11 | # |
---|
12 | # THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED |
---|
13 | # WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF |
---|
14 | # MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO |
---|
15 | # EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, |
---|
16 | # SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, |
---|
17 | # PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; |
---|
18 | # OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, |
---|
19 | # WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR |
---|
20 | # OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF |
---|
21 | # ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
---|
22 | |
---|
23 | ## build glibc-$VERSION for Slackware |
---|
24 | |
---|
25 | VERSION=${VERSION:-$(echo glibc-*.tar.xz | rev | cut -f 3- -d . | cut -f 1 -d - | rev)} |
---|
26 | CHECKOUT=${CHECKOUT:-""} |
---|
27 | BUILD=${BUILD:-2} |
---|
28 | |
---|
29 | # I was considering disabling NSCD, but MoZes talked me out of it. :) |
---|
30 | #DISABLE_NSCD=" --disable-nscd " |
---|
31 | |
---|
32 | # $ARCH may be preset, otherwise i586 compatibility with i686 binary |
---|
33 | # structuring is the Slackware default. |
---|
34 | if [ -z "$ARCH" ]; then |
---|
35 | case "$( uname -m )" in |
---|
36 | i?86) export ARCH=i586 ;; |
---|
37 | arm*) export ARCH=arm ;; |
---|
38 | # Unless $ARCH is already set, use uname -m for all other archs: |
---|
39 | *) export ARCH=$( uname -m ) ;; |
---|
40 | esac |
---|
41 | fi |
---|
42 | |
---|
43 | # I'll break this out as an option for fun :-) |
---|
44 | case $ARCH in |
---|
45 | i386) |
---|
46 | OPTIMIZ="-O3 -march=i386 -mcpu=i686" |
---|
47 | LIBDIRSUFFIX="" |
---|
48 | ;; |
---|
49 | i486) |
---|
50 | OPTIMIZ="-O3 -march=i486 -mtune=i686" |
---|
51 | LIBDIRSUFFIX="" |
---|
52 | ;; |
---|
53 | i586) |
---|
54 | OPTIMIZ="-O3 -march=i586 -mtune=i686" |
---|
55 | LIBDIRSUFFIX="" |
---|
56 | ;; |
---|
57 | i686) |
---|
58 | OPTIMIZ="-O3 -march=i686" |
---|
59 | LIBDIRSUFFIX="" |
---|
60 | ;; |
---|
61 | athlon) |
---|
62 | OPTIMIZ="-O3 -march=athlon" |
---|
63 | LIBDIRSUFFIX="" |
---|
64 | ;; |
---|
65 | s390) |
---|
66 | OPTIMIZ="-O3" |
---|
67 | LIBDIRSUFFIX="" |
---|
68 | ;; |
---|
69 | x86_64) |
---|
70 | OPTIMIZ="-O3 -fPIC" |
---|
71 | LIBDIRSUFFIX="64" |
---|
72 | ;; |
---|
73 | *) |
---|
74 | OPTIMIZ="-O3" |
---|
75 | LIBDIRSUFFIX="" |
---|
76 | ;; |
---|
77 | esac |
---|
78 | |
---|
79 | case $ARCH in |
---|
80 | x86_64) |
---|
81 | TARGET=${TARGET:-x86_64} |
---|
82 | ;; |
---|
83 | i586) |
---|
84 | # This should be i586 for all 32-bit x86 arch: |
---|
85 | TARGET=${TARGET:-i586} |
---|
86 | ;; |
---|
87 | esac |
---|
88 | |
---|
89 | # Hand off the $ARCH variable to $SLACKWARE_ARCH to avoid confusing glibc: |
---|
90 | SLACKWARE_ARCH=$ARCH |
---|
91 | unset ARCH |
---|
92 | |
---|
93 | CVSVER=${VERSION}${CHECKOUT} |
---|
94 | |
---|
95 | # NOTE!!! glibc needs to be built against the sanitized kernel headers, |
---|
96 | # which will be installed under /usr/include by the kernel-headers package. |
---|
97 | # Be sure the correct version of the headers package is installed BEFORE |
---|
98 | # building glibc! |
---|
99 | |
---|
100 | CWD=$(pwd) |
---|
101 | # Temporary build location. This should not be a directory |
---|
102 | # path a non-root user could create later... |
---|
103 | TMP=${TMP:-/glibc-tmp-$(mcookie)} |
---|
104 | mkdir -p $TMP |
---|
105 | |
---|
106 | NUMJOBS=${NUMJOBS:-" -j7 "} |
---|
107 | |
---|
108 | # This function fixes a doinst.sh file for x86_64. |
---|
109 | # With thanks to Fred Emmott. |
---|
110 | fix_doinst() { |
---|
111 | if [ "x$LIBDIRSUFFIX" = "x" ]; then |
---|
112 | return; |
---|
113 | fi; |
---|
114 | # Fix "( cd usr/lib ;" occurrences |
---|
115 | sed -i "s#lib ;#lib${LIBDIRSUFFIX} ;#" install/doinst.sh |
---|
116 | # Fix "lib/" occurrences |
---|
117 | sed -i "s#lib/#lib${LIBDIRSUFFIX}/#g" install/doinst.sh |
---|
118 | # Fix "( cd lib" occurrences |
---|
119 | sed -i "s#( cd lib\$#( cd lib${LIBDIRSUFFIX}#" install/doinst.sh |
---|
120 | |
---|
121 | if [ "$SLACKWARE_ARCH" = "x86_64" ]; then |
---|
122 | sed -i 's#ld-linux.so.2#ld-linux-x86-64.so.2#' install/doinst.sh |
---|
123 | fi |
---|
124 | } |
---|
125 | |
---|
126 | # This is a patch function to put all glibc patches in the build script |
---|
127 | # up near the top. |
---|
128 | apply_patches() { |
---|
129 | # Use old-style locale directories rather than a single (and strangely |
---|
130 | # formatted) /usr/lib/locale/locale-archive file: |
---|
131 | zcat $CWD/glibc.locale.no-archive.diff.gz | patch -p1 --verbose || exit 1 |
---|
132 | # The is_IS locale is causing a strange error about the "echn" command |
---|
133 | # not existing. This patch reverts is_IS to the version shipped in |
---|
134 | # glibc-2.5: |
---|
135 | zcat $CWD/is_IS.diff.gz | patch -p1 --verbose || exit 1 |
---|
136 | # Support ru_RU.CP1251 locale: |
---|
137 | zcat $CWD/glibc.ru_RU.CP1251.diff.gz | patch -p1 --verbose || exit 1 |
---|
138 | # This reverts a patch that was made to glibc to fix "namespace leakage", |
---|
139 | # which seems to cause some build failures (e.g. with conntrack): |
---|
140 | zcat $CWD/glibc.revert.to.fix.build.breakages.diff.gz | patch -p1 -l --verbose || exit 1 |
---|
141 | # Make it harder for people to trick ldd into running code: |
---|
142 | zcat $CWD/glibc.ldd.trace.through.dynamic.linker.diff.gz | patch -p1 --verbose || exit 1 |
---|
143 | # Add a C.UTF-8 locale: |
---|
144 | zcat $CWD/glibc-c-utf8-locale.patch.gz | patch -p1 --verbose || exit 1 |
---|
145 | } |
---|
146 | |
---|
147 | # This is going to be the initial $DESTDIR: |
---|
148 | export PKG=$TMP/package-glibc-incoming-tree |
---|
149 | PGLIBC=$TMP/package-glibc |
---|
150 | PSOLIBS=$TMP/package-glibc-solibs |
---|
151 | PI18N=$TMP/package-glibc-i18n |
---|
152 | PPROFILE=$TMP/package-glibc-profile |
---|
153 | PDEBUG=$TMP/package-glibc-debug |
---|
154 | |
---|
155 | # Empty these locations first: |
---|
156 | for dir in $PKG $PGLIBC $PSOLIBS $PZONE $PI18N $PPROFILE $PDEBUG ; do |
---|
157 | if [ -d $dir ]; then |
---|
158 | rm -rf $dir |
---|
159 | fi |
---|
160 | mkdir -p $dir |
---|
161 | done |
---|
162 | if [ -d $TMP/glibc-$VERSION ]; then |
---|
163 | rm -rf $TMP/glibc-$VERSION |
---|
164 | fi |
---|
165 | |
---|
166 | # Create an incoming directory structure for glibc to be built into: |
---|
167 | mkdir -p $PKG/lib${LIBDIRSUFFIX} |
---|
168 | mkdir -p $PKG/sbin |
---|
169 | mkdir -p $PKG/usr/bin |
---|
170 | mkdir -p $PKG/usr/lib${LIBDIRSUFFIX} |
---|
171 | mkdir -p $PKG/usr/sbin |
---|
172 | mkdir -p $PKG/usr/include |
---|
173 | mkdir -p $PKG/usr/doc |
---|
174 | mkdir -p $PKG/usr/man |
---|
175 | mkdir -p $PKG/usr/share |
---|
176 | mkdir -p $PKG/var/db/nscd |
---|
177 | mkdir -p $PKG/var/run/nscd |
---|
178 | |
---|
179 | # Begin extract/compile: |
---|
180 | cd $TMP |
---|
181 | rm -rf glibc-$CVSVER |
---|
182 | tar xvf $CWD/glibc-$CVSVER.tar.xz \ |
---|
183 | || tar xvf $CWD/glibc-$CVSVER.tar.bz2 \ |
---|
184 | || tar xvf $CWD/glibc-$CVSVER.tar.gz |
---|
185 | cd glibc-$CVSVER |
---|
186 | |
---|
187 | chown -R root:root . |
---|
188 | find . -perm 666 -exec chmod 644 {} \; |
---|
189 | find . -perm 664 -exec chmod 644 {} \; |
---|
190 | find . -perm 600 -exec chmod 644 {} \; |
---|
191 | find . -perm 444 -exec chmod 644 {} \; |
---|
192 | find . -perm 400 -exec chmod 644 {} \; |
---|
193 | find . -perm 440 -exec chmod 644 {} \; |
---|
194 | find . -perm 777 -exec chmod 755 {} \; |
---|
195 | find . -perm 775 -exec chmod 755 {} \; |
---|
196 | find . -perm 511 -exec chmod 755 {} \; |
---|
197 | find . -perm 711 -exec chmod 755 {} \; |
---|
198 | find . -perm 555 -exec chmod 755 {} \; |
---|
199 | |
---|
200 | # Clean up leftover CVS directories: |
---|
201 | find . -type d -name CVS -exec rm -r {} \; 2> /dev/null |
---|
202 | |
---|
203 | # Apply patches; exit if any fail. |
---|
204 | apply_patches |
---|
205 | if [ ! $? = 0 ]; then |
---|
206 | exit 1 |
---|
207 | fi |
---|
208 | |
---|
209 | # Make build directory: |
---|
210 | mkdir build-glibc-$VERSION |
---|
211 | cd build-glibc-$VERSION || exit 1 |
---|
212 | |
---|
213 | echo "BUILDING DAS NPTL GLIBC" |
---|
214 | CFLAGS="-g $OPTIMIZ" \ |
---|
215 | ../configure \ |
---|
216 | --prefix=/usr \ |
---|
217 | --libdir=/usr/lib${LIBDIRSUFFIX} \ |
---|
218 | --enable-kernel=2.6.32 \ |
---|
219 | --with-headers=/usr/include \ |
---|
220 | --enable-add-ons \ |
---|
221 | --enable-obsolete-rpc \ |
---|
222 | --enable-profile \ |
---|
223 | $DISABLE_NSCD \ |
---|
224 | --infodir=/usr/info \ |
---|
225 | --mandir=/usr/man \ |
---|
226 | --with-tls \ |
---|
227 | --with-__thread \ |
---|
228 | --without-cvs \ |
---|
229 | $TARGET-slackware-linux |
---|
230 | |
---|
231 | make $NUMJOBS || make || exit 1 |
---|
232 | make install install_root=$PKG || exit 1 |
---|
233 | make localedata/install-locales install_root=$PKG || exit 1 |
---|
234 | |
---|
235 | # The prevailing standard seems to be putting unstripped libraries in |
---|
236 | # /usr/lib/debug/ and stripping the debugging symbols from all the other |
---|
237 | # libraries. |
---|
238 | mkdir -p $PKG/usr/lib${LIBDIRSUFFIX}/debug |
---|
239 | cp -a $PKG/lib${LIBDIRSUFFIX}/l*.so* $PKG/usr/lib${LIBDIRSUFFIX}/debug |
---|
240 | cp -a $PKG/usr/lib${LIBDIRSUFFIX}/*.a $PKG/usr/lib${LIBDIRSUFFIX}/debug |
---|
241 | # Don't need debug+profile: |
---|
242 | ( cd $PKG/usr/lib${LIBDIRSUFFIX}/debug ; rm -f *_p.* ) |
---|
243 | # NOTE: Is there really a reason for the glibc-debug package? |
---|
244 | # If you're debugging glibc, you can also compile it, right? |
---|
245 | |
---|
246 | ## COMMENTED OUT: There's no reason for profile libs to include -g information. |
---|
247 | ## Put back unstripped profiling libraries: |
---|
248 | #mv $PKG/usr/lib${LIBDIRSUFFIX}/debug/*_p.a $PKG/usr/lib${LIBDIRSUFFIX} |
---|
249 | # It might be best to put the unstripped and profiling libraries in glibc-debug and glibc-profile. |
---|
250 | |
---|
251 | # I don't think "strip -g" causes the pthread problems. It's --strip-unneeded that does. |
---|
252 | strip -g $PKG/lib${LIBDIRSUFFIX}/l*.so* |
---|
253 | strip -g $PKG/usr/lib${LIBDIRSUFFIX}/l*.so* || true |
---|
254 | strip -g $PKG/usr/lib${LIBDIRSUFFIX}/lib*.a || true |
---|
255 | |
---|
256 | # Remove the rquota.x and rquota.h include files, as they are provided by |
---|
257 | # the quota package: |
---|
258 | rm -f $PKG/usr/include/rpcsvc/rquota.{h,x} |
---|
259 | |
---|
260 | # Back to the sources dir to add some files/docs: |
---|
261 | cd $TMP/glibc-$CVSVER |
---|
262 | |
---|
263 | # We'll automatically install the config file for the Name Server Cache Daemon. |
---|
264 | # Perhaps this should also have some commented-out startup code in rc.inet2... |
---|
265 | mkdir -p $PKG/etc |
---|
266 | cat nscd/nscd.conf > $PKG/etc/nscd.conf.new |
---|
267 | |
---|
268 | # Install docs: |
---|
269 | ( mkdir -p $PKG/usr/doc/glibc-$VERSION |
---|
270 | cp -a \ |
---|
271 | BUGS CONFORMANCE COPYING* INSTALL LICENSES NAMESPACE \ |
---|
272 | NEWS PROJECTS README* \ |
---|
273 | $PKG/usr/doc/glibc-$VERSION |
---|
274 | ) |
---|
275 | |
---|
276 | # Trim the NEWS file to omit ancient history: |
---|
277 | if [ -r NEWS ]; then |
---|
278 | DOCSDIR=$(echo $PKG/usr/doc/glibc-$VERSION) |
---|
279 | cat NEWS | head -n 1000 > $DOCSDIR/NEWS |
---|
280 | touch -r NEWS $DOCSDIR/NEWS |
---|
281 | fi |
---|
282 | |
---|
283 | # OK, there are some very old Linux standards that say that any binaries in a /bin or |
---|
284 | # /sbin directory (and the directories themselves) should be group bin rather than |
---|
285 | # group root, unless a specific group is really needed for some reason. |
---|
286 | # |
---|
287 | # I can't find any mention of this in more recent standards docs, and always thought |
---|
288 | # that it was pretty cosmetic anyway (hey, if there's a reason -- fill me in!), so |
---|
289 | # it's possible that this ownership change won't be followed in the near future |
---|
290 | # (it's a PITA, and causes many bug reports when the perms change is occasionally |
---|
291 | # forgotten). |
---|
292 | # |
---|
293 | # But, it's hard to get me to break old habits, so we'll continue the tradition here: |
---|
294 | # |
---|
295 | # No, no we won't. You know how we love to break traditions. |
---|
296 | |
---|
297 | # Strip most binaries: |
---|
298 | ( cd $PKG |
---|
299 | find . | xargs file | grep "executable" | grep ELF | cut -f 1 -d : | xargs strip --strip-debug 2> /dev/null |
---|
300 | find . | xargs file | grep "shared object" | grep ELF | cut -f 1 -d : | xargs strip -g 2> /dev/null |
---|
301 | ) |
---|
302 | |
---|
303 | # Fix info dir: |
---|
304 | rm $PKG/usr/info/dir |
---|
305 | gzip -9 $PKG/usr/info/* |
---|
306 | |
---|
307 | # This is junk |
---|
308 | rm $PKG/etc/ld.so.cache |
---|
309 | ( cd $PKG |
---|
310 | find . -name "*.orig" -exec rm {} \; |
---|
311 | ) |
---|
312 | |
---|
313 | ################################## |
---|
314 | # OK, time to make some packages # |
---|
315 | ################################## |
---|
316 | |
---|
317 | # glibc-profile: |
---|
318 | cd $PPROFILE |
---|
319 | mkdir -p usr/lib${LIBDIRSUFFIX} |
---|
320 | # Might as well just grab these with 'mv' to simplify things later: |
---|
321 | mv $PKG/usr/lib${LIBDIRSUFFIX}/lib*_p.a usr/lib${LIBDIRSUFFIX} |
---|
322 | # Profile libs should be stripped. Use the debug libs to debug... |
---|
323 | ( cd usr/lib${LIBDIRSUFFIX} ; strip -g *.a ) |
---|
324 | mkdir install |
---|
325 | cp -a $CWD/slack-desc.glibc-profile install/slack-desc |
---|
326 | makepkg -l y -c n $TMP/glibc-profile-$VERSION-$SLACKWARE_ARCH-$BUILD.txz |
---|
327 | |
---|
328 | # THIS IS NO LONGER PACKAGED (or is it? might be better to let it be made, and then ship it or not...) |
---|
329 | # glibc-debug: |
---|
330 | cd $PDEBUG |
---|
331 | mkdir -p usr/lib${LIBDIRSUFFIX} |
---|
332 | # Might as well just grab these with 'mv' to simplify things later: |
---|
333 | mv $PKG/usr/lib${LIBDIRSUFFIX}/debug usr/lib${LIBDIRSUFFIX} |
---|
334 | mkdir install |
---|
335 | cp -a $CWD/slack-desc.glibc-debug install/slack-desc |
---|
336 | makepkg -l y -c n $TMP/glibc-debug-$VERSION-$SLACKWARE_ARCH-$BUILD.txz |
---|
337 | ## INSTEAD, NUKE THESE LIBS |
---|
338 | #rm -rf $PKG/usr/lib${LIBDIRSUFFIX}/debug |
---|
339 | |
---|
340 | # glibc-i18n: |
---|
341 | cd $PI18N |
---|
342 | mkdir -p usr/lib${LIBDIRSUFFIX}/locale |
---|
343 | mv $PKG/usr/lib${LIBDIRSUFFIX}/locale/* usr/lib${LIBDIRSUFFIX}/locale |
---|
344 | mkdir -p usr/share/{i18n,locale} |
---|
345 | mv $PKG/usr/share/i18n/* usr/share/i18n |
---|
346 | mv $PKG/usr/share/locale/* usr/share/locale |
---|
347 | # Leave copies of the C, POSIX, and en_US locales in the main glibc package: |
---|
348 | cp -a usr/lib${LIBDIRSUFFIX}/locale/{C,en_US}* $PKG/usr/lib${LIBDIRSUFFIX}/locale |
---|
349 | mkdir -p $PKG/usr/share/i18n/locales |
---|
350 | cp -a usr/share/i18n/locales/{C,POSIX,en_US} $PKG/usr/share/i18n/locales |
---|
351 | mkdir install |
---|
352 | cp -a $CWD/slack-desc.glibc-i18n install/slack-desc |
---|
353 | makepkg -l y -c n $TMP/glibc-i18n-$VERSION-$SLACKWARE_ARCH-$BUILD.txz |
---|
354 | |
---|
355 | # glibc-solibs: |
---|
356 | cd $PSOLIBS |
---|
357 | mkdir -p etc/profile.d |
---|
358 | cp -a $CWD/profile.d/* etc/profile.d |
---|
359 | chown -R root:root etc |
---|
360 | chmod 755 etc/profile.d/* |
---|
361 | mkdir -p lib${LIBDIRSUFFIX} |
---|
362 | cp -a $PKG/lib${LIBDIRSUFFIX}/* lib${LIBDIRSUFFIX} |
---|
363 | ( cd lib${LIBDIRSUFFIX} |
---|
364 | mkdir incoming |
---|
365 | mv *so* incoming |
---|
366 | mv incoming/libSegFault.so . |
---|
367 | ) |
---|
368 | mkdir -p usr |
---|
369 | cp -a $PKG/usr/bin usr |
---|
370 | mv usr/bin/ldd . |
---|
371 | rm usr/bin/* |
---|
372 | mv ldd usr/bin |
---|
373 | mkdir -p usr/lib${LIBDIRSUFFIX} |
---|
374 | # The gconv directory has a lot of stuff, but including it here will save some problems. |
---|
375 | # Seems standard elsewhere. |
---|
376 | cp -a $PKG/usr/lib${LIBDIRSUFFIX}/gconv usr/lib${LIBDIRSUFFIX} |
---|
377 | # Another manpage abandoned by GNU... |
---|
378 | #mkdir -p usr/man/man1 |
---|
379 | #cp -a $PKG/usr/man/man1/ldd.1.gz usr/man/man1 |
---|
380 | mkdir -p usr/libexec |
---|
381 | #cp -a $PKG/usr/libexec/pt_chown usr/libexec |
---|
382 | # Same usr.bin deal: |
---|
383 | cp -a $PKG/sbin . |
---|
384 | mv sbin/ldconfig . |
---|
385 | rm sbin/* |
---|
386 | mv ldconfig sbin |
---|
387 | mkdir install |
---|
388 | cp -a $CWD/slack-desc.glibc-solibs install/slack-desc |
---|
389 | cp -a $CWD/doinst.sh-glibc-solibs install/doinst.sh |
---|
390 | fix_doinst |
---|
391 | sed -i "s/@@VERSION@@/$VERSION/g" install/doinst.sh |
---|
392 | # Ditch links: |
---|
393 | find . -type l -exec rm {} \; |
---|
394 | # Build the package: |
---|
395 | makepkg -l y -c n $TMP/glibc-solibs-$VERSION-$SLACKWARE_ARCH-$BUILD.txz |
---|
396 | |
---|
397 | # And finally, the complete "all-in-one" glibc package is created |
---|
398 | # from whatever was leftover: |
---|
399 | cd $PGLIBC |
---|
400 | mv $PKG/* . |
---|
401 | mkdir -p etc/profile.d |
---|
402 | cp -a $CWD/profile.d/* etc/profile.d |
---|
403 | chown -R root:root etc |
---|
404 | chmod 755 etc/profile.d/* |
---|
405 | # Ditch links (these are in doinst.sh-glibc): |
---|
406 | find . -type l -exec rm {} \; |
---|
407 | # libm.so is *not* a linker script on all $ARCH. |
---|
408 | # If it's missing now, replace the symlink: |
---|
409 | if [ ! -r usr/lib${LIBDIRSUFFIX}/libm.so ]; then |
---|
410 | ( cd usr/lib${LIBDIRSUFFIX} ; ln -sf ../../lib${LIBDIRSUFFIX}/libm.so.6 libm.so ) |
---|
411 | fi |
---|
412 | mkdir install |
---|
413 | cp -a $CWD/slack-desc.glibc install/slack-desc |
---|
414 | cp -a $CWD/doinst.sh-glibc install/doinst.sh |
---|
415 | fix_doinst |
---|
416 | sed -i "s/@@VERSION@@/$VERSION/g" install/doinst.sh |
---|
417 | ( cd lib${LIBDIRSUFFIX} |
---|
418 | mkdir incoming |
---|
419 | mv *so* incoming |
---|
420 | mv incoming/libSegFault.so . |
---|
421 | ) |
---|
422 | # Build the package: |
---|
423 | /sbin/makepkg -l y -c n $TMP/glibc-$VERSION-$SLACKWARE_ARCH-$BUILD.txz |
---|
424 | |
---|
425 | # Done! |
---|
426 | echo |
---|
427 | echo "glibc packages built in $TMP!" |
---|
428 | |
---|