From bdc8a14e0196f40d101200db4c68d7e5bc1c11c6 Mon Sep 17 00:00:00 2001 From: Helmut Pozimski Date: Mon, 27 Dec 2021 22:19:17 +0100 Subject: [PATCH] wine: add rpath patch from alpine for musl closes #34707 --- srcpkgs/wine/patches/musl-rpath.patch | 57 +++++++++++++++++++++++++++ srcpkgs/wine/template | 2 +- 2 files changed, 58 insertions(+), 1 deletion(-) create mode 100644 srcpkgs/wine/patches/musl-rpath.patch diff --git a/srcpkgs/wine/patches/musl-rpath.patch b/srcpkgs/wine/patches/musl-rpath.patch new file mode 100644 index 00000000000..768b34f3c91 --- /dev/null +++ b/srcpkgs/wine/patches/musl-rpath.patch @@ -0,0 +1,57 @@ +diff --git a/configure b/configure +index 774a95ce003..d408e77cc78 100755 +--- a/wine-7.0-rc3/configure ++++ b/wine-7.0-rc3/configure +@@ -11137,6 +11137,38 @@ fi + LIBWINE_DEPENDS="wine.map" + + TOP_INSTALL_LIB="$TOP_INSTALL_LIB libs/wine/libwine.so.$libwine_version libs/wine/libwine.so.$libwine_soversion" ++ ++ # do this at the end because it needs double dollar for makefile ++ as_ac_var=`printf "%s\n" "ac_cv_cflags_-Wl,-rpath,\\\\\\$ORIGIN" | $as_tr_sh` ++{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the compiler supports -Wl,-rpath,\\\$ORIGIN" >&5 ++printf %s "checking whether the compiler supports -Wl,-rpath,\\\$ORIGIN... " >&6; } ++if eval test \${$as_ac_var+y} ++then : ++ printf %s "(cached) " >&6 ++else $as_nop ++ ac_wine_try_cflags_saved=$CFLAGS ++CFLAGS="$CFLAGS -Wl,-rpath,\\\$ORIGIN" ++cat confdefs.h - <<_ACEOF >conftest.$ac_ext ++/* end confdefs.h. */ ++int main(int argc, char **argv) { return 0; } ++_ACEOF ++if ac_fn_c_try_link "$LINENO" ++then : ++ eval "$as_ac_var=yes" ++else $as_nop ++ eval "$as_ac_var=no" ++fi ++rm -f core conftest.err conftest.$ac_objext conftest.beam \ ++ conftest$ac_exeext conftest.$ac_ext ++CFLAGS=$ac_wine_try_cflags_saved ++fi ++eval ac_res=\$$as_ac_var ++ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 ++printf "%s\n" "$ac_res" >&6; } ++if eval test \"x\$"$as_ac_var"\" = x"yes" ++then : ++ UNIXLDFLAGS="$UNIXLDFLAGS '-Wl,-rpath,\$\$ORIGIN'" ++fi + ;; + esac + +diff --git a/configure.ac b/configure.ac +index 8c5066a3de6..01ede86df1e 100644 +--- a/wine-7.0-rc3/configure.ac ++++ b/wine-7.0-rc3/configure.ac +@@ -916,6 +916,9 @@ case $host_os in + AC_SUBST(LIBWINE_SHAREDLIB,"libwine.so.$libwine_version") + AC_SUBST(LIBWINE_DEPENDS,"wine.map") + TOP_INSTALL_LIB="$TOP_INSTALL_LIB libs/wine/libwine.so.$libwine_version libs/wine/libwine.so.$libwine_soversion" ++ ++ # do this at the end because it needs double dollar for makefile ++ WINE_TRY_CFLAGS([-Wl,-rpath,\\\$ORIGIN],[UNIXLDFLAGS="$UNIXLDFLAGS '-Wl,-rpath,\$\$ORIGIN'"]) + ;; + esac + diff --git a/srcpkgs/wine/template b/srcpkgs/wine/template index dbaf40e8291..b6833784f39 100644 --- a/srcpkgs/wine/template +++ b/srcpkgs/wine/template @@ -1,7 +1,7 @@ # Template file for 'wine' pkgname=wine version=7.0rc3 -revision=1 +revision=2 _pkgver=${version/r/-r} create_wrksrc=yes build_wrksrc=wine-${_pkgver}