Skip to content

Commit

Permalink
added new woff2-compress-build shell script for local builds of woff2…
Browse files Browse the repository at this point in the history
…_compress dependency
  • Loading branch information
chrissimpkins committed Mar 15, 2018
1 parent 0da551b commit c0f9b0c
Showing 1 changed file with 51 additions and 0 deletions.
51 changes: 51 additions & 0 deletions tools/scripts/install/woff2-compress-build.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
#!/bin/sh

# /////////////////////////////////////////////////////////////////
#
# woff2-compress-build.sh
# A shell script that builds the woff2_compress build dependency
# Copyright 2018 Christopher Simpkins
# MIT License
#
# Usage: ./woff2-compress-build.sh
#
# /////////////////////////////////////////////////////////////////

# The woff2 git clone directory.
BUILD="$HOME"
INST="$HOME/woff2"

# woff2 executable path
WOFF2_BIN="$BUILD/woff2/woff2_compress"

if test -d "$INST" -o -f "$INST"; then
echo "Build directory \`$INST' must not exist."
exit 1
fi

cd "$BUILD" || exit 1

echo "#####"
echo "git clone woff2 project"
echo "#####"

# clone the Source Foundry fork of the woff2 repo
# contains fix for OS X build bug - https://github.com/google/woff2/issues/73

This comment has been minimized.

Copy link
@anthrotype

anthrotype Mar 15, 2018

that was fixed more than a year ago in upstream
google/woff2#72

This comment has been minimized.

Copy link
@chrissimpkins

chrissimpkins Mar 15, 2018

Author Member

It was still failing for me last fall when I wrote these scripts. I used the fixes suggested in the issue report threads there to address it in our downstream branch. Will review changelog to see if there are any changes that warrant moving away from our pinned version and back to the upstream repo. Thanks Cosimo.

This comment has been minimized.

Copy link
@chrissimpkins

chrissimpkins Mar 15, 2018

Author Member

The issue report remains open for this google/woff2#73

This comment has been minimized.

Copy link
@anthrotype

anthrotype Mar 15, 2018

can you reproduce the issue? If so please write it there, or file a separate issue if different.

This comment has been minimized.

Copy link
@chrissimpkins

chrissimpkins Mar 15, 2018

Author Member

Will re-compile it and check again.

# recursive flag to clone the brotli submodule within the woff2 repo
git clone --recursive https://github.com/source-foundry/woff2.git

cd "$INST" || exit 1

echo "#####"
echo "Build woff2"
echo "#####"

make clean all

if [ -f "$WOFF2_BIN" ]; then
echo " "
echo "woff2_compress successfully built on the path '$WOFF2_BIN'"
else
echo "The woff2_compress build failed."
exit 1
fi

0 comments on commit c0f9b0c

Please sign in to comment.