Changes between Initial Version and Version 1 of npl/mediabox/libsdl-image


Ignore:
Timestamp:
08/08/08 00:10:42 (13 years ago)
Author:
trac
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • npl/mediabox/libsdl-image

    v1 v1  
     1Downloaden en standaard buildscript proberen:
     2{{{
     3psy npl # mkdir mediabox/libsdl_image
     4psy npl # cd mediabox/libsdl_image/
     5psy libsdl_image # wget http://www.libsdl.org/projects/SDL_image/release/SDL_image-1.2.6.tar.gz
     6--16:10:58--  http://www.libsdl.org/projects/SDL_image/release/SDL_image-1.2.6.tar.gz
     7           => `SDL_image-1.2.6.tar.gz'
     8Resolving www.libsdl.org... 208.97.185.109
     9Connecting to www.libsdl.org|208.97.185.109|:80... connected.
     10HTTP request sent, awaiting response... 200 OK
     11Length: 1,308,812 (1.2M) [application/x-tar]
     12
     13100%[===============================================================================================================>] 1,308,812    350.32K/s    ETA 00:00
     14
     1516:11:05 (194.10 KB/s) - `SDL_image-1.2.6.tar.gz' saved [1308812/1308812]
     16
     17psy libsdl_image # cp ../../.SlackBuild.example libglew.SlackBuild
     18psy libsdl_image # cp ../../packagename.SlackBuild.example libsdl_image.SlackBuild
     19psy libsdl_image # cd ../..
     20psy npl # ./rebuildcheck libsdl_image
     21REBUILD REQUIRED: ./SDL_image-1.2.6.tar.gz has changed!
     22REBUILDING /home/psy/syn3/npl/mediabox/libsdl_image/libsdl_image.SlackBuild:
     23Buildroot up-to-date check: ............................................................................................................DONE
     24Buildroot /home/psy/syn3/builder/buildroot0 repareren/syncen...OK
     25/home/psy/syn3/npl/mediabox/libsdl_image word gekopieerd naar werkdirectory /home/psy/syn3/builder/buildroot0/tmp/build
     26*** Chroot naar /home/psy/syn3/builder/buildroot0 en starten van libsdl_image.SlackBuild in /tmp/build:
     27/dev/pts/43: No such file or directory
     281 /tmp/build > basename ./libsdl_image.SlackBuild
     291 /tmp/build > sed s/.SlackBuild//
     3026 /tmp/build > NAME=libsdl_image
     311 /tmp/build > ls SDL_image-1.2.6.tar.gz
     32...
     33checking for sdl-config... no
     34checking for SDL - version >= 1.2.10... no
     35*** The sdl-config script installed by SDL could not be found
     36*** If SDL was installed in PREFIX, make sure PREFIX/bin is in
     37*** your path, or set the SDL_CONFIG environment variable to the
     38*** full path to sdl-config.
     39configure: error: *** SDL version 1.2.10 not found!
     4018 /tmp/build/SDL_image-1.2.6 > exit 1
     4157 /tmp/build > exit 1
     42*** Er ging iets mis tijdens het bakken in de buildroot!
     43Error while rebuilding /home/psy/syn3/npl/mediabox/libsdl_image/libsdl_image.SlackBuild!
     44psy npl #     
     45}}}
     46
     47Het lijkt er op dat we libsdl nodig zijn als dependency. (best logisch ook). We zetten ''#NEED:libsdl'' in de slackbuild en proberen het nog eens. Deze heeft zeer veel diepere dependencies, dus het duurt even om de buildroot te vullen. Koffie dus! Sterker nog het is zaterdag, dus even een lekker Bitburger biertje er bij:
     48{{{
     49checking for SDL - version >= 1.2.10... no
     50*** Could not run SDL test program, checking why...
     51*** The test program failed to compile or link. See the file config.log for the
     52*** exact error that occured. This usually means SDL was incorrectly installed
     53*** or that you have moved SDL since it was installed. In the latter case, you
     54*** may want to edit the sdl-config script: /usr/bin/sdl-config
     55configure: error: *** SDL version 1.2.10 not found!
     56psy npl # ./findpkg libsdl
     57/home/psy/syn3/npl/.tmp/D/libsdl-1.2.11-i586-3073.tgz
     58}}}
     59
     60Aiiii...het werkt nog niet, we hebben versie 1.2.11, dus het moet werken zou je zeggen. We duiken de buildroot in en gaan op onderzoek uit:
     61{{{
     62psy npl # chroot ../builder/buildroot0/
     63stderr is not a tty - where are you?
     64[Syn-3] root@darkstar.example.net /# cd /tmp/build/
     65SDL_image-1.2.6          SDL_image-1.2.6.tar.gz   libsdl_image.SlackBuild
     66[Syn-3] root@darkstar.example.net /# cd /tmp/build/SDL_image-1.2.6
     67[Syn-3] root@darkstar.example.net /tmp/build/SDL_image-1.2.6# cat config.
     68config.guess  config.log    config.sub
     69[Syn-3] root@darkstar.example.net /tmp/build/SDL_image-1.2.6# cat config.log
     70...
     71configure:20120: result: no
     72configure:20159: gcc -o conftest -g -O2 -I/usr/include/SDL -D_GNU_SOURCE=1 -D_REENTRANT   conftest.c  -L/usr/lib -Wl,-rpath,/usr/lib -lSDL -lpthread >&5
     73/usr/lib/gcc-lib/i486-slackware-linux/3.3.4/../../../../i486-slackware-linux/bin/ld: warning: libdirectfb-0.9.so.25, needed by /usr/lib/libSDL.so, not found (try using -rpath or -rpath-link)
     74/usr/lib/gcc-lib/i486-slackware-linux/3.3.4/../../../../i486-slackware-linux/bin/ld: warning: libfusion-0.9.so.25, needed by /usr/lib/libSDL.so, not found (try using -rpath or -rpath-link)
     75/usr/lib/gcc-lib/i486-slackware-linux/3.3.4/../../../../i486-slackware-linux/bin/ld: warning: libdirect-0.9.so.25, needed by /usr/lib/libSDL.so, not found (try using -rpath or -rpath-link)
     76/usr/lib/libSDL.so: undefined reference to `DirectFBCreate'
     77/usr/lib/libSDL.so: undefined reference to `DirectFBErrorString'
     78/usr/lib/libSDL.so: undefined reference to `DirectFBError'
     79/usr/lib/libSDL.so: undefined reference to `DirectFBInit'
     80collect2: ld returned 1 exit status
     81...
     82}}}
     83
     84We zien in de config.log, een stuk vanaf het einde van de file dat libSDL.so de dependency libdirectfb nodig is. Vreemd, want deze moet automatisch geinstalled worden. We onderenzoeken libSDL.so wat beter:
     85{{{
     86[Syn-3] root@darkstar.example.net /tmp/build/SDL_image-1.2.6# ldd /usr/lib/libSDL.so
     87        libm.so.6 => /lib/libm.so.6 (0xb7e48000)
     88        libX11.so.6 => /usr/X11/lib/libX11.so.6 (0xb7d5b000)
     89        libXext.so.6 => /usr/X11/lib/libXext.so.6 (0xb7d4d000)
     90        libXrandr.so.2 => /usr/X11/lib/libXrandr.so.2 (0xb7d49000)
     91        libXrender.so.1 => /usr/X11/lib/libXrender.so.1 (0xb7d3f000)
     92        libdirectfb-0.9.so.25 => not found
     93        libfusion-0.9.so.25 => not found
     94        libdirect-0.9.so.25 => not found
     95        libz.so.1 => /usr/lib/libz.so.1 (0xb7d2d000)
     96        libdl.so.2 => /lib/libdl.so.2 (0xb7d2a000)
     97        libpthread.so.0 => /lib/libpthread.so.0 (0xb7cd8000)
     98        libc.so.6 => /lib/libc.so.6 (0xb7ba9000)
     99        libXau.so.6 => /usr/X11/lib/libXau.so.6 (0xb7ba6000)
     100        libXdmcp.so.6 => /usr/X11/lib/libXdmcp.so.6 (0xb7ba1000)
     101        /lib/ld-linux.so.2 => /lib/ld-linux.so.2 (0x80000000)
     102[Syn-3] root@darkstar.example.net /tmp/build/SDL_image-1.2.6# find / |grep libdirectfb
     103...
     104/usr/lib/libdirectfb-1.0.so.0.0.0
     105/usr/lib/libdirectfb.so
     106/usr/lib/libdirectfb-1.0.so.0
     107/usr/lib/libdirectfb.la
     108}}}
     109
     110Shit...libsdl is gelinked tegen libdirectfb 0.9, terwijl libdirectfb 1.0 geinstalleerd is! Dit betekend dat iemand ooit een nieuwe versie voor libdirectfb gebuild heeft en dat libsdl niet gerebuild is. We kijken in libsdl en veranderen de #NEED in #DEP. Zo zorgen we ervoor dat libsdl automatisch gerebuild word bij een andere versie van libdirectfb. Ook zetten we in ons eigen script een #DEP, zodat we zeker weten dat deze ook rebuild als libsdl ooit vernieuwd word..
     111
     112We doen een rebuildcheck op libsdl_image, waardoor libsdl nu automatisch gerebuild word en daarna libsdl_image nogmaals. (hopenlijk;). Dit gaat allemaal nog langer duren, dus we lurken rustig van ons bier en wachten af:
     113{{{
     114psy npl # mcedit mediabox/libsdl/libsdl.SlackBuild
     115
     116psy npl # mcedit -dc mediabox/libsdl_image/libsdl_image.SlackBuild
     117
     118psy npl # ./rebuildcheck libsdl_image
     119Dependency check libsdl (use ignoredep to skip)
     120|-Dependency check DirectFB (use ignoredep to skip)
     121|-REBUILD REQUIRED: ./libsdl.SlackBuild has changed!
     122|-Rebuild required: Dependency MD5 changed /home/psy/syn3/npl/mediabox/DirectFB/DirectFB!
     123|-(use ignoredep to ignore dependency changes)
     124|-Was builded against:
     125cat: /home/psy/syn3/npl/mediabox/libsdl/libsdl.depver: No such file or directory
     126|-REBUILDING /home/psy/syn3/npl/mediabox/libsdl/libsdl.SlackBuild:
     127...
     128*** Build gelukt.
     129* Packages terugmoven naar originele directory..
     130/home/psy/syn3/builder/buildroot0/tmp/build/libsdl.arch /home/psy/syn3/builder/buildroot0/tmp/build/libsdl_dev.arch ...
     131/home/psy/syn3/builder/buildroot0/tmp/build/libsdl.version /home/psy/syn3/builder/buildroot0/tmp/build/libsdl_dev.version ...
     132/home/psy/syn3/builder/buildroot0/tmp/build/libsdl.pkg /home/psy/syn3/builder/buildroot0/tmp/build/libsdl_dev.pkg ...
     133
     134* Klaar ja!
     135|-Updating md5 for /home/psy/syn3/npl/mediabox/libsdl/libsdl.SlackBuild...
     136|-Updating dependency information for /home/psy/syn3/npl/mediabox/libsdl/libsdl.SlackBuild...
     137REBUILD REQUIRED: ./SDL_image-1.2.6.tar.gz has changed!
     138...
     139*** Build gelukt.
     140* Packages terugmoven naar originele directory..
     141/home/psy/syn3/builder/buildroot0/tmp/build/libsdl_image.arch /home/psy/syn3/builder/buildroot0/tmp/build/libsdl_image_dev.arch ...
     142/home/psy/syn3/builder/buildroot0/tmp/build/libsdl_image.version /home/psy/syn3/builder/buildroot0/tmp/build/libsdl_image_dev.version ...
     143/home/psy/syn3/builder/buildroot0/tmp/build/libsdl_image.pkg /home/psy/syn3/builder/buildroot0/tmp/build/libsdl_image_dev.pkg ...
     144
     145* Klaar ja!
     146Updating md5 for /home/psy/syn3/npl/mediabox/libsdl_image/libsdl_image.SlackBuild...
     147Updating dependency information for /home/psy/syn3/npl/mediabox/libsdl_image/libsdl_image.SlackBuild...
     148All rebuilds completed.
     149
     150
     151}}}
     152
     153Het rebuilden van libsdl EN libsdl_image gaat nu goed! Het probleem lag dus bij een ander pakketje. We zijn er in geslaagd om libsdl_image simpelweg te builden door het standaard buildscript te gebruiken met 1 DEP er in voor libsdl.
     154
     155We bekijken de inhoud van het pakketje:
     156{{{
     157psy npl # tar -tzf mediabox/libsdl_image/libsdl_image.pkg
     158./
     159install/
     160install/doinst.sh
     161usr/
     162usr/lib/
     163usr/lib/libSDL_image-1.2.so.0.1.5
     164psy npl # tar -tzf mediabox/libsdl_image/libsdl_image_dev.pkg
     165./
     166usr/
     167usr/lib/
     168usr/lib/libSDL_image.la
     169usr/lib/libSDL_image.a
     170usr/include/
     171usr/include/SDL/
     172usr/include/SDL/SDL_image.h
     173}}}
     174
     175Dit ziet er goed uit. Tijd om toe te voegen aan SVN:
     176{{{
     177psy npl # svn add mediabox/libsdl_image
     178A         mediabox/libsdl_image
     179A  (bin)  mediabox/libsdl_image/SDL_image-1.2.6.tar.gz
     180A         mediabox/libsdl_image/libsdl_image.SlackBuild
     181A         mediabox/libsdl_image/libsdl_image.arch
     182A         mediabox/libsdl_image/libsdl_image_dev.arch
     183A         mediabox/libsdl_image/libsdl_image.version
     184A         mediabox/libsdl_image/libsdl_image_dev.version
     185A  (bin)  mediabox/libsdl_image/libsdl_image.pkg
     186A  (bin)  mediabox/libsdl_image/libsdl_image_dev.pkg
     187A         mediabox/libsdl_image/libsdl_image.md5
     188A         mediabox/libsdl_image/libsdl_image.depver
     189psy npl # svn commit -m 'libsdl_image,nodig voor openmsx' mediabox/libsdl_image/
     190Adding         mediabox/libsdl_image
     191Adding  (bin)  mediabox/libsdl_image/SDL_image-1.2.6.tar.gz
     192Adding         mediabox/libsdl_image/libsdl_image.SlackBuild
     193Adding         mediabox/libsdl_image/libsdl_image.arch
     194Adding         mediabox/libsdl_image/libsdl_image.depver
     195Adding         mediabox/libsdl_image/libsdl_image.md5
     196Adding  (bin)  mediabox/libsdl_image/libsdl_image.pkg
     197Adding         mediabox/libsdl_image/libsdl_image.version
     198Adding         mediabox/libsdl_image/libsdl_image_dev.arch
     199Adding  (bin)  mediabox/libsdl_image/libsdl_image_dev.pkg
     200Adding         mediabox/libsdl_image/libsdl_image_dev.version
     201Transmitting file data ..........
     202Committed revision 3431.
     203}}}
     204
     205Zo, nu kunnen we weer verder met openmsx.
     206En het mooiste is: ons biertje is nog niet eens op!