Gentoo Archives: gentoo-commits

From: Michael Haubenwallner <haubi@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/proj/prefix:master commit in: app-arch/bzip2/
Date: Thu, 28 Apr 2016 15:07:16
Message-Id: 1461855943.5306100a4e38cf250329ccbcbfaf94502c39913a.haubi@gentoo
1 commit: 5306100a4e38cf250329ccbcbfaf94502c39913a
2 Author: Michael Haubenwallner <michael.haubenwallner <AT> ssi-schaefer <DOT> com>
3 AuthorDate: Thu Apr 28 15:05:31 2016 +0000
4 Commit: Michael Haubenwallner <haubi <AT> gentoo <DOT> org>
5 CommitDate: Thu Apr 28 15:05:43 2016 +0000
6 URL: https://gitweb.gentoo.org/repo/proj/prefix.git/commit/?id=5306100a
7
8 bzip2-1.0.6-r7: Cygwin port
9
10 app-arch/bzip2/bzip2-1.0.6-r7.ebuild | 11 ++++++++++-
11 1 file changed, 10 insertions(+), 1 deletion(-)
12
13 diff --git a/app-arch/bzip2/bzip2-1.0.6-r7.ebuild b/app-arch/bzip2/bzip2-1.0.6-r7.ebuild
14 index d07ed3d..23a6674 100644
15 --- a/app-arch/bzip2/bzip2-1.0.6-r7.ebuild
16 +++ b/app-arch/bzip2/bzip2-1.0.6-r7.ebuild
17 @@ -55,6 +55,12 @@ src_prepare() {
18 sed -i -e '/^SONAME/s,=,=${EPREFIX}/lib/,' Makefile-libbz2_so || die "cannt set soname"
19 fi
20 fi
21 + if [[ ${CHOST} == *-cygwin* ]] ; then
22 + sed -i -e "s/-o libbz2\.so\.${PV}/-Wl,--out-implib=libbz2$(get_libname ${PV})/" \
23 + -e "s/-Wl,-soname -Wl,libbz2\.so\.1/-o cygbz2-${PV%%.*}.dll/" \
24 + -e "s/libbz2\.so/libbz2$(get_libname)/g" \
25 + Makefile-libbz2_so
26 + fi
27 }
28
29 bemake() {
30 @@ -81,7 +87,8 @@ multilib_src_compile() {
31 *)
32 bemake -f "${S}"/Makefile-libbz2_so all
33 # Make sure we link against the shared lib #504648
34 - ln -sf libbz2.so.${PV} libbz2.so
35 + [[ $(get_libname) != $(get_libname ${PV}) ]] &&
36 + ln -sf libbz2$(get_libname ${PV}) libbz2$(get_libname)
37 ;;
38 esac
39 bemake -f "${S}"/Makefile all LDFLAGS="${LDFLAGS} $(usex static -static '')"
40 @@ -97,7 +104,9 @@ multilib_src_install() {
41 # .x.x - SONAME some distros use #338321
42 # .x - SONAME Gentoo uses
43 dolib.so libbz2$(get_libname ${PV})
44 + [[ ${CHOST} == *-cygwin* ]] && dobin cygbz2-${PV%%.*}.dll
45 local v
46 + [[ $(get_libname) != $(get_libname ${PV}) ]] &&
47 for v in libbz2$(get_libname) libbz2$(get_libname ${PV%%.*}) libbz2$(get_libname ${PV%.*}) ; do
48 dosym libbz2$(get_libname ${PV}) /usr/$(get_libdir)/${v}
49 done