Skip to content

Commit a2ee613

Browse files
committed
debug: Enhance build and install scripts with GLIBC dependency checks
1 parent 9eff462 commit a2ee613

File tree

2 files changed

+47
-0
lines changed

2 files changed

+47
-0
lines changed

.github/packaging/project/build_package.sh

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,32 @@ function build_packages(){
77
chown -R root:root .
88
GIT_DIR=$(git rev-parse --show-toplevel)
99
cd "$GIT_DIR"
10+
11+
echo "=== BEFORE PyInstaller: Checking Python environment ==="
12+
echo "Python version and location:"
13+
which python && python --version
14+
echo "Python GLIBC dependencies:"
15+
ldd $(which python)
16+
echo "Pipenv location and version:"
17+
which pipenv && pipenv --version
18+
19+
echo "=== Running PyInstaller build ==="
1020
make one-file
21+
22+
echo "=== AFTER PyInstaller: Checking built binary dependencies ==="
23+
if [ -f "$GIT_DIR/build/bin/asadm" ]; then
24+
echo "Built binary GLIBC dependencies:"
25+
ldd "$GIT_DIR/build/bin/asadm" | head -20
26+
echo "=== All GLIBC versions required by built binary ==="
27+
ldd "$GIT_DIR/build/bin/asadm" | grep "GLIBC_" | sort -V | uniq
28+
echo "=== Checking if binary is dynamically linked or static ==="
29+
file "$GIT_DIR/build/bin/asadm"
30+
echo "=== Binary size and type ==="
31+
ls -lh "$GIT_DIR/build/bin/asadm"
32+
else
33+
echo "Binary not found at expected location"
34+
find "$GIT_DIR/build" -name "asadm" -exec ls -la {} \;
35+
fi
1136
cd $GIT_DIR/pkg
1237
echo "building package for $BUILD_DISTRO"
1338

.github/packaging/project/install_deps.sh

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -200,7 +200,29 @@ function install_deps_el9() {
200200
/opt/golang/go/bin/go install github.com/asdf-vm/asdf/cmd/[email protected]
201201
install /root/go/bin/asdf /usr/local/bin/asdf
202202
asdf plugin add python https://github.com/asdf-community/asdf-python.git
203+
echo "=== DEBUGGING GLIBC DEPENDENCIES ==="
204+
echo "System GLIBC version:"
205+
ldd --version
206+
207+
echo "=== BEFORE asdf install: System GLIBC symbols available ==="
208+
echo "Available GLIBC versions in system:"
209+
find /lib* /usr/lib* -name "libc.so.*" -exec strings {} \; 2>/dev/null | grep "GLIBC_" | sort -V | uniq | tail -10
210+
211+
echo "=== Installing Python with asdf (will show if it downloads pre-compiled vs compiles) ==="
212+
# First, try normal installation to see what happens
203213
asdf install python 3.10.18
214+
215+
echo "=== POST asdf install: Checking Python GLIBC dependencies ==="
216+
echo "Python binary dependencies:"
217+
ldd /root/.asdf/installs/python/3.10.18/bin/python
218+
219+
echo "=== All GLIBC versions required by Python installation ==="
220+
find /root/.asdf/installs/python/3.10.18 -name "*.so*" -exec ldd {} \; 2>/dev/null | grep "GLIBC_" | sort -V | uniq
221+
222+
echo "=== Checking libgcc_s.so.1 specifically ==="
223+
find /root/.asdf/installs/python/3.10.18 -name "*libgcc*" -exec ls -la {} \; 2>/dev/null || echo "No libgcc files found"
224+
echo "=== libgcc GLIBC requirements ==="
225+
find /root/.asdf/installs/python/3.10.18 -name "*libgcc*" -exec ldd {} \; 2>/dev/null | grep "GLIBC_" | sort -V | uniq || echo "No libgcc GLIBC dependencies to check"
204226
asdf set python 3.10.18
205227
echo "python 3.10.18" > /.tool-versions
206228
echo "python 3.10.18" > /root/.tool-versions

0 commit comments

Comments
 (0)