pkgsrc ... portable? MY ASS!

Eddig mar par helyen hasznaltam pkgsrc -t mert ugye ahogy szoktam mondani, a kisebbik rossz jobb. De az az allitas, hogy a pkgsrc portable, hamis.

Eddig foleg loonixon hasznaltam, mert nem voltam hajlando yastal szarakodni. Ezert el tudom mondani hogy, SLES9 -n kisebb nagyobb problemak nelkul megy is.

A kovetkezo lepesben csak kivancsisagbol, bootstrappeltem egyet Debil loonixon.

robert@debil:~$ cat /etc/debian_version && uname -a
testing/unstable
Linux debillinux.hu 2.6.17-1-itanium-smp #1 SMP Thu Jul 13 15:28:32 UTC 2006 ia64 GNU/Linux

Eloszoris probaljuk meg gcc -vel:

Using built-in specs.
Target: ia64-linux-gnu
Configured with: ../src/configure -v --enable-languages=c,c++,java,fortran,objc,obj-c++,ada,treelang --prefix=/usr --enable-shared --with-system-zlib --libexecdir=/usr/lib --without-included-gettext --enable-threads=posix --enable-nls --program-suffix=-4.1 --enable-__cxa_atexit --enable-clocale=gnu --enable-libstdcxx-debug --enable-java-awt=gtk --enable-gtk-cairo --with-java-home=/usr/lib/jvm/java-1.4.2-gcj-4.1-1.4.2.0/jre --enable-mpfr --with-system-libunwind --enable-checking=release ia64-linux-gnu
Thread model: posix
gcc version 4.1.2 20060708 (prerelease) (Debian 4.1.1-8)

Eredmeny:
Meg annyire se mukodik mint SLES9 -n. Idokozbe valamit elkurhattak a sracok kemenyen. A bootstrap utan:

221 Thank you for using the FTP service on ftp.NetBSD.org.
checksum: ``/usr/pkg/bin/digest'' is missing
ERROR: Make sure the Makefile and checksum file (/usr/pkgsrc/lang/gcc/distinfo)
ERROR: are up to date. If you want to override this check, type
ERROR: "/usr/pkg/bin/bmake NO_CHECKSUM=yes [other args]".
*** Error code 1

Utanna probaljuk icc -vel:

Intel(R) C Itanium(R) Compiler for Itanium(R)-based applications
Version 9.1 Build 20060523 Package ID: l_cc_c_9.1.039
Copyright (C) 1985-2006 Intel Corporation. All rights reserved.

Eredmeny:
Megrosszab. A bootstrap vegen megprobal gcc2 -t forditani nekem, amit senki nem kert tole. Es nem is igy kene, mivel icc a compiler. Miutan ezt workaroundoltam az mk.confban, ugyanaz a hiba mint gcc -s bootstrap utan. A bootstrap hianyos.

Aztan nezzuk a kovetkezo aldozatot. AIX...


# uname -a && oslevel -r && gcc -v
AIX Vigor31 1 5 004082BA4C00
5100-03
Using built-in specs.
Target: powerpc-ibm-aix5.1.0.0
Configured with: ../gcc-4.0.0/configure --disable-aix64 --disable-nls
Thread model: aix
gcc version 4.0.0


        gcc -g -O2 -I. -I./.. -I. -I.. -I./../libedit  -I./../libnetbsd  -c chared.c
In file included from sys.h:142,
                 from chared.c:37:
/usr/include/regex.h:174: error: conflicting types for 'regex'
/usr/include/libgen.h:42: error: previous declaration of 'regex' was here
/usr/include/regex.h:175: error: conflicting types for 'regcmp'
/usr/include/libgen.h:41: error: previous declaration of 'regcmp' was here
make: 1254-004 The error code from the last command is 1.

Stop.
make: 1254-004 The error code from the last command is 2.


/usr/include/regex.h:extern char *regex(char *, char *, char *);
/usr/include/libgen.h:extern char *regex(const char *, const char *, ...);

Hat igen... nembaj ezt workaroundoljuk a ../net/tnftp/files/libedit/sys.h -ban. Egy egyszeru if statementel, hogy ne includeoljuk a regex.h -t ha mar libgen.h includeolva van. Majd a bootstrap vegen az AIX ban talalhato install(3) -t probalta hasznalni amelyek kapcsoloi nem egyeznek a BSD kompatibilis install(1) -al. Ez azert erdekes mert az egesz bootstrap GNU configure scripteket hasznal, ami elvileg arra kenyszeritette a forditasi kornyezetet, hogy az internal install scriptet hasznalja. Na sebaj ez is csak egy env variable (INSTALL=path_to_install). Ezutan mk.conf -ban kellet kicsit hackelni, hogy ne akarjon mar nekem minden aron gcc -t perditeni amikor mar van.

# pkg_info
digest-20060302 Message digest wrapper utility
patch-2.5.4nb2 Patch files using diff output
gzip-base-1.2.4bnb1 Compress or expand files
libtool-base-1.5.22nb3 Generic shared library support script (the script itself)
bzip2-1.0.3 Block-sorting file compressor
pkg_install-info-4.5nb3 Standalone GNU info file installation utility
libiconv-1.10nb3 Character set conversion library
gettext-lib-0.14.5 Internationalized Message Handling Library (libintl)

A szomoru ebben az egeszben az, hogy felvagnak azzal, hogy pkgsrc mennyire portable. Jelzem ezek teljesen default rendeszerek voltak, szinte semmi mas beallitas nem tortent es meglepo modon azon a rendszeren mukodott a legjobban, amitol nem is vartam el.

Szep dolog, hogy egy portable dolgot akarnak csinalni, de akkor ahhoz minden valtoztatas utan le is kene tesztelni az egesz hobelebancot. Mert lehet hogy ezek 1 honapja mukodtek de azota total broken a cucc. Ezt igy eleg viccesnek tartom, mert kicsit tobb erobevitellel hasznalhattam volna az OpenBSD ports tree-t es a pkg_* tools mert az Perlben van irva, es nagyon az eselye annak hogy portable. Pedig mi csak openbsd-re szantuk.

Sot az is lehet hogy en barmoltam el valamit, bar erosen ketlem. De ha megis akkor rugdossatok meg. Es kovetelem hogy az AIX, Linux keruljon le a pkgsrc supported platforms listabol addig, amig out-of-the box megy.

Hozzászólások

Hat szerintem ezt a portable-t ugy kell erteni, hogy van egy rugalmas keretrendszer, ami hordozhato. Ez a keretrendszer keves modositast igenyel, ha uj platformra akarod ratolni. Mindemellett a konkret tamogatast egy adott platformra _meg kell csinalni_. Es hogy _jol_ tamogatott legyen, ahhoz valami elszant ember vere es veriteke szuksegeltetik. Mint ahogy Joerg Sonnenberger csinalja Dfly-on.
Igazabol szerintem nincs is mas aktualice jol tamogatott rendszer, mint a NetBSD meg a Dfly.

De _ha_ valaki komolyan akarna venni Solarison vagy Linuxon vagy Interixen vagy AIXen, lenne honnan kezdenie.

Ennel tobbet jozan esszel nemigen varhatsz, azt hiszem.

Amugy meg a pkgsrc bmake + shellben van irva ami nem kevesbe hordozhato mint a perl. Neked se a bmake forditasakor dobott dobott hibat a cucc... hanem amikor hasznalni probaltad volna.
Az hogy perlben lenne, nem ovna meg a nem mukodo kodtol.

221 Thank you for using the FTP service on ftp.NetBSD.org.
checksum: ``/usr/pkg/bin/digest'' is missing
ERROR: Make sure the Makefile and checksum file (/usr/pkgsrc/lang/gcc/distinfo)
ERROR: are up to date. If you want to override this check, type
ERROR: "/usr/pkg/bin/bmake NO_CHECKSUM=yes [other args]".
*** Error code 1

A digest ellenőrzi a letöltött források checksumját, az üzenetből az látszik, hogy ez a program hiányzik, de leírja szépen, hogy ha (b)make NO_CHECKSUM=yes változót kap, akkor nem történik ellenőrzés. Szerintem tedd fel NO_CHECKSUM=yes opcióval a digestet, és utána minden rendben kellene, hogy legyen.