2019-08-04 09:26:52 -06:00
|
|
|
#!/bin/sh -e
|
|
|
|
|
2019-08-04 10:54:25 -06:00
|
|
|
build_freetype() (
|
|
|
|
cd freetype
|
2019-08-04 09:26:52 -06:00
|
|
|
|
|
|
|
./configure \
|
|
|
|
--prefix=/usr \
|
2019-08-04 10:54:25 -06:00
|
|
|
--enable-freetype-config \
|
2021-08-08 11:57:04 -06:00
|
|
|
--with-harfbuzz="$2" \
|
|
|
|
--with-bzip2=no \
|
2019-08-04 09:26:52 -06:00
|
|
|
|
|
|
|
make
|
2021-07-17 12:54:51 -06:00
|
|
|
make install
|
2019-08-04 09:26:52 -06:00
|
|
|
)
|
|
|
|
|
2019-08-04 10:54:25 -06:00
|
|
|
build_harfbuzz() (
|
2020-07-28 05:14:10 -06:00
|
|
|
# Point Harfbuzz to the Freetype files.
|
|
|
|
export CXXFLAGS="$CXXFLAGS -I$1/usr/include/freetype2"
|
|
|
|
export LDFLAGS="$LDFLAGS -L$1/usr/lib"
|
|
|
|
|
2019-08-04 10:54:25 -06:00
|
|
|
cd harfbuzz
|
2019-08-04 09:26:52 -06:00
|
|
|
|
2020-07-28 05:14:10 -06:00
|
|
|
meson \
|
2020-07-27 07:45:56 -06:00
|
|
|
--prefix=/usr \
|
2020-07-28 05:14:10 -06:00
|
|
|
-Dpkg_config_path="$1/usr/lib/pkgconfig" \
|
|
|
|
-Ddefault_library=both \
|
2021-08-08 11:19:30 -06:00
|
|
|
-Dglib=disabled \
|
2020-07-28 05:14:10 -06:00
|
|
|
-Dfreetype=enabled \
|
2021-08-08 11:19:30 -06:00
|
|
|
-Dgobject=disabled \
|
2020-07-28 05:14:10 -06:00
|
|
|
-Dcairo=disabled \
|
|
|
|
-Dicu=disabled \
|
|
|
|
-Dbenchmark=disabled \
|
|
|
|
-Dtests=disabled \
|
|
|
|
. output
|
|
|
|
|
|
|
|
ninja -C output
|
|
|
|
ninja -C output install
|
2019-08-04 09:26:52 -06:00
|
|
|
)
|
|
|
|
|
|
|
|
build_freetype "$1" no
|
|
|
|
build_harfbuzz "$1"
|
2019-08-04 10:54:25 -06:00
|
|
|
|
|
|
|
# Point Freetype to the Harfbuzz files.
|
|
|
|
export HARFBUZZ_CFLAGS="-I$PWD/harfbuzz/src"
|
2020-07-28 05:14:10 -06:00
|
|
|
export HARFBUZZ_LIBS="-L$PWD/harfbuzz/output/src -lharfbuzz"
|
2019-08-04 10:54:25 -06:00
|
|
|
|
2019-08-04 09:26:52 -06:00
|
|
|
build_freetype "$1" yes
|