Github messages for voidlinux
 help / color / mirror / Atom feed
From: iFoundSilentHouse <iFoundSilentHouse@users.noreply.github.com>
To: ml@inbox.vuxu.org
Subject: Re: [PR PATCH] [Updated] [WIP] wine: add aarch64 packaging
Date: Tue, 23 Apr 2024 10:04:22 +0200	[thread overview]
Message-ID: <20240423080422.6435721627@inbox.vuxu.org> (raw)
In-Reply-To: <gh-mailinglist-notifications-41a7ca26-5023-4802-975b-f1789d68868e-void-packages-49943@inbox.vuxu.org>

[-- Attachment #1: Type: text/plain, Size: 1384 bytes --]

There is an updated pull request by iFoundSilentHouse against master on the void-packages repository

https://github.com/iFoundSilentHouse/void-packages wine-9.6
https://github.com/void-linux/void-packages/pull/49943

[WIP] wine: add aarch64 packaging
What was added:
* aarch64 as new arch
* mingw is disabled as build option when target is aarch64 (there's no mingw cross package for aarch64)
* added wayland-devel, lld, clang, llvm17, when compiling cross without mingw. Added wayland-devel as member of makedepends. Clang build doesn't work without this. Not sure whether it's right place.
* wine-tools is disabled with no-mingw (clang) cross compilation (see below)
* minor tweaks for aarch64 building
* added wayland support
* added WoW64 support for aarch64 (see https://github.com/void-linux/void-packages/pull/49943#issuecomment-2069202421)

- I tested the changes in this PR: **NO**

Needs testing:
- [ ] 1) Native aarch64 testing with -Q build
- [ ] 2) Cross-built x86>aarch64 binaries
- [ ] 3) Cross-built aarch64>x86 binaries

- I built this PR locally for these architectures:
  - aarch64 (cross)
  - aarch64-musl (cross)
Build-install was successful but:
1) haven't figured out how to build wine-tools when cross-compiling with clang

@Hoshpak  @fvalasiad 

A patch file from https://github.com/void-linux/void-packages/pull/49943.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-wine-9.6-49943.patch --]
[-- Type: text/x-diff, Size: 3736 bytes --]

From b34be60d51d9ab89e05a40f46148989d63453fc9 Mon Sep 17 00:00:00 2001
From: iFoundSilentHouse <adeptslab@gmail.com>
Date: Mon, 22 Apr 2024 14:08:41 +0600
Subject: [PATCH] wine: add aarch64 packaging

---
 srcpkgs/wine/template | 44 +++++++++++++++++++++++++++++++++++--------
 1 file changed, 36 insertions(+), 8 deletions(-)

diff --git a/srcpkgs/wine/template b/srcpkgs/wine/template
index cbe0d1c0fc2ed9..68409a7e614918 100644
--- a/srcpkgs/wine/template
+++ b/srcpkgs/wine/template
@@ -1,12 +1,12 @@
 # Template file for 'wine'
 pkgname=wine
 version=9.7
-revision=1
+revision=2
 _pkgver=${version/r/-r}
 create_wrksrc=yes
 build_wrksrc=wine-${_pkgver}
 build_style=gnu-configure
-configure_args="--bindir=/usr/libexec/wine $(vopt_with xshm)"
+configure_args="--bindir=/usr/libexec/wine $(vopt_with xshm) --with-wayland"
 short_desc="Run Microsoft Windows applications"
 maintainer="Helmut Pozimski <helmut@pozimski.eu>"
 license="LGPL-2.1-or-later"
@@ -18,15 +18,19 @@ checksum="d9f3c333656e88bd4cef5331f34b1c8b69c964a52759eef745d8ddae51a15353
 
 # NOTE: wine depends on specific versions of wine-mono and wine-gecko,
 # check for updates to these packages when updating wine
-
 build_options="mingw staging xshm"
-build_options_default="mingw xshm"
+build_options_default="xshm"
+case "$XBPS_TARGET_MACHINE" in
+	aarch64*) ;;
+	*) build_options_default+=" mingw" ;;
+esac
+
 desc_option_mingw="Use the MinGW cross compiler to build WinPE DLLs"
 desc_option_staging="Apply the wine-staging patchset"
 desc_option_xshm="Enable support for the X Shared Memory Extension"
 
 lib32mode=full
-archs="i686* x86_64*"
+archs="i686* x86_64* aarch64*"
 
 patch_args="-Np1 --directory=${build_wrksrc}"
 
@@ -49,7 +53,7 @@ makedepends="gettext-devel ncurses-devel glu-devel libSM-devel
  freetype-devel pulseaudio-devel giflib-devel
  v4l-utils-devel fontconfig-devel gnutls-devel dbus-devel sane-devel
  libpcap-devel cups-devel ocl-icd-devel vulkan-loader gst-plugins-base1-devel
- SDL2-devel"
+ SDL2-devel wayland-devel libxkbcommon-devel"
 depends="libXi libXinerama libXcomposite libXcursor libOSMesa
  desktop-file-utils hicolor-icon-theme liberation-fonts-ttf
  gnutls SDL2 wine-common>=${version}_${revision}"
@@ -62,7 +66,8 @@ replaces="libwine>=0"
 make_check=extended
 
 if [ "$XBPS_TARGET_WORDSIZE" != 32 ]; then
-	configure_args+=" --enable-win64 --libdir=/usr/lib"
+	_64bit_configure_args=" --enable-win64 --libdir=/usr/lib"
+	configure_args+=$_64bit_configure_args}
 	_wine_suffix="64"
 	_wineserver_suffix=${_wine_suffix}
 else
@@ -70,13 +75,36 @@ else
 	CFLAGS=" -D_LARGE_FILE_SOURCE=1 -D_FILE_OFFSET_BITS=64"
 fi
 
+if [ "$CROSS_BUILD" ] && [ -z "$build_option_mingw" ]; then
+	case "$XBPS_MACHINE" in
+		x86_64*|i686*) hostmakedepends+=" cross-${XBPS_MACHINE%-musl}-w64-mingw32" ;;
+	esac
+	hostmakedepends+=" ${makedepends} lld17 clang17 llvm17"
+	pre_configure() {
+		# native compilation for wine-tools
+		vsrcextract -C ../wine-tools-for-cross wine-${_pkgver}.tar.xz
+		cd ../wine-tools-for-cross
+		env CC=cc LD=ld CXX=g++ \
+			CFLAGS="" CXXFLAGS="" LDFLAGS="" \
+			./configure $_64bit_configure_args # not set if 32bit
+		make ${makejobs}
+		configure_args+=" --with-wine-tools=../wine-tools-for-cross --enable-tools"
+	}
+fi
+
 if [ "$XBPS_LIBC" = "glibc" ]; then
 	hostmakedepends+=" prelink"
 fi
 
+if [ "$XBPS_TARGET_MACHINE" = aarch64 ]; then
+	# build with WoW64 support for aarch64
+	configure_args+=" --enable-archs=i386,x86_64"
+fi
 if [ "$XBPS_TARGET_LIBC" = "musl" ]; then
 	configure_args+=" --enable-archs=i386,x86_64"
-	makedepends+=" cross-i686-w64-mingw32"
+	if [ "$XBPS_TARGET_MACHINE" != aarch64-musl ]; then
+		makedepends+=" cross-i686-w64-mingw32"
+	fi
 fi
 
 _wine_libexec="/usr/libexec/wine"

  parent reply	other threads:[~2024-04-23  8:04 UTC|newest]

Thread overview: 63+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-04-20 20:47 [PR PATCH] " iFoundSilentHouse
2024-04-20 20:53 ` [PR REVIEW] " classabbyamp
2024-04-20 20:53 ` classabbyamp
2024-04-20 20:53 ` classabbyamp
2024-04-20 20:53 ` classabbyamp
2024-04-20 20:56 ` [PR PATCH] [Updated] " iFoundSilentHouse
2024-04-20 20:56 ` fvalasiad
2024-04-20 21:04 ` [PR REVIEW] " Calandracas606
2024-04-20 21:04 ` iFoundSilentHouse
2024-04-20 21:06 ` fvalasiad
2024-04-20 21:13 ` [PR PATCH] [Updated] " iFoundSilentHouse
2024-04-20 21:17 ` iFoundSilentHouse
2024-04-20 21:24 ` iFoundSilentHouse
2024-04-20 21:34 ` [PR REVIEW] " classabbyamp
2024-04-20 21:35 ` classabbyamp
2024-04-20 21:36 ` iFoundSilentHouse
2024-04-20 21:37 ` iFoundSilentHouse
2024-04-20 21:41 ` [PR PATCH] [Updated] " iFoundSilentHouse
2024-04-20 21:42 ` iFoundSilentHouse
2024-04-20 21:44 ` [PR PATCH] [Updated] " iFoundSilentHouse
2024-04-20 21:45 ` iFoundSilentHouse
2024-04-20 21:45 ` fvalasiad
2024-04-20 21:56 ` iFoundSilentHouse
2024-04-20 22:08 ` fvalasiad
2024-04-20 22:16 ` iFoundSilentHouse
2024-04-20 22:34 ` [PR PATCH] [Updated] " iFoundSilentHouse
2024-04-20 22:36 ` [PR REVIEW] " iFoundSilentHouse
2024-04-20 22:38 ` [PR PATCH] [Updated] " iFoundSilentHouse
2024-04-21  0:01 ` fvalasiad
2024-04-21  5:56 ` Hoshpak
2024-04-21  6:29 ` iFoundSilentHouse
2024-04-21  6:37 ` iFoundSilentHouse
2024-04-21  7:34 ` iFoundSilentHouse
2024-04-21 14:14 ` fvalasiad
2024-04-22  8:23 ` [PR PATCH] [Updated] " iFoundSilentHouse
2024-04-22  8:23 ` [PR PATCH] [Closed]: " iFoundSilentHouse
2024-04-22  8:25 ` [PR PATCH] [Updated] " iFoundSilentHouse
2024-04-22 10:34 ` iFoundSilentHouse
2024-04-22 10:37 ` [PR PATCH] [Updated] " iFoundSilentHouse
2024-04-22 10:39 ` iFoundSilentHouse
2024-04-22 10:44 ` [PR PATCH] [Updated] " iFoundSilentHouse
2024-04-22 10:49 ` iFoundSilentHouse
2024-04-22 11:53 ` iFoundSilentHouse
2024-04-22 11:54 ` iFoundSilentHouse
2024-04-22 12:09 ` iFoundSilentHouse
2024-04-22 12:09 ` iFoundSilentHouse
2024-04-22 12:10 ` iFoundSilentHouse
2024-04-22 12:12 ` iFoundSilentHouse
2024-04-22 12:13 ` iFoundSilentHouse
2024-04-22 12:17 ` iFoundSilentHouse
2024-04-22 13:24 ` zlice
2024-04-22 13:27 ` zlice
2024-04-22 16:35 ` Hoshpak
2024-04-22 16:49 ` iFoundSilentHouse
2024-04-22 16:50 ` iFoundSilentHouse
2024-04-22 17:01 ` iFoundSilentHouse
2024-04-22 19:52 ` fvalasiad
2024-04-23  8:04 ` iFoundSilentHouse [this message]
2024-04-23  8:07 ` iFoundSilentHouse
2024-04-23  8:13 ` iFoundSilentHouse
2024-04-23  9:18 ` iFoundSilentHouse
2024-04-25 17:39 ` iFoundSilentHouse
2024-05-14  3:30 ` zlice

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20240423080422.6435721627@inbox.vuxu.org \
    --to=ifoundsilenthouse@users.noreply.github.com \
    --cc=ml@inbox.vuxu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).