78 lines
3.3 KiB
Bash
78 lines
3.3 KiB
Bash
# Maintainer: Alexey Pavlov <alexpux@gmail.com>
|
|
|
|
_realname=headers
|
|
pkgbase=mingw-w64-${_realname}-git
|
|
pkgname="${MINGW_PACKAGE_PREFIX}-${_realname}-git"
|
|
replaces=("${MINGW_PACKAGE_PREFIX}-${_realname}-svn")
|
|
pkgdesc="MinGW-w64 headers for Windows"
|
|
pkgver=7.0.0.5285.7b2baaf8
|
|
pkgrel=1
|
|
arch=('any')
|
|
url="https://mingw-w64.sourceforge.io/"
|
|
license=('custom')
|
|
groups=("${MINGW_PACKAGE_PREFIX}-toolchain")
|
|
makedepends=('git' "${MINGW_PACKAGE_PREFIX}-tools")
|
|
provides=("${MINGW_PACKAGE_PREFIX}-${_realname}")
|
|
conflicts=("${MINGW_PACKAGE_PREFIX}-${_realname}")
|
|
options=('!strip' '!libtool' '!emptydirs')
|
|
source=("mingw-w64"::"git+https://git.code.sf.net/p/mingw-w64/mingw-w64"
|
|
0001-Allow-to-use-bessel-and-complex-functions-without-un.patch
|
|
0002-DirectX-9-fixes-for-VLC.patch
|
|
0003-DirectX-11-fixes-for-VLC.patch)
|
|
sha256sums=('SKIP'
|
|
'd641257f7e1469aff89adc33e57702b75fe9667ca035978f890eae1020b6814c'
|
|
'74dc78f8ef27599d4ebf020f9496316c6afd6677381f13561f30780d144a07e1'
|
|
'e80b76aa3eef6d0206c4d99ac340a60cfd92ea80392a6ec5122dc3851fbd3286')
|
|
|
|
pkgver() {
|
|
cd "${srcdir}/mingw-w64"
|
|
local _major=$(head -n 16 mingw-w64-headers/crt/_mingw_mac.h | grep '__MINGW64_VERSION_MAJOR' | sed -e 's/.* //' | tr '\n' '.' | sed 's/.$/\n/')
|
|
local _minor=$(head -n 16 mingw-w64-headers/crt/_mingw_mac.h | grep '__MINGW64_VERSION_MINOR' | sed -e 's/.* //' | tr '\n' '.' | sed 's/.$/\n/')
|
|
local _rev=0
|
|
printf "%s.%s.%s.%s.%s" ${_major} ${_minor} ${_rev} "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
|
|
}
|
|
|
|
prepare() {
|
|
cd ${srcdir}/mingw-w64
|
|
|
|
git am --committer-date-is-author-date "${srcdir}/0001-Allow-to-use-bessel-and-complex-functions-without-un.patch"
|
|
git am --committer-date-is-author-date "${srcdir}/0002-DirectX-9-fixes-for-VLC.patch"
|
|
git am --committer-date-is-author-date "${srcdir}/0003-DirectX-11-fixes-for-VLC.patch"
|
|
|
|
|
|
|
|
cd ${srcdir}/mingw-w64/mingw-w64-headers
|
|
touch include/windows.*.h include/wincrypt.h include/prsht.h
|
|
}
|
|
|
|
build() {
|
|
msg "Configuring ${MINGW_CHOST} headers"
|
|
[[ -d ${srcdir}/headers-${MINGW_CHOST} ]] && rm -rf ${srcdir}/headers-${MINGW_CHOST}
|
|
mkdir -p ${srcdir}/headers-${MINGW_CHOST} && cd ${srcdir}/headers-${MINGW_CHOST}
|
|
${srcdir}/mingw-w64/mingw-w64-headers/configure \
|
|
--build=${MINGW_CHOST} \
|
|
--host=${MINGW_CHOST} \
|
|
--target=${MINGW_CHOST} \
|
|
--prefix=${MINGW_PREFIX}/${MINGW_CHOST} \
|
|
--enable-sdk=all \
|
|
--enable-secure-api \
|
|
--with-default-win32-winnt=0x601 \
|
|
--enable-idl \
|
|
--without-widl
|
|
}
|
|
|
|
package() {
|
|
msg "Installing ${MINGW_CHOST} headers"
|
|
cd ${srcdir}/headers-${MINGW_CHOST}
|
|
make DESTDIR=${pkgdir} install
|
|
|
|
rm ${pkgdir}${MINGW_PREFIX}/${MINGW_CHOST}/include/pthread_signal.h
|
|
rm ${pkgdir}${MINGW_PREFIX}/${MINGW_CHOST}/include/pthread_time.h
|
|
rm ${pkgdir}${MINGW_PREFIX}/${MINGW_CHOST}/include/pthread_unistd.h
|
|
|
|
msg "Installing MinGW-w64 licenses"
|
|
install -Dm644 ${srcdir}/mingw-w64/mingw-w64-headers/ddk/readme.txt ${pkgdir}${MINGW_PREFIX}/share/licenses/${_realname}/ddk-readme.txt
|
|
install -Dm644 ${srcdir}/mingw-w64/mingw-w64-headers/direct-x/COPYING.LIB ${pkgdir}${MINGW_PREFIX}/share/licenses/${_realname}/direct-x-COPYING.LIB
|
|
install -Dm644 ${srcdir}/mingw-w64/mingw-w64-headers/direct-x/readme.txt ${pkgdir}${MINGW_PREFIX}/share/licenses/${_realname}/direct-x-readme.txt
|
|
}
|