Skip to content

Commit

Permalink
Put back unconditional downloading of the GTK+3 bundle
Browse files Browse the repository at this point in the history
in `cross-build-mingw.sh`. Also re-arrange the code a little bit
to make it clearer what it's doing.
  • Loading branch information
codebrainz committed Oct 3, 2020
1 parent f6eef2a commit 937001c
Showing 1 changed file with 9 additions and 8 deletions.
17 changes: 9 additions & 8 deletions scripts/cross-build-mingw.sh
Expand Up @@ -42,13 +42,6 @@ EOF
done
shift $((OPTIND - 1))

if [ "$GTK3" = yes ]; then
BUNDLE_ZIP="$GTK3_BUNDLE_ZIP"
else
BUNDLE_ZIP="$GTK2_BUNDLE_ZIP"
CONFIGUREFLAGS="$CONFIGUREFLAGS --enable-gtk2=yes"
fi

# USAGE: fetch_and_unzip URL DEST_PREFIX
fetch_and_unzip()
{
Expand Down Expand Up @@ -88,7 +81,15 @@ cd "$BUILDDIR"

mkdir _deps

fetch_and_unzip "$BUNDLE_ZIP" _deps
# both the GTK2 and GTK3 build require files from the GTK3 bundle
# so download and unzip it unconditionally
fetch_and_unzip "$GTK3_BUNDLE_ZIP" _deps

if [ "$GTK3" = no ]; then
fetch_and_unzip "$GTK2_BUNDLE_ZIP" _deps
CONFIGUREFLAGS="$CONFIGUREFLAGS --enable-gtk2=yes"
fi

# fixup the prefix= in the pkg-config files
sed -i "s%^\(prefix=\).*$%\1$PWD/_deps%" _deps/lib/pkgconfig/*.pc

Expand Down

0 comments on commit 937001c

Please sign in to comment.