summaryrefslogtreecommitdiff
path: root/user/wine/APKBUILD
blob: 2e356df60f037797c649c8616eeb1015a6870373 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
# Contributor: Valery Kartel <valery.kartel@gmail.com>
# Contributor: Sören Tempel <soeren+alpine@soeren-tempel.net>
# Contributor: Łukasz Jendrysik <scadu@yandex.com>
# Contributor: Martell Malone <martell@marinelayer.io>
# Maintainer: A. Wilcox <awilfox@adelielinux.org>
pkgname=wine
pkgver=7.0
pkgrel=0
pkgdesc="Compatibility layer for running Windows programs"
url="https://www.winehq.org/"
arch="pmmx x86 x86_64"
license="LGPL-2.0+"
options="!check"
depends=""
depends_dev="$pkgname perl"
makedepends="fontconfig-dev freetype-dev ncurses-dev openldap-dev openssl-dev
	libxcomposite-dev libxcursor-dev libxext-dev libxfixes-dev libxi-dev
	libxinerama-dev libxrandr-dev libxrender-dev libxxf86dga-dev mesa-dev
	alsa-lib-dev cups-dev dbus-dev eudev-dev gnutls-dev openal-soft-dev
	pulseaudio-dev sane-dev udisks2-dev unixodbc-dev v4l-utils-dev
	gstreamer-dev krb5-dev libgphoto2-dev libusb-dev bison flex
	autoconf automake libtool gst-plugins-base-dev"
subpackages="$pkgname-dev $pkgname-doc"
source="http://dl.winehq.org/$pkgname/source/${pkgver%.[1-9]}/$pkgname-$pkgver.tar.xz
	headers.patch
	printer.patch
	rpath.patch
	"

prepare() {
	default_prepare
	aclocal && autoheader && autoreconf
}

build() {
	case "$CARCH" in
		x86_64) _win64=--enable-win64; _ldrsuffix=64;;
	esac
	./configure \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr \
		--libdir=/usr/lib \
		--sysconfdir=/etc \
		--localstatedir=/var \
		--with-cups \
		--with-dbus \
		--with-fontconfig \
		--with-freetype \
		--with-openal \
		--with-opengl \
		--with-pulse \
		--with-sane \
		--with-udev \
		--with-x \
		--with-xcomposite \
		--with-xinerama \
		$_win64
	make LDFLAGS="$LDFLAGS -no-pie" \
		tools/{widl/widl,winebuild/winebuild,winegcc/winegcc,wrc/wrc} \
		loader/wine$_ldrsuffix loader/wine${_ldrsuffix}-preloader server/wineserver
	make
}

check() {
	make test
}

package() {
	make -j1 DESTDIR="$pkgdir" install

	install -Dm755 tools/wineapploader \
		"$pkgdir"/usr/bin/wineapploader

	for file in msiexec notepad regedit regsvr32 wineboot \
		winecfg wineconsole winefile winemine winepath; do
		rm "$pkgdir"/usr/bin/$file
		ln -sf /usr/bin/wineapploader "$pkgdir"/usr/bin/$file
	done
}

dev() {
	default_dev

	install -d "$subpkgdir"/usr/bin
	for file in widl wmc wrc winebuild winedump function_grep.pl \
		 winedbg winemaker winegcc winecpp wineg++; do
		mv "$pkgdir"/usr/bin/$file "$subpkgdir"/usr/bin/
	done
}

sha512sums="eec17b046ed5447eb540f421c9b2748d9419ce087496c2743a9914fd27bbe5ff9da0cfe47d3cd76fa97323bd1188a1d82b1eef4968d86ed1957dc1a95e28529c  wine-7.0.tar.xz
04b4035ad7db762bf965bce095457be9e96292a799c4443c9b93fd572e49371a4bfe297bc3cf720c1e1f7338585767309ec9d84e83db64109883c1782cef40ba  headers.patch
26c72d45329eaf6f0f361edf08a2984ecc99d892bff3d0932928514db5882bebd5744627aa3a63f0715fc308e12364879356d5e94b334d7c6dc9ea3ff854e423  printer.patch
ade85bee3df634bfb69ae6a27f262708c68c0f9b7be894b44c17fdf14ce5fe8093b1ce2eb7ecca2ca245d9f9b7a1e62ff061449e44acb277c1f03a44449d5191  rpath.patch"