/[packages]/cauldron/zlib/current/SOURCES/zlib-1.2.5-multibuild.patch
ViewVC logotype

Contents of /cauldron/zlib/current/SOURCES/zlib-1.2.5-multibuild.patch

Parent Directory Parent Directory | Revision Log Revision Log


Revision 448 - (show annotations) (download)
Sat Jan 8 10:00:21 2011 UTC (10 years, 11 months ago) by blino
File size: 4132 byte(s)
imported package zlib
1 --- zlib-1.2.5/configure.multibuild~ 2010-04-20 06:15:19.000000000 +0200
2 +++ zlib-1.2.5/configure 2010-11-29 19:18:30.027409816 +0100
3 @@ -18,12 +18,13 @@ if [ -n "${CHOST}" ]; then
4 CROSS_PREFIX="${CHOST}-"
5 fi
6
7 +top_srcdir=`dirname $0`
8 STATICLIB=libz.a
9 LDFLAGS="${LDFLAGS} -L. ${STATICLIB}"
10 -VER=`sed -n -e '/VERSION "/s/.*"\(.*\)".*/\1/p' < zlib.h`
11 -VER3=`sed -n -e '/VERSION "/s/.*"\([0-9]*\\.[0-9]*\\.[0-9]*\).*/\1/p' < zlib.h`
12 -VER2=`sed -n -e '/VERSION "/s/.*"\([0-9]*\\.[0-9]*\)\\..*/\1/p' < zlib.h`
13 -VER1=`sed -n -e '/VERSION "/s/.*"\([0-9]*\)\\..*/\1/p' < zlib.h`
14 +VER=`sed -n -e '/VERSION "/s/.*"\(.*\)".*/\1/p' < $top_srcdir/zlib.h`
15 +VER3=`sed -n -e '/VERSION "/s/.*"\([0-9]*\\.[0-9]*\\.[0-9]*\).*/\1/p' < $top_srcdir/zlib.h`
16 +VER2=`sed -n -e '/VERSION "/s/.*"\([0-9]*\\.[0-9]*\)\\..*/\1/p' < $top_srcdir/zlib.h`
17 +VER1=`sed -n -e '/VERSION "/s/.*"\([0-9]*\)\\..*/\1/p' < $top_srcdir/zlib.h`
18 if "${CROSS_PREFIX}ar" --version >/dev/null 2>/dev/null || test $? -lt 126; then
19 AR=${AR-"${CROSS_PREFIX}ar"}
20 test -n "${CROSS_PREFIX}" && echo Using ${AR}
21 @@ -118,7 +119,7 @@ if test "$gcc" -eq 1 && ($cc -c $cflags
22 uname=`(uname -s || echo unknown) 2>/dev/null`
23 fi
24 case "$uname" in
25 - Linux* | linux* | GNU | GNU/* | *BSD | DragonFly) LDSHARED=${LDSHARED-"$cc -shared -Wl,-soname,libz.so.1,--version-script,zlib.map"} ;;
26 + Linux* | linux* | GNU | GNU/* | *BSD | DragonFly) LDSHARED=${LDSHARED-"$cc -shared -Wl,-soname,libz.so.1,--version-script,$top_srcdir/zlib.map"} ;;
27 CYGWIN* | Cygwin* | cygwin* | OS/2*)
28 EXE='.exe' ;;
29 MINGW*|mingw*)
30 @@ -289,14 +290,14 @@ EOF
31 fi
32 fi
33
34 -cp -p zconf.h.in zconf.h
35 +cp -p $top_srcdir/zconf.h.in zconf.h
36
37 cat > $test.c <<EOF
38 #include <unistd.h>
39 int main() { return 0; }
40 EOF
41 if test "`($CC -c $CFLAGS $test.c) 2>&1`" = ""; then
42 - sed < zconf.h "/^#ifdef HAVE_UNISTD_H.* may be/s/def HAVE_UNISTD_H\(.*\) may be/ 1\1 was/" > zconf.temp.h
43 + sed < $top_srcdir/zconf.h "/^#ifdef HAVE_UNISTD_H.* may be/s/def HAVE_UNISTD_H\(.*\) may be/ 1\1 was/" > zconf.temp.h
44 mv zconf.temp.h zconf.h
45 echo "Checking for unistd.h... Yes."
46 else
47 @@ -546,7 +547,7 @@ esac
48 rm -f $test.[co] $test $test$shared_ext
49
50 # udpate Makefile
51 -sed < Makefile.in "
52 +sed < $top_srcdir/Makefile.in "
53 /^CC *=/s#=.*#=$CC#
54 /^CFLAGS *=/s#=.*#=$CFLAGS#
55 /^SFLAGS *=/s#=.*#=$SFLAGS#
56 @@ -572,7 +573,7 @@ sed < Makefile.in "
57 /^test: */s#:.*#: $TEST#
58 " > Makefile
59
60 -sed < zlib.pc.in "
61 +sed < $top_srcdir/zlib.pc.in "
62 /^CC *=/s#=.*#=$CC#
63 /^CFLAGS *=/s#=.*#=$CFLAGS#
64 /^CPP *=/s#=.*#=$CPP#
65 @@ -594,3 +595,10 @@ sed < zlib.pc.in "
66 " | sed -e "
67 s/\@VERSION\@/$VER/g;
68 " > zlib.pc
69 +
70 +# symlink sources
71 +if test "$top_srcdir" != "."; then
72 + for f in $top_srcdir/*.[ch]; do
73 + ln -s $f `basename $f`
74 + done
75 +fi
76 --- zlib-1.2.5/Makefile.in.multibuild~ 2010-04-20 06:12:21.000000000 +0200
77 +++ zlib-1.2.5/Makefile.in 2010-11-29 19:20:29.521423435 +0100
78 @@ -161,12 +161,10 @@ example64$(EXE): example64.o $(STATICLIB
79 minigzip64$(EXE): minigzip64.o $(STATICLIB)
80 $(CC) $(CFLAGS) -o $@ minigzip64.o $(TEST_LDFLAGS)
81
82 -install-libs: $(LIBS)
83 +install-libs-only: $(LIBS)
84 -@if [ ! -d $(DESTDIR)$(exec_prefix) ]; then mkdir -p $(DESTDIR)$(exec_prefix); fi
85 -@if [ ! -d $(DESTDIR)$(libdir) ]; then mkdir -p $(DESTDIR)$(libdir); fi
86 -@if [ ! -d $(DESTDIR)$(sharedlibdir) ]; then mkdir -p $(DESTDIR)$(sharedlibdir); fi
87 - -@if [ ! -d $(DESTDIR)$(man3dir) ]; then mkdir -p $(DESTDIR)$(man3dir); fi
88 - -@if [ ! -d $(DESTDIR)$(pkgconfigdir) ]; then mkdir -p $(DESTDIR)$(pkgconfigdir); fi
89 cp $(STATICLIB) $(DESTDIR)$(libdir)
90 cp $(SHAREDLIBV) $(DESTDIR)$(sharedlibdir)
91 cd $(DESTDIR)$(libdir); chmod u=rw,go=r $(STATICLIB)
92 @@ -178,6 +176,10 @@ install-libs: $(LIBS)
93 ln -s $(SHAREDLIBV) $(SHAREDLIBM); \
94 ($(LDCONFIG) || true) >/dev/null 2>&1; \
95 fi
96 +
97 +install-libs: install-libs-only
98 + -@if [ ! -d $(DESTDIR)$(man3dir) ]; then mkdir -p $(DESTDIR)$(man3dir); fi
99 + -@if [ ! -d $(DESTDIR)$(pkgconfigdir) ]; then mkdir -p $(DESTDIR)$(pkgconfigdir); fi
100 cp zlib.3 $(DESTDIR)$(man3dir)
101 chmod 644 $(DESTDIR)$(man3dir)/zlib.3
102 cp zlib.pc $(DESTDIR)$(pkgconfigdir)

  ViewVC Help
Powered by ViewVC 1.1.28