contrib/inkscape/Pkgfile
2018-12-26 21:32:04 +11:00

62 lines
1.4 KiB
Plaintext

# Description: An open source SVG editor.
# URL: https://www.inkscape.org/
# Maintainer: Danny Rawlins, crux at romster dot me
# Depends on: boehm-gc boost gsl gtkmm poppler-glib popt
# Optional: rtmpdump openldap libexif openjade gtk-doc gtkspell brotli imagemagick-compat
name=inkscape
version=0.92.3
release=2
source=(https://media.inkscape.org/dl/resources/file/$name-$version.tar.bz2
poppler-fixes-from-master.patch)
build() {
cd $name-$version
patch -p1 -i $SRC/poppler-fixes-from-master.patch
sed -i 's| abs(| std::fabs(|g' src/ui/tools/flood-tool.cpp
# Fix build with poppler 0.71
sed \
-e 's|gTrue|true|g' \
-e 's|gFalse|false|g' \
-e 's|GBool|bool|g' \
-i src/extension/internal/pdfinput/pdf-parser.*
# Fix build with poppler 0.72
sed \
-e 's|getCString|c_str|g' \
-i src/extension/internal/pdfinput/*
CXXFLAGS+=' -std=c++11'
./autogen.sh
export PKG_CONFIG_PATH='/usr/lib/imagemagick6/pkgconfig'
export FREETYPE_CONFIG="/usr/bin/pkg-config freetype2"
./configure \
--prefix=/usr \
--disable-nls \
--with-python \
--with-perl \
--enable-lcms \
--enable-poppler-cairo \
--disable-strict-build \
--disable-dependency-tracking
make
make DESTDIR=$PKG install
rm \
$PKG/usr/share/man/man1/inkscape.??.1 \
$PKG/usr/share/man/man1/inkscape.zh_TW.1
rm -r \
$PKG/usr/share/man/?? \
$PKG/usr/share/man/zh_TW
find $PKG/usr/share/inkscape -name README -exec rm -f {} +
/usr/bin/python -mcompileall $PKG
}