forked from msys2/MINGW-packages
-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathPKGBUILD
More file actions
56 lines (52 loc) · 2.07 KB
/
Copy pathPKGBUILD
File metadata and controls
56 lines (52 loc) · 2.07 KB
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
# Maintainer: Alexey Pavlov <alexpux@gmail.com>
# Contributor: Martell Malone <martellmalone@gmail.com>
_realname=tools
pkgbase="mingw-w64-${_realname}"
pkgname="${MINGW_PACKAGE_PREFIX}-${_realname}"
pkgver=13.0.0.r551.g5595a0ef4
pkgrel=1
_commit='5595a0ef4079da3cbf5ab800a3d2d66e8534b74d'
pkgdesc="MinGW-w64 tools (mingw-w64)"
arch=('any')
mingw_arch=('mingw32' 'mingw64' 'ucrt64' 'clang64' 'clangarm64')
url="https://www.mingw-w64.org/"
msys2_repository_url="https://sourceforge.net/p/mingw-w64/mingw-w64/ci/master/tree/mingw-w64-tools/"
license=('spdx:GPL-3.0-or-later AND LGPL-2.1-or-later')
provides=("${MINGW_PACKAGE_PREFIX}-${_realname}-git=${pkgver}")
conflicts=("${MINGW_PACKAGE_PREFIX}-${_realname}-git")
replaces=("${MINGW_PACKAGE_PREFIX}-${_realname}-git")
groups=("${MINGW_PACKAGE_PREFIX}-toolchain")
makedepends=("${MINGW_PACKAGE_PREFIX}-cc"
"${MINGW_PACKAGE_PREFIX}-autotools"
"${MINGW_PACKAGE_PREFIX}-libmangle"
"git")
depends=("${MINGW_PACKAGE_PREFIX}-cc-libs")
options=('!emptydirs')
source=("mingw-w64"::"git+https://git.code.sf.net/p/mingw-w64/mingw-w64#commit=$_commit")
sha256sums=('9a7c8627b168ddea5cc3e946131247c788487edd201c118ee409e03391134698')
_tools="gendef genidl genpeimg widl" # genstubdll
pkgver() {
cd "${srcdir}/mingw-w64"
git describe --long ${_commit} | sed 's/\([^-]*-g\)/r\1/;s/-/./g;s/^v//g'
}
build() {
for cur in ${_tools}; do
plain "Building ${cur} ..."
mkdir -p "${srcdir}"/${MSYSTEM}-${cur} && cd "${srcdir}"/${MSYSTEM}-${cur}
"${srcdir}"/mingw-w64/mingw-w64-tools/${cur}/configure \
--prefix=${MINGW_PREFIX} \
--with-mangle=${MINGW_PREFIX} \
--with-widl-includedir=${MINGW_PREFIX}/include
make
done
}
package() {
for cur in ${_tools}; do
plain "Installing ${cur} ..."
cd "${srcdir}"/${MSYSTEM}-${cur}
make DESTDIR="${pkgdir}" install
if [[ -f "${srcdir}/mingw-w64/mingw-w64-tools/${cur}"/COPYING ]]; then
install -Dm644 "${srcdir}"/mingw-w64/mingw-w64-tools/${cur}/COPYING "${pkgdir}"${MINGW_PREFIX}/share/licenses/mingw-w64-tools/COPYING.${cur}
fi
done
}