Skip to content

Commit c0bcaf0

Browse files
committed
ease arch constraints from x86 and ppc64le
Signed-off-by: Md. Shafi Hussain <[email protected]>
1 parent 9df7d38 commit c0bcaf0

File tree

2 files changed

+17
-21
lines changed

2 files changed

+17
-21
lines changed

jupyter/utils/install_pandoc.sh

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ UNAME_TO_GOARCH["s390x"]="s390x"
1111
ARCH="${UNAME_TO_GOARCH[$(uname -m)]}"
1212

1313
if [[ "$ARCH" == "ppc64le" ]]; then
14+
1415
# Install Pandoc from source
1516
dnf install -y https://dl.fedoraproject.org/pub/epel/epel-release-latest-9.noarch.rpm
1617
dnf install -y pandoc
@@ -19,14 +20,12 @@ if [[ "$ARCH" == "ppc64le" ]]; then
1920
export PATH="/usr/local/pandoc/bin:$PATH"
2021
pandoc --version
2122

22-
elif [[ "$ARCH" == "amd64" ]]; then
23+
else
24+
2325
# pandoc installation
2426
curl -fL "https://github.com/jgm/pandoc/releases/download/3.7.0.2/pandoc-3.7.0.2-linux-${ARCH}.tar.gz" -o /tmp/pandoc.tar.gz
2527
mkdir -p /usr/local/pandoc
2628
tar xvzf /tmp/pandoc.tar.gz --strip-components 1 -C /usr/local/pandoc/
2729
rm -f /tmp/pandoc.tar.gz
2830

29-
else
30-
echo "Unsupported architecture: $ARCH" >&2
31-
exit 1
3231
fi

jupyter/utils/install_texlive.sh

Lines changed: 14 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -11,23 +11,23 @@ UNAME_TO_GOARCH["s390x"]="s390x"
1111
ARCH="${UNAME_TO_GOARCH[$(uname -m)]}"
1212

1313
if [[ "$ARCH" == "ppc64le" ]]; then
14+
1415
echo "Installing TeX Live from source for $ARCH..."
1516

1617
# Install build dependencies
1718
dnf install -y gcc-toolset-13 perl make libX11-devel \
1819
zlib-devel freetype-devel libpng-devel ncurses-devel \
19-
gd-devel libtool wget tar xz
20-
21-
rpm -q libXmu-devel || rpm -ivh --nodeps https://mirror.stream.centos.org/9-stream/AppStream/ppc64le/os/Packages/libXmu-devel-1.1.3-8.el9.ppc64le.rpm
22-
rpm -q libXext-devel|| rpm -ivh --nodeps https://mirror.stream.centos.org/9-stream/AppStream/ppc64le/os/Packages/libXext-devel-1.3.4-8.el9.ppc64le.rpm
23-
rpm -q libICE-devel || rpm -ivh --nodeps https://mirror.stream.centos.org/9-stream/AppStream/ppc64le/os/Packages/libICE-devel-1.0.10-8.el9.ppc64le.rpm
24-
rpm -q libSM-devel || rpm -ivh --nodeps https://mirror.stream.centos.org/9-stream/AppStream/ppc64le/os/Packages/libSM-devel-1.2.3-10.el9.ppc64le.rpm
25-
rpm -q libXmu || rpm -ivh --nodeps https://mirror.stream.centos.org/9-stream/AppStream/ppc64le/os/Packages/libXmu-1.1.3-8.el9.ppc64le.rpm
26-
rpm -q libXaw-devel || rpm -ivh --nodeps https://mirror.stream.centos.org/9-stream/AppStream/ppc64le/os/Packages/libXaw-devel-1.0.13-19.el9.ppc64le.rpm
27-
rpm -q libXaw || rpm -ivh --nodeps https://mirror.stream.centos.org/9-stream/AppStream/ppc64le/os/Packages/libXaw-1.0.13-19.el9.ppc64le.rpm
28-
rpm -q libXt-devel || rpm -ivh --nodeps https://mirror.stream.centos.org/9-stream/AppStream/ppc64le/os/Packages/libXt-devel-1.2.0-6.el9.ppc64le.rpm
29-
rpm -q flex || rpm -ivh --nodeps https://mirror.stream.centos.org/9-stream/AppStream/ppc64le/os/Packages/flex-2.6.4-9.el9.ppc64le.rpm
30-
rpm -q bison || rpm -ivh --nodeps https://mirror.stream.centos.org/9-stream/AppStream/ppc64le/os/Packages/bison-3.7.4-5.el9.ppc64le.rpm
20+
gd-devel libtool wget tar xz \
21+
https://mirror.stream.centos.org/9-stream/AppStream/ppc64le/os/Packages/libXmu-devel-1.1.3-8.el9.ppc64le.rpm \
22+
https://mirror.stream.centos.org/9-stream/AppStream/ppc64le/os/Packages/libXext-devel-1.3.4-8.el9.ppc64le.rpm \
23+
https://mirror.stream.centos.org/9-stream/AppStream/ppc64le/os/Packages/libICE-devel-1.0.10-8.el9.ppc64le.rpm \
24+
https://mirror.stream.centos.org/9-stream/AppStream/ppc64le/os/Packages/libSM-devel-1.2.3-10.el9.ppc64le.rpm \
25+
https://mirror.stream.centos.org/9-stream/AppStream/ppc64le/os/Packages/libXmu-1.1.3-8.el9.ppc64le.rpm \
26+
https://mirror.stream.centos.org/9-stream/AppStream/ppc64le/os/Packages/libXaw-devel-1.0.13-19.el9.ppc64le.rpm \
27+
https://mirror.stream.centos.org/9-stream/AppStream/ppc64le/os/Packages/libXaw-1.0.13-19.el9.ppc64le.rpm \
28+
https://mirror.stream.centos.org/9-stream/AppStream/ppc64le/os/Packages/libXt-devel-1.2.0-6.el9.ppc64le.rpm \
29+
https://mirror.stream.centos.org/9-stream/AppStream/ppc64le/os/Packages/flex-2.6.4-9.el9.ppc64le.rpm \
30+
https://mirror.stream.centos.org/9-stream/AppStream/ppc64le/os/Packages/bison-3.7.4-5.el9.ppc64le.rpm
3131

3232
# Step 1: Download and extract the TeX Live source
3333
wget https://ftp.math.utah.edu/pub/tex/historic/systems/texlive/2025/texlive-20250308-source.tar.xz
@@ -81,7 +81,8 @@ ln -sf "$TEX_BIN_DIR" /usr/local/texlive/bin/linux
8181
pdflatex --version
8282
tlmgr --version
8383

84-
elif [[ "$ARCH" == "amd64" ]]; then
84+
else
85+
8586
# tex live installation
8687
echo "Installing TexLive to allow PDf export from Notebooks"
8788
curl -fL https://mirror.ctan.org/systems/texlive/tlnet/install-tl-unx.tar.gz -o install-tl-unx.tar.gz
@@ -92,9 +93,5 @@ elif [[ "$ARCH" == "amd64" ]]; then
9293
cd /usr/local/texlive/bin/linux
9394
./tlmgr install tcolorbox pdfcol adjustbox titling enumitem soul ucs collection-fontsrecommended
9495

95-
else
96-
echo "Unsupported architecture: $ARCH" >&2
97-
exit 1
98-
9996
fi
10097

0 commit comments

Comments
 (0)