Skip to content

Commit

Permalink
CI (wheels): Use flex and bison from the distro
Browse files Browse the repository at this point in the history
This should be more efficient and will not rely on GNU servers which are currently down. The downside is that they are not pinned anymore, but these packages shouldn't have breaking changes.

PiperOrigin-RevId: 680981189
  • Loading branch information
oprypin authored and copybara-github committed Oct 1, 2024
1 parent 07fd169 commit 83e28a7
Showing 1 changed file with 1 addition and 33 deletions.
34 changes: 1 addition & 33 deletions build_scripts/wheels/manylinux.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,41 +8,9 @@ if [[ -z "$PLAT" ]]; then
exit 1
fi

dnf install -y ninja-build gettext-devel python3-devel # gettext is for flex

# TODO: what should be the update cadence for these?
BISON_VERSION='3.6'
FLEX_VERSION='2.6.4'

untar() {
mkdir -pv "$1"
tar -C "$1" -xzvf "${1}.tar.gz" --strip-components=1
rm -vf "${1}.tar.gz"
}

TD="$(mktemp -d)"
pushd "$TD" || exit 1

# Install Flex
curl -sSL \
-o flex.tar.gz \
"https://github.com/westes/flex/releases/download/v${FLEX_VERSION}/flex-${FLEX_VERSION}.tar.gz"
untar flex
pushd flex
./autogen.sh && ./configure && make && make install
popd

# Install GNU Bison
curl -sSL \
-o bison.tar.gz \
"https://ftp.gnu.org/gnu/bison/bison-${BISON_VERSION}.tar.gz"
untar bison
pushd bison
./configure && make && make install

dnf install -y ninja-build python3-devel flex bison
cd /io
dirs -c
rm -rf "$TD"

cmake --version
ninja --version
Expand Down

0 comments on commit 83e28a7

Please sign in to comment.