blob: 1188712be5f8e1e7d244e298b56334d7796923ba [file] [log] [blame] [edit]
# Maintainer: umarcor <unai.martinezcorral@ehu.eus>
_realname=verilator
pkgbase=mingw-w64-${_realname}
pkgname="${MINGW_PACKAGE_PREFIX}-${_realname}"
pkgver=4.204
pkgrel=1
pkgdesc="The fastest free Verilog HDL simulator (mingw-w64)"
arch=('any')
mingw_arch=('mingw32' 'mingw64' 'ucrt64' 'clang64' 'clang32')
url="https://www.veripool.org/projects/verilator/wiki/Intro"
license=("LGPL")
groups=("${MINGW_PACKAGE_PREFIX}-eda")
makedepends=("${MINGW_PACKAGE_PREFIX}-gcc" "flex")
depends=("${MINGW_PACKAGE_PREFIX}-gcc-libs")
source=(
"${_realname}::https://codeload.github.com/${_realname}/${_realname}/tar.gz/v${pkgver}"
'0001-Fix-V3Hash-when-building-m32.patch'
)
sha256sums=(
'dbad9bd3cac34e63bbd945fff9a59eaabe31dae1e1c93c847d0f894db9919498'
'9c2a039f72d14896e9def846f4f274ce98cde52ee34cd3adad2c715b8e93c000'
)
prepare() {
[[ -d "${srcdir}/build-${MINGW_CHOST}" ]] && rm -rf "${srcdir}/build-${MINGW_CHOST}"
cp -rf "${srcdir}/${_realname}-${pkgver}" "${srcdir}/build-${MINGW_CHOST}"
cd "${srcdir}/build-${MINGW_CHOST}"
patch -p1 < ${srcdir}/0001-Fix-V3Hash-when-building-m32.patch
sh autoconf
}
build() {
cd "${srcdir}/build-${MINGW_CHOST}"
cp /usr/include/FlexLexer.h src/
export MSYS2_ARG_CONV_EXCL="-DDEFENV"
./configure \
--prefix=${MINGW_PREFIX} \
--build=${MINGW_CHOST} \
--host=${MINGW_CHOST}
make
}
package() {
cd "${srcdir}/build-${MINGW_CHOST}"
make DESTDIR="${pkgdir}" install
}