blob: 2924318b6c862a452b577061c76d09d64bf9106c (
plain)
1 # Description: An open source SVG editor.
2 # URL: https://www.inkscape.org/
3 # Maintainer: Danny Rawlins, crux at romster dot me
4 # Depends on: boehm-gc boost double-conversion gsl gtkmm3 libsoup libxslt poppler-glib popt potrace gdl
5
6 name=inkscape
7 version=1.0.1
8 release=1
9 source=(https://media.inkscape.org/dl/resources/file/$name-$version.tar.xz
10 https://poppler.freedesktop.org/poppler-20.09.0.tar.xz
11 inkscape.patch)
12
13 poppler() {
14 cmake -S poppler-20.09.0 -B build-poppler -G Ninja \
15 -D CMAKE_INSTALL_PREFIX=/usr \
16 -D CMAKE_INSTALL_LIBDIR=lib \
17 -D CMAKE_BUILD_TYPE=Release \
18 -D CMAKE_CXX_FLAGS_RELEASE="$CXXFLAGS" \
19 -D CMAKE_C_FLAGS_RELEASE="$CFLAGS" \
20 -D ENABLE_UNSTABLE_API_ABI_HEADERS=ON \
21 -D ENABLE_UTILS=ON \
22 -D ENABLE_SPLASH=ON \
23 -D ENABLE_CPP=ON \
24 -D ENABLE_GLIB=ON \
25 -D ENABLE_QT5=OFF \
26 -D ENABLE_ZLIB=ON \
27 -D ENABLE_CMS=lcms2 \
28 -D ENABLE_LIBOPENJPEG=none \
29 -D WITH_NSS3=OFF \
30 -Wno-dev
31
32 cmake --build build-poppler
33 DESTDIR=$SRC/poppler cmake --install build-poppler
34 install -D -t $PKG/usr/lib $SRC/poppler/usr/lib/libpoppler.so.102
35
36 export CXXFLAGS+=" -I$SRC/poppler/usr/include -I$SRC/poppler/usr/include/poppler"
37 export PKG_CONFIG_PATH="$SRC/poppler/usr/lib/pkgconfig:$PKG_CONFIG_PATH"
38 }
39
40 build() {
41 [ ! -e '/usr/lib/libpoppler.so.102' ] && poppler
42
43 patch -d $name-${version}_2020-09-07_3bc2e813f5 -p1 -i $SRC/inkscape.patch
44
45 export PKG_CONFIG_PATH="/usr/lib/imagemagick6/pkgconfig:$PKG_CONFIG_PATH"
46
47 cmake -S $name-${version}_2020-09-07_3bc2e813f5 -B build -G Ninja \
48 -D CMAKE_INSTALL_PREFIX=/usr \
49 -D CMAKE_BUILD_TYPE=Release \
50 -D CMAKE_CXX_FLAGS_RELEASE="$CXXFLAGS" \
51 -D CMAKE_C_FLAGS_RELEASE="$CFLAGS" \
52 -Wno-dev
53
54
55 cmake --build build
56 DESTDIR=$PKG cmake --install build
57
58 rm -r $PKG/usr/share/man/?? \
59 $PKG/usr/share/locale \
60 $PKG/usr/share/inkscape/doc
61
62 rm $PKG/usr/share/inkscape/extensions/README.md \
63 $PKG/usr/share/inkscape/extensions/inkex/deprecated-simple/README.rst \
64
65 find $PKG/usr/share/inkscape -name README -exec rm -f {} +
66 /usr/bin/python3 -mcompileall $PKG
67 }
|