2011-11-09 09:18:13 +01:00
|
|
|
# Description: An open source SVG editor.
|
2017-02-11 06:29:26 +01:00
|
|
|
# URL: https://www.inkscape.org/
|
2014-11-10 13:28:07 +01:00
|
|
|
# Maintainer: Danny Rawlins, crux at romster dot me
|
2021-01-31 08:07:06 +01:00
|
|
|
# Depends on: boehm-gc boost double-conversion graphicsmagick gsl gtkmm3 libsoup libxslt poppler-glib popt potrace gdl
|
2011-11-09 09:18:13 +01:00
|
|
|
|
|
|
|
name=inkscape
|
2021-06-12 14:48:34 +02:00
|
|
|
version=1.1
|
2021-09-12 11:26:57 +02:00
|
|
|
_pversion=21.09.0
|
|
|
|
_psoversion=113
|
|
|
|
release=7
|
2020-05-28 17:02:37 +02:00
|
|
|
source=(https://media.inkscape.org/dl/resources/file/$name-$version.tar.xz
|
2021-06-12 14:48:34 +02:00
|
|
|
https://poppler.freedesktop.org/poppler-$_pversion.tar.xz)
|
2011-11-09 09:18:13 +01:00
|
|
|
|
2019-12-04 12:52:25 +01:00
|
|
|
poppler() {
|
2021-03-07 01:35:01 +01:00
|
|
|
cmake -S poppler-$_pversion -B build-poppler -G Ninja \
|
2020-11-08 12:19:41 +01:00
|
|
|
-D CMAKE_INSTALL_PREFIX=/usr \
|
|
|
|
-D CMAKE_INSTALL_LIBDIR=lib \
|
|
|
|
-D CMAKE_BUILD_TYPE=Release \
|
2020-12-07 00:54:57 +01:00
|
|
|
-D CMAKE_CXX_FLAGS_RELEASE="$CXXFLAGS" \
|
|
|
|
-D CMAKE_C_FLAGS_RELEASE="$CFLAGS" \
|
2020-11-08 12:19:41 +01:00
|
|
|
-D ENABLE_UNSTABLE_API_ABI_HEADERS=ON \
|
|
|
|
-D ENABLE_UTILS=ON \
|
|
|
|
-D ENABLE_SPLASH=ON \
|
|
|
|
-D ENABLE_CPP=ON \
|
|
|
|
-D ENABLE_GLIB=ON \
|
|
|
|
-D ENABLE_QT5=OFF \
|
|
|
|
-D ENABLE_ZLIB=ON \
|
|
|
|
-D ENABLE_CMS=lcms2 \
|
2021-09-12 11:26:57 +02:00
|
|
|
-D WITH_INTERNAL_2GEOM=ON \
|
2020-11-08 12:19:41 +01:00
|
|
|
-D ENABLE_LIBOPENJPEG=none \
|
|
|
|
-D WITH_NSS3=OFF \
|
2020-11-08 10:05:08 +01:00
|
|
|
-Wno-dev
|
2019-12-04 12:52:25 +01:00
|
|
|
|
2020-05-28 17:45:50 +02:00
|
|
|
cmake --build build-poppler
|
2020-11-08 10:05:08 +01:00
|
|
|
DESTDIR=$SRC/poppler cmake --install build-poppler
|
2021-03-07 01:35:01 +01:00
|
|
|
install -D -t $PKG/usr/lib $SRC/poppler/usr/lib/libpoppler.so.$_psoversion
|
2019-12-04 12:52:25 +01:00
|
|
|
|
2020-05-28 17:45:50 +02:00
|
|
|
export CXXFLAGS+=" -I$SRC/poppler/usr/include -I$SRC/poppler/usr/include/poppler"
|
|
|
|
export PKG_CONFIG_PATH="$SRC/poppler/usr/lib/pkgconfig:$PKG_CONFIG_PATH"
|
2019-12-04 12:52:25 +01:00
|
|
|
}
|
|
|
|
|
2011-11-09 09:18:13 +01:00
|
|
|
build() {
|
2021-03-07 01:35:01 +01:00
|
|
|
[ ! -e "/usr/lib/libpoppler.so.$_psoversion" ] && poppler
|
2020-08-21 13:58:52 +02:00
|
|
|
|
2021-04-03 02:51:15 +02:00
|
|
|
# https://gitlab.gnome.org/GNOME/glib/-/issues/2331
|
|
|
|
CFLAGS+=' -DGLIB_VERSION_MIN_REQUIRED=GLIB_VERSION_2_46 -DGLIB_VERSION_MAX_ALLOWED=GLIB_VERSION_2_66'
|
|
|
|
CXXFLAGS+=' -DGLIB_VERSION_MIN_REQUIRED=GLIB_VERSION_2_46 -DGLIB_VERSION_MAX_ALLOWED=GLIB_VERSION_2_66'
|
2017-02-11 06:29:26 +01:00
|
|
|
|
2021-01-31 08:07:06 +01:00
|
|
|
cmake -S $name-${version}_* -B build -G Ninja \
|
2020-11-08 12:19:41 +01:00
|
|
|
-D CMAKE_INSTALL_PREFIX=/usr \
|
2021-06-19 15:14:58 +02:00
|
|
|
-D CMAKE_INSTALL_LIBDIR=lib \
|
2020-11-08 12:19:41 +01:00
|
|
|
-D CMAKE_BUILD_TYPE=Release \
|
2020-12-07 00:54:57 +01:00
|
|
|
-D CMAKE_CXX_FLAGS_RELEASE="$CXXFLAGS" \
|
|
|
|
-D CMAKE_C_FLAGS_RELEASE="$CFLAGS" \
|
2020-11-08 10:05:08 +01:00
|
|
|
-Wno-dev
|
|
|
|
|
2020-05-28 17:02:37 +02:00
|
|
|
cmake --build build
|
2020-07-08 15:01:36 +02:00
|
|
|
DESTDIR=$PKG cmake --install build
|
2011-11-09 09:18:13 +01:00
|
|
|
|
2020-05-28 17:02:37 +02:00
|
|
|
rm -r $PKG/usr/share/man/?? \
|
2021-06-12 14:48:34 +02:00
|
|
|
$PKG/usr/share/man/zh_TW \
|
2020-05-28 17:02:37 +02:00
|
|
|
$PKG/usr/share/locale \
|
|
|
|
$PKG/usr/share/inkscape/doc
|
2012-03-02 13:29:46 +01:00
|
|
|
|
2020-05-28 17:02:37 +02:00
|
|
|
rm $PKG/usr/share/inkscape/extensions/README.md \
|
|
|
|
$PKG/usr/share/inkscape/extensions/inkex/deprecated-simple/README.rst \
|
2011-11-09 09:18:13 +01:00
|
|
|
|
|
|
|
find $PKG/usr/share/inkscape -name README -exec rm -f {} +
|
2021-01-31 08:07:06 +01:00
|
|
|
|
2020-05-28 17:02:37 +02:00
|
|
|
/usr/bin/python3 -mcompileall $PKG
|
2021-01-31 08:07:06 +01:00
|
|
|
/usr/bin/python3 -O -m compileall $PKG
|
|
|
|
/usr/bin/python3 -OO -m compileall $PKG
|
2011-11-09 09:18:13 +01:00
|
|
|
}
|