'making' in 64-bit Ubuntu 7.04

General area for talk about ZSNES. The best place to ask for related questions as well as troubleshooting.

Moderator: ZSNES Mods

Post Reply
NFITC1
Rookie
Posts: 36
Joined: Wed Jun 21, 2006 4:58 pm
Location: 127.0.0.1
Contact:

'making' in 64-bit Ubuntu 7.04

Post by NFITC1 »

I've been wrestling with the configure file for days now trying to get it to see the SDL I have installed. This morning I finally got it to work, but when I tried to make the executable, this happens:

Configure:

Code: Select all

user@localhost:~/zsnes_1_51/src$ ./configure
checking build system type... x86_64-unknown-linux-gnu
checking host system type... x86_64-unknown-linux-gnu
checking target system type... x86_64-unknown-linux-gnu
checking for a BSD-compatible install... /usr/bin/install -c
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 g++... g++
checking whether we are using the GNU C++ compiler... yes
checking whether g++ accepts -g... yes
checking for nasm... nasm
checking for sdl-config... /usr/local/bin/sdl-config
checking for SDL - version >= 1.2.0... yes
checking for zlib - version >= 1.2.3... yes
checking for libpng - version >= 1.2.0... yes
checking if you want the zsnes debugger... yes
checking for initscr in -lcurses... yes
checking for initscr in -lncurses... yes
checking for initscr in -lpdcurses... no
checking if you want libao support... no
checking how to run the C preprocessor... gcc -E
checking for X... libraries , headers 
checking for glGetError in -lGL... yes
checking for OpenGL... yes
checking for JMA support... yes
checking for cpu info... found
checking if you want gdb friendly executable... no
checking which cpu architecture to optimize for... athlon64
checking if you want crazy optimizations... no
checking for grep that handles long lines and -e... /bin/grep
checking for egrep... /bin/grep -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 whether sys/types.h defines makedev... yes
configure: creating ./config.status
config.status: creating Makefile
config.status: creating config.h
config.status: config.h is unchanged


ZSNES v1.51

SDL support                   Version 1.2.12
NASM support                  NASM version 0.98.38 compiled on Jun 27 2005
zlib support                  Version 1.2.3
PNG support                   Yes, version 1.2.15beta5
OpenGL support                Yes
JMA support                   Yes
ZSNES debugger                Enabled

The binary will be installed in /usr/local/bin

Configure complete, now type 'make' and pray.
Then the make file:

Code: Select all

user@localhost:~/zsnes_1_51/src$ make
tools/depbuild gcc " -pipe -I. -I/usr/local/include -I/usr/include -D__UNIXSDL__  -I/usr/local/include/SDL -D_GNU_SOURCE=1 -D_REENTRANT  -D__OPENGL__ -march=athlon64 -O3 -fomit-frame-pointer -s" nasm " -w-orphan-labels -D__UNIXSDL__ -f elf -DELF -D__OPENGL__ -O1" cfg.o endmem.o init.o initc.o input.o md.o patch.o ui.o vcache.o version.o zloader.o zmovie.o zpath.o zstate.o ztime.o ztimec.o chips/c4emu.o chips/c4proc.o chips/dsp1emu.o chips/dsp1proc.o chips/dsp2proc.o chips/dsp3emu.o chips/dsp3proc.o chips/dsp4emu.o chips/dsp4proc.o chips/fxemu2.o chips/fxemu2b.o chips/fxemu2c.o chips/fxtable.o chips/obc1emu.o chips/obc1proc.o chips/sa1proc.o chips/sa1regs.o chips/sdd1emu.o chips/seta10.o chips/sfxproc.o chips/st10proc.o chips/7110proc.o chips/seta11.o chips/st11proc.o cpu/dma.o cpu/dsp.o cpu/dspproc.o cpu/execute.o cpu/executec.o cpu/irq.o cpu/memory.o cpu/memtable.o cpu/spc700.o cpu/stable.o cpu/table.o cpu/tablec.o debugasm.o debugger.o gui/gui.o gui/guifuncs.o gui/menu.o effects/burn.o effects/smoke.o effects/water.o jma/7zlzma.o jma/crc32.o jma/iiostrm.o       jma/inbyte.o jma/jma.o jma/lzma.o      jma/lzmadec.o jma/winout.o jma/zsnesjma.o mmlib/mm.o mmlib/linux.o  video/makev16b.o video/makev16t.o video/makevid.o video/mode716.o video/mode716b.o video/mode716d.o video/mode716e.o video/mode716t.o video/mode7.o video/mode7ext.o video/mv16tms.o video/m716text.o video/newg162.o video/newgfx.o video/newgfx16.o video/newgfx2.o video/procvid.o video/procvidc.o video/sw_draw.o video/2xsaiw.o video/hq2x16.o video/hq2x32.o video/hq3x16.o video/hq3x32.o video/hq4x16.o video/hq4x32.o video/ntsc.o video/copyvwin.o linux/audio.o linux/battery.o linux/sdlintrf.o linux/sdllink.o linux/gl_draw.o linux/sw_draw.o linux/safelib.o zip/unzip.o zip/zpng.o > makefile.dep
gcc  -pipe -I. -I/usr/local/include -I/usr/include -D__UNIXSDL__  -I/usr/local/include/SDL -D_GNU_SOURCE=1 -D_REENTRANT  -D__OPENGL__ -march=athlon64 -O3 -fomit-frame-pointer -s -o version.o -c version.c
g++ -o zsnes cfg.o endmem.o init.o initc.o input.o md.o patch.o ui.o vcache.o version.o zloader.o zmovie.o zpath.o zstate.o ztime.o ztimec.o chips/c4emu.o chips/c4proc.o chips/dsp1emu.o chips/dsp1proc.o chips/dsp2proc.o chips/dsp3emu.o chips/dsp3proc.o chips/dsp4emu.o chips/dsp4proc.o chips/fxemu2.o chips/fxemu2b.o chips/fxemu2c.o chips/fxtable.o chips/obc1emu.o chips/obc1proc.o chips/sa1proc.o chips/sa1regs.o chips/sdd1emu.o chips/seta10.o chips/sfxproc.o chips/st10proc.o chips/7110proc.o chips/seta11.o chips/st11proc.o cpu/dma.o cpu/dsp.o cpu/dspproc.o cpu/execute.o cpu/executec.o cpu/irq.o cpu/memory.o cpu/memtable.o cpu/spc700.o cpu/stable.o cpu/table.o cpu/tablec.o debugasm.o debugger.o gui/gui.o gui/guifuncs.o gui/menu.o effects/burn.o effects/smoke.o effects/water.o jma/7zlzma.o jma/crc32.o jma/iiostrm.o  jma/inbyte.o jma/jma.o jma/lzma.o       jma/lzmadec.o jma/winout.o jma/zsnesjma.o mmlib/mm.o mmlib/linux.o  video/makev16b.o video/makev16t.o video/makevid.o video/mode716.o video/mode716b.o video/mode716d.o video/mode716e.o video/mode716t.o video/mode7.o video/mode7ext.o video/mv16tms.o video/m716text.o video/newg162.o video/newgfx.o video/newgfx16.o video/newgfx2.o video/procvid.o video/procvidc.o video/sw_draw.o video/2xsaiw.o video/hq2x16.o video/hq2x32.o video/hq3x16.o video/hq3x32.o video/hq4x16.o video/hq4x32.o video/ntsc.o video/copyvwin.o linux/audio.o linux/battery.o linux/sdlintrf.o linux/sdllink.o linux/gl_draw.o linux/sw_draw.o linux/safelib.o zip/unzip.o zip/zpng.o  -pipe -I. -I/usr/local/include -I/usr/include -D__UNIXSDL__  -I/usr/local/include/SDL -D_GNU_SOURCE=1 -D_REENTRANT  -D__OPENGL__ -march=athlon64 -O3 -fomit-frame-pointer -s -fno-rtti  -L/usr/local/lib -L/usr/lib  -lz -L/usr/local/lib -Wl,-rpath,/usr/local/lib -lSDL -lpthread  -lpng -lm -lcurses -lGL
/usr/bin/ld: skipping incompatible /usr/local/lib/libSDL.so when searching for -lSDL
/usr/bin/ld: skipping incompatible /usr/local/lib/libSDL.a when searching for -lSDL
/usr/bin/ld: warning: i386 architecture of input file `endmem.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `init.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `vcache.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `ztime.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `chips/c4proc.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `chips/dsp1proc.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `chips/dsp2proc.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `chips/dsp3proc.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `chips/dsp4proc.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `chips/fxemu2.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `chips/fxemu2b.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `chips/fxemu2c.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `chips/fxtable.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `chips/obc1proc.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `chips/sa1proc.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `chips/sa1regs.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `chips/sfxproc.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `chips/st10proc.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `chips/7110proc.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `chips/st11proc.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `cpu/dma.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `cpu/dsp.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `cpu/dspproc.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `cpu/execute.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `cpu/irq.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `cpu/memory.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `cpu/spc700.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `cpu/stable.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `cpu/table.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `cpu/tablec.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `debugasm.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `gui/gui.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `gui/menu.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `video/makev16b.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `video/makev16t.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `video/makevid.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `video/mode716.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `video/mode716b.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `video/mode716d.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `video/mode716e.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `video/mode716t.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `video/mode7.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `video/mode7ext.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `video/mv16tms.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `video/m716text.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `video/newg162.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `video/newgfx.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `video/newgfx16.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `video/newgfx2.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `video/procvid.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `video/sw_draw.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `video/2xsaiw.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `video/hq2x16.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `video/hq2x32.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `video/hq3x16.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `video/hq3x32.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `video/hq4x16.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `video/hq4x32.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `video/copyvwin.o' is incompatible with i386:x86-64 output
/usr/bin/ld: warning: i386 architecture of input file `linux/sdlintrf.o' is incompatible with i386:x86-64 output
rm -f version.o
All those architecture incompatible doesn't make me happy. Is there anything I can do about this? Should I do something during the configure process?
Deathlike2
ZSNES Developer
ZSNES Developer
Posts: 6747
Joined: Tue Dec 28, 2004 6:47 am

Post by Deathlike2 »

You need to compile for a 32-bit target.
Continuing [url=http://slickproductions.org/forum/index.php?board=13.0]FF4[/url] Research...
NFITC1
Rookie
Posts: 36
Joined: Wed Jun 21, 2006 4:58 pm
Location: 127.0.0.1
Contact:

Post by NFITC1 »

Deathlike2 wrote:You need to compile for a 32-bit target.
So I gathered, but I don't know how to do that. Is that an option I should select when I type ./configure?
NFITC1
Rookie
Posts: 36
Joined: Wed Jun 21, 2006 4:58 pm
Location: 127.0.0.1
Contact:

Post by NFITC1 »

Well, I finally got it to work. After reading other topics on this forum, I tried quite a few things before choosing to install fresh. All I did was:

Code: Select all

export CFLAGS="-m32"
export CXXFLAGS="-m32"
./configure --enable-release --disable-cpucheck force_arch=athlon64
make
Which took a LONG time, Then ran

Code: Select all

make install
as root and it installed.

This information should probably be added to the install.txt for 64-bit Linux users who, like me, don't want to run things in 32-bit emulated mode through an additional APL like WINE.
adventure_of_link
Locksmith of Hyrule
Posts: 3634
Joined: Sun Aug 08, 2004 7:49 am
Location: 255.255.255.255
Contact:

Post by adventure_of_link »

uh dude, WINE runs WINDOWS applications...
<Nach> so why don't the two of you get your own room and leave us alone with this stupidity of yours?
NSRT here.
Deathlike2
ZSNES Developer
ZSNES Developer
Posts: 6747
Joined: Tue Dec 28, 2004 6:47 am

Post by Deathlike2 »

NFITC1 wrote:This information should probably be added to the install.txt for 64-bit Linux users who, like me, don't want to run things in 32-bit emulated mode through an additional APL like WINE.
32-bit mode is not emulated.
Continuing [url=http://slickproductions.org/forum/index.php?board=13.0]FF4[/url] Research...
NFITC1
Rookie
Posts: 36
Joined: Wed Jun 21, 2006 4:58 pm
Location: 127.0.0.1
Contact:

Post by NFITC1 »

adventure_of_link wrote:uh dude, WINE runs WINDOWS applications...
Yes, dude, I know. I didn't want to run the windows version through WINE. I'm trying to avoid as much pre-processing as possible. That's what I mean.

And, Deathlike2, I'm not sure how this compiled. If g++ compiles the 32-bit code into a 64-bit executable, which I assume, it isn't emulated.
And yes, I know what WINE stands for. But when a 32-bit app is running on a 64-bit processor, some level of pre-processing occurs. Mostly on the hardware level. That's what I meant when I said emulated mode. Not the correct choice of words.
funkyass
"God"
Posts: 1128
Joined: Tue Jul 27, 2004 11:24 pm

Post by funkyass »

no, it compiles 32-bit code into a 32-bit binary, 64-bit linux can run it natively if the right libraries are installed(check for a lib32 directory).
Does [Kevin] Smith masturbate with steel wool too?

- Yes, but don’t change the subject.
NFITC1
Rookie
Posts: 36
Joined: Wed Jun 21, 2006 4:58 pm
Location: 127.0.0.1
Contact:

Post by NFITC1 »

funkyass wrote:no, it compiles 32-bit code into a 32-bit binary, 64-bit linux can run it natively if the right libraries are installed(check for a lib32 directory).
This is what I suspected. Although I wanted it to be 64-bit. :(
Either way, I don't have to run it through WINE now, which is what I really wanted anyway.
Aerdan
Winter Knight
Posts: 467
Joined: Mon Aug 16, 2004 10:16 pm
Contact:

Post by Aerdan »

Read the 'compiling from SVN' FAQ, except replace 'SVN' with '1.51' as appropriate and use 1.51's sources instead.
Post Reply