Skip to content

Commit

Permalink
fontforge
Browse files Browse the repository at this point in the history
Signed-off-by: Batuhan Apaydin <[email protected]>
  • Loading branch information
developer-guy committed Feb 20, 2024
1 parent e173604 commit 0c09a2f
Show file tree
Hide file tree
Showing 5 changed files with 314 additions and 278 deletions.
192 changes: 99 additions & 93 deletions fontforge.yaml
Original file line number Diff line number Diff line change
@@ -1,106 +1,112 @@
# Generated from https://git.alpinelinux.org/aports/plain/community/fontforge/APKBUILD
package:
name: fontforge
version: "20230101"
epoch: 0
description: Free (libre) font editor
copyright:
- license: GPL-3.0-or-later
name: fontforge
version: "20230101"
epoch: 0
description: Free (libre) font editor
copyright:
- license: GPL-3.0-or-later

environment:
contents:
packages:
- autoconf
- automake
- build-base
- busybox
- ca-certificates-bundle
- cmake
- giflib-dev
- gnu-libiconv-dev
- gtk+3.0-dev
- libspiro-dev
- libxml2-dev
- pango-dev
- potrace
- py3-setuptools
- python3-dev
- readline-dev
- samurai
- tiff-dev
- woff2-dev
contents:
packages:
- autoconf
- automake
- build-base
- busybox
- ca-certificates-bundle
- cmake
- giflib-dev
- gnu-libiconv-dev
- gtk+3.0-dev
- libspiro-dev
- libxml2-dev
- pango-dev
- potrace
- py3-setuptools
- python3-dev
- readline-dev
- samurai
- tiff-dev
- woff2-dev

pipeline:
- uses: git-checkout
with:
repository: https://github.com/fontforge/fontforge
expected-commit: a1dad3e81da03d5d5f3c4c1c1b9b5ca5ebcfcecf
tag: v${{package.version}}
- runs: |
export CFLAGS="$CFLAGS -flto=auto -I/usr/include/gnu-libiconv"
export CXXFLAGS="$CXXFLAGS -flto=auto -I/usr/include/gnu-libiconv"
_build build-nogui -DENABLE_GUI=OFF -DBUILD_TESTING=OFF
_build build -DENABLE_GUI=ON -DBUILD_TESTING="$(want_check && echo ON || echo OFF)"
- uses: git-checkout
with:
repository: https://github.com/fontforge/fontforge
expected-commit: a1dad3e81da03d5d5f3c4c1c1b9b5ca5ebcfcecf
tag: v${{package.version}}

- runs: |
export CFLAGS="$CFLAGS -flto=auto -I/usr/include/gnu-libiconv"
export CXXFLAGS="$CXXFLAGS -flto=auto -I/usr/include/gnu-libiconv"
_build build-nogui -DENABLE_GUI=OFF -DBUILD_TESTING=OFF
_build build -DENABLE_GUI=ON -DBUILD_TESTING="$(want_check && echo ON || echo OFF)"
builddir="$(pwd)"
builddir="$(pwd)"
if [ "$CBUILD" != "$CHOST" ]; then
local crossopts="-DCMAKE_SYSTEM_NAME=Linux -DCMAKE_HOST_SYSTEM_NAME=Linux"
fi
cmake -B "$builddir" -G Ninja \
-DCMAKE_BUILD_TYPE=MinSizeRel \
-DCMAKE_INSTALL_PREFIX=/usr \
-DCMAKE_INSTALL_LIBDIR=lib \
-DCMAKE_SKIP_INSTALL_RPATH=ON \
-DENABLE_X11=OFF \
-DENABLE_PYTHON_SCRIPTING=ON \
-DENABLE_PYTHON_EXTENSION=ON \
-DENABLE_LIBSPIRO=ON \
-DENABLE_LIBGIF=ON \
-DENABLE_LIBJPEG=ON \
-DENABLE_LIBPNG=ON \
-DENABLE_LIBREADLINE=ON \
-DENABLE_LIBTIFF=ON \
-DENABLE_WOFF2=ON \
-DENABLE_DOCS=OFF \
$crossopts \
"$@"
cmake --build "$builddir"
if [ "$CBUILD" != "$CHOST" ]; then
local crossopts="-DCMAKE_SYSTEM_NAME=Linux -DCMAKE_HOST_SYSTEM_NAME=Linux"
fi
cmake -B "$builddir" -G Ninja \
-DCMAKE_BUILD_TYPE=MinSizeRel \
-DCMAKE_INSTALL_PREFIX=/usr \
-DCMAKE_INSTALL_LIBDIR=lib \
-DCMAKE_SKIP_INSTALL_RPATH=ON \
-DENABLE_X11=OFF \
-DENABLE_PYTHON_SCRIPTING=ON \
-DENABLE_PYTHON_EXTENSION=ON \
-DENABLE_LIBSPIRO=ON \
-DENABLE_LIBGIF=ON \
-DENABLE_LIBJPEG=ON \
-DENABLE_LIBPNG=ON \
-DENABLE_LIBREADLINE=ON \
-DENABLE_LIBTIFF=ON \
-DENABLE_WOFF2=ON \
-DENABLE_DOCS=OFF \
$crossopts \
"$@"
cmake --build "$builddir"
mkdir -p "${{targets.destdir}}"/usr/bin
mkdir -p "${{targets.destdir}}"/usr/bin
DESTDIR="${{targets.destdir}}" cmake --install build
DESTDIR=".dest-nogui" cmake --install build-nogui
mv "${{targets.destdir}}"/usr/bin/fontforge "${{targets.destdir}}"/usr/bin/fontforge-gui
mv .dest-nogui/usr/bin/fontforge "${{targets.destdir}}"/usr/bin/
DESTDIR="${{targets.destdir}}" cmake --install build
DESTDIR=".dest-nogui" cmake --install build-nogui
mv "${{targets.destdir}}"/usr/bin/fontforge "${{targets.destdir}}"/usr/bin/fontforge-gui
mv .dest-nogui/usr/bin/fontforge "${{targets.destdir}}"/usr/bin/
- uses: strip

- uses: strip
subpackages:
- name: fontforge-dev
pipeline:
- uses: split/dev
dependencies:
runtime:
- fontforge
description: fontforge dev
- name: fontforge-gui
pipeline:
- runs: |
mv "${{targets.destdir}}"/usr/bin/fontforge-gui "${{targets.subpkgdir}}"/usr/bin/fontforge-gui
mv "${{targets.destdir}}"/usr/bin/applications "${{targets.subpkgdir}}"/usr/bin/applications
mv "${{targets.destdir}}"/usr/bin/icons "${{targets.subpkgdir}}"/usr/bin/icons
mv "${{targets.destdir}}"/usr/bin/metainfo "${{targets.subpkgdir}}"/usr/bin/metainfo
description: fontforge GUI
- name: fontforge-doc
pipeline:
- uses: split/manpages
description: fontforge manpages
- name: py3-fontforge
pipeline:
- runs: |
mv "${{targets.destdir}}"/usr/lib/python3.* "${{targets.subpkgdir}}"/usr/lib/python3.*
mv "${{targets.destdir}}"/usr/share/fontforge/python "${{targets.subpkgdir}}"/usr/share/fontforge/python
description: Python 3 bindings for fontforge
- name: fontforge-dev
pipeline:
- uses: split/dev
dependencies:
runtime:
- fontforge
description: fontforge dev

- name: fontforge-gui
pipeline:
- runs: |
mv "${{targets.destdir}}"/usr/bin/fontforge-gui "${{targets.subpkgdir}}"/usr/bin/fontforge-gui
mv "${{targets.destdir}}"/usr/bin/applications "${{targets.subpkgdir}}"/usr/bin/applications
mv "${{targets.destdir}}"/usr/bin/icons "${{targets.subpkgdir}}"/usr/bin/icons
mv "${{targets.destdir}}"/usr/bin/metainfo "${{targets.subpkgdir}}"/usr/bin/metainfo
description: fontforge GUI

- name: fontforge-doc
pipeline:
- uses: split/manpages
description: fontforge manpages

- name: py3-fontforge
pipeline:
- runs: |
mv "${{targets.destdir}}"/usr/lib/python3.* "${{targets.subpkgdir}}"/usr/lib/python3.*
mv "${{targets.destdir}}"/usr/share/fontforge/python "${{targets.subpkgdir}}"/usr/share/fontforge/python
description: Python 3 bindings for fontforge

update:
enabled: true
Expand Down
121 changes: 64 additions & 57 deletions gnu-libiconv.yaml
Original file line number Diff line number Diff line change
@@ -1,64 +1,71 @@
# Generated from https://git.alpinelinux.org/aports/plain/community/gnu-libiconv/APKBUILD
package:
name: gnu-libiconv
version: "1.17"
epoch: 0
description: GNU charset conversion library for libc which doesn't implement it
copyright:
- license: LGPL-2.1-or-later
name: gnu-libiconv
version: "1.17"
epoch: 0
description: GNU charset conversion library for libc which doesn't implement it
copyright:
- license: LGPL-2.1-or-later

environment:
contents:
packages:
- autoconf
- automake
- build-base
- busybox
- ca-certificates-bundle
- gnu-libiconv-dev
contents:
packages:
- autoconf
- automake
- build-base
- busybox
- ca-certificates-bundle
- gnu-libiconv-dev

pipeline:
- uses: fetch
with:
expected-sha256: 8f74213b56238c85a50a5329f77e06198771e70dd9a739779f4c02f65d971313
uri: https://ftp.gnu.org/pub/gnu/libiconv/libiconv-${{package.version}}.tar.gz
- runs: |
./configure \
--build=$CBUILD \
--host=$CHOST \
--prefix=/usr \
--mandir=/usr/share/man \
--docdir=/usr/share/doc/$pkgname/ \
--disable-nls \
--disable-static \
--enable-extra-encodings
# since users of this package use this package to work around missing features in musls iconv,
# enable extra encodings (like the CP437) to be closer to glibcs iconv.
# work around rpath issue
sed -i 's|^hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=""|g' libtool
sed -i 's|^runpath_var=LD_RUN_PATH|runpath_var=DIE_RPATH_DIE|g' libtool
- uses: autoconf/make
- runs: |
mkdir -p "${{targets.destdir}}"/usr/bin
mkdir "${{targets.destdir}}"/usr/include/gnu-libiconv
make DESTDIR="${{targets.destdir}}/" install
# move headers so they dont clash with libc headers
mv "${{targets.destdir}}"/usr/include/*.h "${{targets.destdir}}"/usr/include/gnu-libiconv
mv "${{targets.destdir}}"/usr/bin/iconv "${{targets.destdir}}"/usr/bin/gnu-iconv
- uses: strip
- uses: fetch
with:
expected-sha256: 8f74213b56238c85a50a5329f77e06198771e70dd9a739779f4c02f65d971313
uri: https://ftp.gnu.org/pub/gnu/libiconv/libiconv-${{package.version}}.tar.gz

- runs: |
./configure \
--build=$CBUILD \
--host=$CHOST \
--prefix=/usr \
--mandir=/usr/share/man \
--docdir=/usr/share/doc/$pkgname/ \
--disable-nls \
--disable-static \
--enable-extra-encodings
# since users of this package use this package to work around missing features in musls iconv,
# enable extra encodings (like the CP437) to be closer to glibcs iconv.
# work around rpath issue
sed -i 's|^hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=""|g' libtool
sed -i 's|^runpath_var=LD_RUN_PATH|runpath_var=DIE_RPATH_DIE|g' libtool
- uses: autoconf/make

- runs: |
mkdir -p "${{targets.destdir}}"/usr/bin
mkdir "${{targets.destdir}}"/usr/include/gnu-libiconv
make DESTDIR="${{targets.destdir}}/" install
# move headers so they dont clash with libc headers
mv "${{targets.destdir}}"/usr/include/*.h "${{targets.destdir}}"/usr/include/gnu-libiconv
mv "${{targets.destdir}}"/usr/bin/iconv "${{targets.destdir}}"/usr/bin/gnu-iconv
- uses: strip

subpackages:
- name: gnu-libiconv-doc
pipeline:
- uses: split/manpages
description: gnu-libiconv manpages
- name: gnu-libiconv-dev
pipeline:
- uses: split/dev
dependencies:
runtime:
- gnu-libiconv
- gnu-libiconv
description: gnu-libiconv dev
- name: gnu-libiconv-doc
pipeline:
- uses: split/manpages
description: gnu-libiconv manpages

- name: gnu-libiconv-dev
pipeline:
- uses: split/dev
dependencies:
runtime:
- gnu-libiconv
- gnu-libiconv
description: gnu-libiconv dev

update:
enabled: true
Expand Down
Loading

0 comments on commit 0c09a2f

Please sign in to comment.