Bonjour suite à un problème avec pSX qui refuse de démarrer je suis par hasard tombé sur une doc ubuntu parlant de pcsx-df.
Moi qui croyais que le projet pcsx avait été abandonné depuis 2003, je ne m'étais jamais vraiment intéressé à cet émulateur.
Maintenant j'essaye donc de le compiler mais comme toujours ça doit être un make pour ubuntu ou debian, je me retrouve donc avec des occurrences qui n'aboutissent à rien ...
Et comme je n'ai toujours pas compris comment résoudre facilement ce genre de problèmes j'en appelle à votre aide :-?

Tout d'abord voici le fichier source : http://downloads.sourceforge.net/pcsx-df/pcsx-df-1.9.tar.gz
Et voici ce que j'obtiens après un second make :
Making all in data
make[1]: entrant dans le répertoire « /home/quentin/Bureau/pcsx-df-1.9/data »
make[1]: Rien à faire pour « all ».
make[1]: quittant le répertoire « /home/quentin/Bureau/pcsx-df-1.9/data »
Making all in doc
make[1]: entrant dans le répertoire « /home/quentin/Bureau/pcsx-df-1.9/doc »
make[1]: Rien à faire pour « all ».
make[1]: quittant le répertoire « /home/quentin/Bureau/pcsx-df-1.9/doc »
Making all in po
make[1]: entrant dans le répertoire « /home/quentin/Bureau/pcsx-df-1.9/po »
make[1]: Rien à faire pour « all ».
make[1]: quittant le répertoire « /home/quentin/Bureau/pcsx-df-1.9/po »
Making all in libpcsxcore
make[1]: entrant dans le répertoire « /home/quentin/Bureau/pcsx-df-1.9/libpcsxcore »
make[1]: Rien à faire pour « all ».
make[1]: quittant le répertoire « /home/quentin/Bureau/pcsx-df-1.9/libpcsxcore »
Making all in gui
make[1]: entrant dans le répertoire « /home/quentin/Bureau/pcsx-df-1.9/gui »
/bin/sh ../libtool --tag=CC --mode=link gcc  -g -O2   -o pcsx  LnxMain.o Plugin.o Config.o Gtk2Gui.o hdebug.o -lgtk-x11-2.0 -lgdk-x11-2.0 -latk-1.0 -lgio-2.0 -lpangoft2-1.0 -lgdk_pixbuf-2.0 -lpangocairo-1.0 -lcairo -lpango-1.0 -lfreetype -lfontconfig -lgobject-2.0 -lgmodule-2.0 -lglib-2.0   -lglade-2.0 -lgtk-x11-2.0 -lxml2 -lgdk-x11-2.0 -latk-1.0 -lgio-2.0 -lpangoft2-1.0 -lgdk_pixbuf-2.0 -lpangocairo-1.0 -lcairo -lpango-1.0 -lfreetype -lfontconfig -lgobject-2.0 -lgmodule-2.0 -lglib-2.0   ../libpcsxcore/libpcsxcore.la 
gcc -g -O2 -o .libs/pcsx LnxMain.o Plugin.o Config.o Gtk2Gui.o hdebug.o  -lglade-2.0 -lgtk-x11-2.0 -lxml2 -lgdk-x11-2.0 -latk-1.0 -lgio-2.0 -lpangoft2-1.0 -lgdk_pixbuf-2.0 -lpangocairo-1.0 -lcairo -lpango-1.0 -lfreetype -lfontconfig -lgobject-2.0 -lgmodule-2.0 -lglib-2.0 ../libpcsxcore/.libs/libpcsxcore.so  -Wl,--rpath -Wl,/usr/local/lib
hdebug.o: In function `hdb_start':
/home/quentin/Bureau/pcsx-df-1.9/gui/hdebug.c:383: undefined reference to `pthread_create'
collect2: ld returned 1 exit status
make[1]: *** [pcsx] Erreur 1
make[1]: quittant le répertoire « /home/quentin/Bureau/pcsx-df-1.9/gui »
make: *** [all-recursive] Erreur 1
J'ai fait quelques recherches sur les erreurs de compilation avec pthread_create mais je n'ai rien compris aux résultats ...
Sinon est-ce que c'est problématique d'effectuer le make en plusieurs fois cad
1) make qui ne finit pas à cause d'un problème
2) résolution du problème
3 make qui se déroule sans problèmes

Merci d'avance pour votre aide et s'il vous manque des éléments pour résoudre mon problème je serais ravi de les fournir 🙂
Salut.

Il te manqua apparemment l'accès à la bibliothèque des threads.
Dans ton Makefile, essaye de rajouter à la variable LDFLAGS= la bibliothèque pthreads...

++
Excuse moi eddy mais je ne comprends pas très bien ce qu'il faut que je fasse ...
Il faut que je mette
LDFLAGS = /usr/lib/libpthread.so
???
[root@portable-fedora pcsx-df-1.9]# find / -name *pthread*
/usr/include/pthread.h
/usr/include/bits/pthreadtypes.h
/usr/bin/wine-pthread
/usr/lib/libgpgme++-pthread.so.2.0.2
/usr/lib/libgpgme++-pthread.so.2
/usr/lib/perl5/5.10.0/i386-linux-thread-multi/bits/pthreadtypes.ph
/usr/lib/libpthread_nonshared.a
/usr/lib/libpthread.a
/usr/lib/libpthread.so
/usr/lib/pkgconfig/pthread-stubs.pc
/usr/lib/libgpgme-pthread.so.11.6.5
/usr/lib/libgpgme-pthread.so.11
/home/quentin/compilation/client/ffmpeg/libavcodec/.svn/text-base/pthread.c.svn-base
/home/quentin/compilation/client/ffmpeg/libavcodec/.svn/prop-base/pthread.c.svn-base
/home/quentin/compilation/client/ffmpeg/libavcodec/pthread.c
/windows/C/WINDOWS/system32/pthreadVC.dll
/lib/libpthread.so.0
/lib/libpthread-2.9.so
/lib/i686/nosegneg/libpthread.so.0
/lib/i686/nosegneg/libpthread-2.9.so
Il y a des pthread de partout
Lequel faut-il utiliser ?
Je ne comprend vraiment pas ce qu'il faut que je fasse :-?
Merci pour ton aide
Dans tes sources, dans le fichier gui/Makefile.am repère la ligne 19 et ajoutes-y "-lpthread" :
pcsx_LDADD = \
    $(GTK2_LIBS) $(GLADE2_LIBS) ../libpcsxcore/libpcsxcore.la -lpthread
Lance alors autoreconf, puis ./configure avec tes options éventuelles, et make...
Merci cela résout le problème
Malheureusement c'est bien trop beau, et de nombreuses erreurs sont encore apparues (je viens d'installer les paquets mentionnés par ses erreurs et la compilation se déroule mieux)
Déjà il y en a 2 que j'avais ignoré mais dont je vais quand même parler

1)
[quentin@portable-fedora pcsx-df-1.9]$ autoreconf
autoreconf: configure.ac: AM_GNU_GETTEXT is used, but not AM_GNU_GETTEXT_VERSION
plugins/dfiso/Makefile.am:22: compiling `conf.c' with per-target flags requires `AM_PROG_CC_C_O' in `configure.ac'
Je ne vois pas vraiment ce que ça veux dire ...

2)
[quentin@portable-fedora pcsx-df-1.9]$ ./configure
checking build system type... i686-pc-linux-gnu
checking host system type... i686-pc-linux-gnu
checking target system type... i686-pc-linux-gnu
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... /bin/mkdir -p
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking whether to enable maintainer-specific portions of Makefiles... no
checking for gcc... gcc
checking for C compiler default output file name... a.out
checking whether the C compiler works... yes
checking whether we are cross compiling... no
checking for suffix of executables... 
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking for style of include used by make... GNU
checking dependency style of gcc... gcc3
checking for ranlib... ranlib
checking for a sed that does not truncate output... /bin/sed
checking for grep that handles long lines and -e... /bin/grep
checking for egrep... /bin/grep -E
checking for ld used by gcc... /usr/bin/ld
checking if the linker (/usr/bin/ld) is GNU ld... yes
checking for /usr/bin/ld option to reload object files... -r
checking for BSD-compatible nm... /usr/bin/nm -B
checking whether ln -s works... yes
checking how to recognize dependent libraries... pass_all
checking how to run the C preprocessor... gcc -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking dlfcn.h usability... yes
checking dlfcn.h presence... yes
checking for dlfcn.h... yes
checking for g++... g++
checking whether we are using the GNU C++ compiler... yes
checking whether g++ accepts -g... yes
checking dependency style of g++... gcc3
checking how to run the C++ preprocessor... g++ -E
checking for g77... no
checking for xlf... no
checking for f77... no
checking for frt... no
checking for pgf77... no
checking for cf77... no
checking for fort77... no
checking for fl32... no
checking for af77... no
checking for xlf90... no
checking for f90... no
checking for pgf90... no
checking for pghpf... no
checking for epcf90... no
checking for gfortran... gfortran
checking whether we are using the GNU Fortran 77 compiler... yes
checking whether gfortran accepts -g... yes
checking the maximum length of command line arguments... 1966080
checking command to parse /usr/bin/nm -B output from gcc object... ok
checking for objdir... .libs
checking for ar... ar
checking for ranlib... (cached) ranlib
checking for strip... strip
checking if gcc supports -fno-rtti -fno-exceptions... no
checking for gcc option to produce PIC... -fPIC
checking if gcc PIC flag -fPIC works... yes
checking if gcc static flag -static works... yes
checking if gcc supports -c -o file.o... yes
checking whether the gcc linker (/usr/bin/ld) supports shared libraries... yes
checking whether -lc should be explicitly linked in... no
checking dynamic linker characteristics... GNU/Linux ld.so
checking how to hardcode library paths into programs... immediate
checking whether stripping libraries is possible... yes
checking if libtool supports shared libraries... yes
checking whether to build shared libraries... yes
checking whether to build static libraries... yes
configure: creating libtool
appending configuration tag "CXX" to libtool
checking for ld used by g++... /usr/bin/ld
checking if the linker (/usr/bin/ld) is GNU ld... yes
checking whether the g++ linker (/usr/bin/ld) supports shared libraries... yes
checking for g++ option to produce PIC... -fPIC
checking if g++ PIC flag -fPIC works... yes
checking if g++ static flag -static works... yes
checking if g++ supports -c -o file.o... yes
checking whether the g++ linker (/usr/bin/ld) supports shared libraries... yes
checking dynamic linker characteristics... GNU/Linux ld.so
(cached) (cached) checking how to hardcode library paths into programs... immediate
appending configuration tag "F77" to libtool
checking if libtool supports shared libraries... yes
checking whether to build shared libraries... yes
checking whether to build static libraries... yes
checking for gfortran option to produce PIC... -fPIC
checking if gfortran PIC flag -fPIC works... yes
checking if gfortran static flag -static works... yes
checking if gfortran supports -c -o file.o... yes
checking whether the gfortran linker (/usr/bin/ld) supports shared libraries... yes
checking dynamic linker characteristics... GNU/Linux ld.so
(cached) (cached) checking how to hardcode library paths into programs... immediate
checking for a BSD-compatible install... /usr/bin/install -c
checking for ANSI C header files... (cached) yes
checking dependency style of gcc... gcc3
checking whether NLS is requested... yes
checking for msgfmt... /usr/bin/msgfmt
checking for gmsgfmt... /usr/bin/msgfmt
checking for xgettext... /usr/bin/xgettext
checking for msgmerge... /usr/bin/msgmerge
checking for ld used by GCC... /usr/bin/ld
checking if the linker (/usr/bin/ld) is GNU ld... yes
checking for shared library run path origin... done
checking for CFPreferencesCopyAppValue... no
checking for CFLocaleCopyCurrent... no
checking for GNU gettext in libc... yes
checking whether to use NLS... yes
checking where the gettext function comes from... libc
checking for pkg-config... /usr/bin/pkg-config
checking pkg-config is at least version 0.9.0... yes
checking for GLIB2... yes
checking for GTK2... yes
checking for GLADE2... yes
checking for BURN... yes
checking for snd_pcm_open in -lasound... yes
checking alsa/asoundlib.h usability... yes
checking alsa/asoundlib.h presence... yes
checking for alsa/asoundlib.h... yes
checking zlib.h usability... yes
checking zlib.h presence... yes
checking for zlib.h... yes
checking bzlib.h usability... yes
checking bzlib.h presence... yes
checking for bzlib.h... yes
checking X11/extensions/Xv.h usability... yes
checking X11/extensions/Xv.h presence... yes
checking for X11/extensions/Xv.h... yes
checking for nasm... /usr/bin/nasm
Dynamic Recompiler selected: x86
checking whether byte ordering is bigendian... no
configure: creating ./config.status
config.status: creating Makefile
config.status: creating data/Makefile
config.status: creating doc/Makefile
config.status: creating libpcsxcore/Makefile
config.status: creating gui/Makefile
config.status: creating plugins/dfinput/Makefile
config.status: creating plugins/dfsound/Makefile
config.status: creating plugins/dfxvideo/Makefile
config.status: creating plugins/dfcdrom/Makefile
config.status: creating plugins/dfiso/Makefile
config.status: creating plugins/dfOpenGL/Makefile
config.status: creating pixmaps/Makefile
config.status: creating po/Makefile.in
config.status: WARNING:  'po/Makefile.in.in' seems to ignore the --datarootdir setting
config.status: creating include/config.h
config.status: include/config.h is unchanged
config.status: executing depfiles commands
config.status: executing po-directories commands
config.status: creating po/POTFILES
config.status: creating po/Makefile
Un gros WARNING 7 lignes avant la fin, cela doit être gênant pour la compilation non ?

Sinon le make vient de se terminer sans erreurs.
Je vais tenter de faire un package checkinstall mais vu les bugs que l'on rencontre avec cette méthode, je pense que je vais essayer celle qui est recommandée par la doc.
Merci encore pour votre aide
Les warnings sont bénins... Les outils de compilation de ton programme utilisent une vieille version des autotools... On peut rendre ça parfait, mais j'ai la flemme d'essayer, et le mini PC que j'utilise ne daigne pas jouer les machines de dév... Mais ça ne doit pas influer sur la compilation proprement dite des binaires.... À exécuter et tester.
Oki si ça marche "normalement" ça me va déjà super bien, ne te dérange pas plus :roll:
J'ai fait le make install, le programme s'est installé sans aucun problème, et il semble fonctionner correctement (en tout cas aucun problème au niveau des confs).
Je verrais si c'est bel et bien le cas à l'usage ...
6 mois plus tard
Bonjour, je tente moi-même la compilation mais malheureusement je ne sais pas comment installer pthreads sur Fedora 11...
Impossible à trouver sur YUM, rien à faire.

Mais comment avez-vous fait ?
Si tu as installé les outils de développement, le paquetage glibc-devel devrait être installé aussi du coup (c'est ce paquetage qui contient pthread). À installer au besoin, donc...