mirror of
https://github.com/ivabus/pantry
synced 2024-11-10 10:35:17 +03:00
fbad316611
* glib linux build fixes * gobj-intr * include symlink step when testing, in case a subsequent test requires it * fix harfbuzz build Co-authored-by: Max Howell <mxcl@me.com>
74 lines
2 KiB
YAML
74 lines
2 KiB
YAML
distributable:
|
|
url: https://download.gnome.org/sources/glib/{{ version.major }}.{{ version.minor }}/glib-{{ version }}.tar.xz
|
|
strip-components: 1
|
|
|
|
versions:
|
|
github: GNOME/glib/tags
|
|
ignore: [2.73.x, 2.74.x]
|
|
|
|
#FIXME 2.73.2 onwards depends on PCRE2 (10.x)
|
|
# lol at bumping a dep in a *PATCH* release, semver is for the weak apparently
|
|
|
|
dependencies:
|
|
gnu.org/gettext: ^0.21
|
|
sourceware.org/libffi: 3
|
|
pcre.org: 8
|
|
|
|
build:
|
|
dependencies:
|
|
tea.xyz/gx/cc: c99
|
|
mesonbuild.com: ^0.63
|
|
ninja-build.org: 1
|
|
freedesktop.org/pkg-config: ^0.29
|
|
python.org: 3 #TODO ^3.5
|
|
script: |
|
|
meson out $ARGS
|
|
|
|
cd out
|
|
ninja -v
|
|
ninja install
|
|
|
|
GT='${prefix}/../../../gnu.org/gettext/v{{ deps.gnu.org/gettext.version.major }}'
|
|
|
|
cd {{prefix}}/lib/pkgconfig
|
|
|
|
sed -i.bak -e \
|
|
's|Libs: -L${libdir} -lglib-2.0 -lintl|Libs: -L${libdir} -lglib-2.0'\ -L$GT/lib\ -lintl\| \
|
|
./glib-2.0.pc
|
|
sed -i.bak -e \
|
|
's|Cflags: -I${includedir}/glib-2.0 -I${libdir}/glib-2.0/include|Cflags: -I${includedir}/glib-2.0 -I${libdir}/glib-2.0/include'\ -I$GT/include\| \
|
|
./glib-2.0.pc
|
|
|
|
rm *.bak
|
|
|
|
#REF https://github.com/Homebrew/homebrew-core/blob/d0e65698ccd502335bea68ce879ae02e1735db0d/Formula/glib.rb#L66-L67
|
|
#FIXME hardcoded paths ^^
|
|
env:
|
|
ARGS:
|
|
- --prefix={{prefix}}
|
|
- --libdir={{prefix}}/lib
|
|
- --wrap-mode=nofallback
|
|
- --buildtype=release
|
|
# tests fail to build with `error: target emulation unknown: -m or at least one .o file required`
|
|
- -Dtests=false
|
|
|
|
test:
|
|
dependencies:
|
|
tea.xyz/gx/cc: c99
|
|
freedesktop.org/pkg-config: ^0.29
|
|
script: |
|
|
sh - <<EOSTDIN
|
|
# unset these since we only want to test via pkg-config
|
|
unset LIBRARY_PATH
|
|
unset CPATH
|
|
unset LD_LIBRARY_PATH
|
|
unset DYLD_FALLBACK_LIBRARY_PATH
|
|
cc $CFLAGS $LDFLAGS test.c
|
|
EOSTDIN
|
|
|
|
./a.out
|
|
env:
|
|
# using pkg-config as pixman puts its headers in `include/pixman-1`
|
|
LDFLAGS: $(pkg-config --libs glib-2.0)
|
|
CFLAGS: $(pkg-config --cflags glib-2.0)
|