pkgsrc-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: Seeking status reports on unusual operating systems



I have an update on AIX as of recent. Using -current as of ~ Jan. 27th on AIX 7.1.

I'm able to bootstrap cleanly like this:

CFLAGS=-pthread LDFLAGS=-pthread ./bootstrap --abi 64 --compiler gcc --full --prefix /opt/pkg --workdir /opt/pkg/obj/bootstrap

The only tweak I made to pkgsrc was this:

Index: sysutils/install-sh/files/install-sh.in
===================================================================
RCS file: /cvsroot/pkgsrc/sysutils/install-sh/files/install-sh.in,v
retrieving revision 1.6
diff -r1.6 install-sh.in
284c284
< if [ x"$stripcmd" != x ]; then $doit $stripcmd $stripflags "$dsttmp"; else true;fi &&
---
> if [ x"$stripcmd" != x ]; then OBJECT_MODE=64 $doit $stripcmd $stripflags "$dsttmp"; else true;fi &&



There is almost certainly a better way than that, so it's on the TODO list. That's the good news.

The bad news is that, on the way to building a pkgsrc gcc12, it's failing while building lang/perl5. Not a big surprise.

Here's what I'm doing to attempt a build (mostly derived from the RPM spec file from the "AIX toolbox for Linux applications").

bmake clean
CC=gcc
LIBS64='-L/opt/pkg/lib:/opt/freeware/lib64:/opt/freeware/lib'
CFLAGS64='-O2 -maix64'
CFLAGS="$CFLAGS64 $LIBS64"
CXXFLAGS="${CFLAGS}"
LDFLAGS="-Wl,-s -Wl,-lpthreads -Wl,-brtl -Wl,-bdynamic -Wl,-b64 ${LIBS64} -Wl,-blibpath:/opt/pkg/lib/perl5/5.36.0/powerpc64-aix-thread-multi-64all/CORE:/opt/pkg/lib:/opt/freeware/lib64:/usr/lib64:/opt/freeware/lib:/usr/lib:/lib" LDDLFLAGS="-G -bI:\$(PERL_INC)/perl.exp -bE:\$(BASEEXT).exp -bnoentry -lc -lm ${LIBS64}"

export CC CFLAGS LDFLAGS LDDLFLAGS

bmake

... and here's where it fails ...


gcc -maix64 -c -D_THREAD_SAFE -O2 -maix64 -L/opt/pkg/lib:/opt/freeware/lib64:/opt/freeware/lib -pthread -D_REENTRANT -I/usr/include -D_ALL_SOURCE -D_ANSI_C_SOURCE -D_POSIX_SOURCE -DUSE_NATIVE_DLOPEN -DNEED_PTHREAD_INIT -fwrapv -fno-strict-aliasing -pipe -maix64 -DUSE_64_BIT_ALL -D_FORTIFY_SOURCE=2 -Wall -Werror=pointer-arith -Werror=vla -Wextra -Wno-long-long -Wno-declaration-after-statement -Wc++-compat -Wwrite-strings -O2 -maix64 -L/opt/pkg/lib:/opt/freeware/lib64:/opt/freeware/lib -pthread -D_REENTRANT -I/usr/include -DVERSION=\"1.64\" -DXS_VERSION=\"1.64\" "-I../.." shared.c "../../miniperl" "-I../../lib" -MExtUtils::Mksymlists -e "Mksymlists('NAME'=>\"threads::shared\", 'DLBASE' => 'shared', 'DL_FUNCS' => { }, 'FUNCLIST' => [], 'IMPORTS' => { }, 'DL_VARS' => []);"
rm -f ../../lib/auto/threads/shared/shared.so
gcc -maix64 -Wl,-R/opt/pkg/lib/perl5/5.36.0/powerpc64-aix-thread-multi-64all/CORE -Wl,-b64 -Wl,-bhalt:4 -Wl,-G -Wl,-bI:../../perl.exp -Wl,-bnoentry -lpthreads -lc -lm -L/opt/pkg/lib:/opt/freeware/lib64:/opt/freeware/lib -L/usr/lib -Wl,-R/usr/lib -Wl,-R/opt/pkg/lib -Wl,-bE:shared.exp shared.o -o ../../lib/auto/threads/shared/shared.so ld: 0706-027 The -R /opt/pkg/lib/perl5/5.36.0/powerpc64-aix-thread-multi-64all/CORE flag is ignored.
ld: 0706-027 The -R /opt/pkg/lib flag is ignored.
ld: 0706-027 The -R /opt/pkg/lib/perl5/5.36.0/powerpc64-aix-thread-multi-64all/CORE flag is ignored.
ld: 0706-027 The -R /opt/pkg/lib flag is ignored.
chmod 755 ../../lib/auto/threads/shared/shared.so
LIBPATH=/opt/pkg/obj/lang/perl5/work/perl-5.36.0 ./perl -Ilib -I. -f pod/buildtoc -q Can't load 'lib/auto/re/re.so' for module re: Symbol resolution failed for lib/auto/re/re.so because:
        Thread-local variable PL_current_context (number 236)
                  is imported from a dynamically-loaded dependent
                  module perl, but
                  the initial-exec model was used.
Examine .loader section relocation entries with the 'dump -Rv' command.
Examine .loader section symbols with the 'dump -Tv' command. at lib/XSLoader.pm line 94.
 at lib/re.pm line 95.
Compilation failed in require at lib/Text/Wrap.pm line 48.
BEGIN failed--compilation aborted at lib/Text/Wrap.pm line 48.
Compilation failed in require at pod/buildtoc line 6.
BEGIN failed--compilation aborted at pod/buildtoc line 6.
*** Error code 8

Stop.
bmake: stopped in /opt/pkg/obj/lang/perl5/work/perl-5.36.0
*** Error code 1


--
Louis

On 4/4/22 4:15 PM, Louis Guillaume wrote:
Hi Greg,

On AIX 7.1, a clean bootstrap (using -current) attempt fails:

# gcc --version
gcc (GCC) 8.3.0
Copyright (C) 2018 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.


# ./bootstrap --abi 64 --compiler gcc --full --pkgdbdir /opt/pkg/.dbdir --prefix /opt/pkg --sysconfbase /opt/pkg/etc --workdir /opt/pkg/bootstrap


I had made some attempt to get it working last year, got a working bootstrap (seemingly) but eventually threw in the towel. AIX ld just doesn't play nice with many packages it seems.

Right now the first thing to fail is trying to link libnbcompat; a pthreads issue. That can be worked around, but I know it's the first of many characters in a deep rabbit hole.

I'd love to help to get it working again.

--
Louis

On 3/31/22 7:02 PM, Greg Troxel wrote:

pkgsrc runs or has run on many operating systems, but time marches on
and one needs a C++17 compiler to compile a lot of things, which doesn't
go so well with the gcc3 binaries for systems that went out of support
20 years ago :-)

But seriously, it would be nice if the list in bootstrap/README of which
systems don't work were more up to date.  This message is a call for
data.

There are four platforms where it is well know that they work:
   NetBSD
   Solaris
   macOS
   Linux
so no need to mention them.

FreeBSD is listed in the "works well" list in bootstrap/README but not
at www.pkgsrc.org.  It's pretty clearly 5th on the list of works-well
platforms, so that's fair but it would be nice to sort it better.  If
you are actively building on FreeBSD (did a bootstrap of 2022Q1, have
built a lot of packages, using it seriosly, etc.), pleaes speak up here.
Or if you have used it in the last year, please say that here or just to
me.  If you are doing bulk builds, please say that here too, and
consider sending them to pkgsrc-bulk (where I don't see any reports).

Beyond FreeBSD, for all other platforms, it would be good to get a
bootstrap works/doesn't-work status for 2022Q1, and if it doesn't work
and you know the last quarterly branch where it did work, that's
interesting too.

And, if you actually use pkgsrc on a platform that lacks a
README.${platform}, please write one and send it here or to me
privately.

I will interpret lack of response about a platform by the end of 14
April to mean "this platform is believed to have no users".

Thanks,
Greg


Home | Main Index | Thread Index | Old Index