Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 47f1722

Browse files
authored
gh-117088: Fix AIX build (GH-132595)
1 parent efcc42b commit 47f1722

File tree

2 files changed

+7
-1
lines changed

2 files changed

+7
-1
lines changed

Makefile.pre.in

+6-1
Original file line numberDiff line numberDiff line change
@@ -1012,7 +1012,12 @@ $(LIBRARY): $(LIBRARY_OBJS)
10121012
$(AR) $(ARFLAGS) $@ $(LIBRARY_OBJS)
10131013

10141014
libpython$(LDVERSION).so: $(LIBRARY_OBJS) $(DTRACE_OBJS)
1015-
$(BLDSHARED) -Wl,-h$(INSTSONAME) -o $(INSTSONAME) $(LIBRARY_OBJS) $(MODLIBS) $(SHLIBS) $(LIBC) $(LIBM)
1015+
# AIX Linker don't support "-h" option
1016+
if test "$(MACHDEP)" != "aix"; then \
1017+
$(BLDSHARED) -Wl,-h$(INSTSONAME) -o $(INSTSONAME) $(LIBRARY_OBJS) $(MODLIBS) $(SHLIBS) $(LIBC) $(LIBM); \
1018+
else \
1019+
$(BLDSHARED) -o $@ $(LIBRARY_OBJS) $(MODLIBS) $(SHLIBS) $(LIBC) $(LIBM); \
1020+
fi
10161021
if test $(INSTSONAME) != $@; then \
10171022
$(LN) -f $(INSTSONAME) $@; \
10181023
fi
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
AIX linker don't support -h option, so avoid it through platform check

0 commit comments

Comments
 (0)