Building SheepShaver x86 Linux

About SheepShaver, a PPC Mac emulator for Windows, MacOS X, and Linux that can run System 7.5.3 to MacOS 9.0.4.

Moderators: Cat_7, Ronald P. Regensburg, ClockWise

User avatar
Cat_7
Expert User
Posts: 6145
Joined: Fri Feb 13, 2004 8:59 am
Location: Sittard, The Netherlands

Compiling form cvs

Post by Cat_7 »

Hello Shadowfox

My guess would be you don't have the X11 development packages installed.

Cat_7
Compile Question

Post by Compile Question »

Well, I did get the files downloaded and now I'm trying to compile them. I'm doing this on a AMD 2600 with MDK 10.0 Beta 2. I get the following error message

checking for XF86VidModeQueryExtension in -lXxf86vm... yes
./configure: line 3090: syntax error near unexpected token `1.2.0,'
./configure: line 3090: ` AM_PATH_GTK(1.2.0, '

Anyone know what that means? Is it saying that I'm missing GTK+? Thanks in advance.
Diffused Mind
Student Driver
Posts: 18
Joined: Sat Feb 07, 2004 8:41 pm
Contact:

Post by Diffused Mind »

Try installing *all* of the development packages for your distribution. If you cant do that, make sure all the GTK+ 1 and 2 packages are installed.
Mac Emu
Forum All-Star
Posts: 1208
Joined: Mon May 20, 2002 11:50 am
Location: Ouraion

Post by Mac Emu »

I find Google a must for using and setting up Linux. You can spend hours\days trying to pinpoint a problem (if you don't give up looking).

Make sure Automake is installed as well. I really need a modern book on Linux programming to make sence of everything.

My wish list:

Sams Teach Yourself C for Linux Programming in 21 Days by Erik de Castro Lopo

Sams Teach Yourself Linux Programming in 24 Hours by Warren Gay

Beginning Linux Programming -- by Richard Stones

Linux Programming by Example by Kurt Wall
Guest

Post by Guest »

Diffused Mind wrote:Try installing *all* of the development packages for your distribution. If you cant do that, make sure all the GTK+ 1 and 2 packages are installed.
hmmm...I doubt that you can install *all* the development packages, even if I had unlimited disk space, this will not work without conflicts. I have installed GTK+ 1 and 2 packages along with automake and even after making a clean install of MDK 9.2 I still have the very same problems as I described for MDK 9.1 before.

Can someone please elaborate what particular packages are needed in order to sucessfully compile this project?

AFAIK, Gwenole developed this under Mandrake, and I cannot believe that you have to install about 2GB of Software to be able to compile it.

I actually spent several day on Google to tackle the problem, but the longer I searched and considering that I can compile other projects, it seems to be related to this particular project.
User avatar
ClockWise
Site Admin
Posts: 4397
Joined: Mon May 20, 2002 4:37 am
Location: Uiwang

Post by ClockWise »

Dig the "view" count on this thread. I think that this "SheepShaver" might be getting some usage. That's great!
Guest

Post by Guest »

checking for XF86VidModeQueryExtension in -lXxf86vm... yes
./configure: line 3090: syntax error near unexpected token `1.2.0,'
./configure: line 3090: ` AM_PATH_GTK(1.2.0, '

Anyone know what that means? Is it saying that I'm missing GTK+? Thanks in advance.
This means that the configure script could not -previously- find gtk+ 1.2, regardless of if it is installed or not. In this case AM_PATH_... is a macro that should have been replaced with a path to gtk+. Here are some pointers that may help out (btw, there is no direct answer to this, so welcome to compiling code. This is not a Linux thing, it is a compiling thing):
1) If you found out -after- getting this message that you did not have gtk+ 1.2 installed and then subsequently installed it, you would need to delete config.cache and rerun configure again. To state what is probably obvious, config.cache are cached results of where library whatnot etc is found to be installed or whatever the case may be.
2) A library is generally split between the libraries (lib) and header files (include(s)). eg. /usr/lib /usr/include etc. Forget about header files for now. There are a variety of locations that libraries could possibly be installed. The kind of 'standard' locations could be /lib /usr/lib /usr/local/lib and so on, possibly anywhere in some cases. Generally these libraries are known as shared libraries (as opposed to static). Anyway, for these libraries to be automagically recognised and found by the system they need to be listed in /etc/ld.so.conf After adding a library an entry would be added to ld.so.config and ldconfig would be run to update/recreate a file called /etc/ld.so.cache. This is a very basic explanation and this process would usually be taken care of for you. This is one of the things that set the different distros apart. So if you know that gtk+ is installed in eg. /usr/lib check that there is a line in /etc/ld.so.config with /usr/lib In this example there should be as it is a common location. This is where problems can occur when libraries are installed in non-standard locations and so not picked up. Another way of pointing to libraries is using LD_LIBRARY_PATH but IMO that is more of a temporary thing.
3) Open up the configure script in an editor and search for what it is failing on and try and understand what the script is trying to do. If nothing makes sense now is a good time to start learning more about shell scripting. Bash would be a good start. Bash really rocks. It can only help you in the future ;)
4) The configure script actually generates a Makefile. That is its purpose. Makefile files are required to compile code. Most code has a configure script. Open up the Makefile and have a look at whats going on in there. Here is a way you could bodge things a little and make it point to where your libraries are. Here is an extract from my Makefile for SheepShaver:

Code: Select all

CFLAGS = -g -O2  -I/usr/X11R6/include -I/usr/include/gtk-1.2 -I/usr/include/glib-1.2 -I/usr/lib/glib/include -I/usr/X11R6/include
CXXFLAGS = -g -O2  -I/usr/X11R6/include -I/usr/include/gtk-1.2 -I/usr/include/glib-1.2 -I/usr/lib/glib/include -I/usr/X11R6/include
CPPFLAGS =  -I../kpx_cpu/include -I../kpx_cpu/src -DUSE_JIT -I../include -I.
DEFS = -DHAVE_CONFIG_H -D_REENTRANT -DDATADIR=\"$(datadir)/$(APP)\"
LDFLAGS =
LIBS = -lpthread   -lSM -lICE  -L/usr/X11R6/lib -lX11 -lXext  -lXxf86dga -lXxf86vm -L/usr/lib -L/usr/X11R6/lib -lgtk -lgdk -rdynamic -lgmodule
 -lglib -ldl -lXi -lXext -lX11 -lm -L/usr/lib -lesd -laudiofile -lm -lasound
There are two things to really look at here. -I<path> points to header files. -L<path> points to a library. So if necessary add where you think they should point to. As an aside, if you ever need to compile code that does not have a configure script that is pretty much what you need to change if necessary.

Thats it. Hope it helps.
ataxy
Master Emulator
Posts: 374
Joined: Sun Jan 25, 2004 3:49 pm
Location: Canada
Contact:

Post by ataxy »

Mac Emu wrote:I find Google a must for using and setting up Linux. You can spend hours\days trying to pinpoint a problem (if you don't give up looking).

Make sure Automake is installed as well. I really need a modern book on Linux programming to make sence of everything.

My wish list:

Sams Teach Yourself C for Linux Programming in 21 Days by Erik de Castro Lopo

Sams Teach Yourself Linux Programming in 24 Hours by Warren Gay

Beginning Linux Programming -- by Richard Stones

Linux Programming by Example by Kurt Wall
you bet id like a linux for more then the dumb one
Guest

Post by Guest »

you bet id like a linux for more then the dumb one
Seems like someone needs to get out more and converse in English with real people before all is lost 8O
ShadowFox
Tinkerer
Posts: 70
Joined: Thu Feb 05, 2004 4:41 am
Location: Connecticut

Re: Compiling form cvs

Post by ShadowFox »

Cat_7 wrote:Hello Shadowfox

My guess would be you don't have the X11 development packages installed.

Cat_7
Would anyone know offhand exactly which packages/libraries/whatnot are required to build? I'm sort of poking through gentoo's portage system looking for anything that looks important, but a google search for "X11 development packages" didn't turn up much useful information. Thanks!
Guest

Post by Guest »

Would anyone know offhand exactly which packages/libraries/whatnot are required to build? I'm sort of poking through gentoo's portage system looking for anything that looks important, but a google search for "X11 development packages" didn't turn up much useful information. Thanks!
It really all depends on how your system is configured, what is installed, what is linked with what etc.
I think you mean 'what is its (SheepShavers) immediate dependencies'. As there is a configure script you can do a ./configure --help to get an idea, which will tell you gtk+, esd, xfree86 dga, along with the xfree86 dev libraries. It wont tell you the versions it requires though which can lead you into another situation which I described ways to get around above. Maybe someone needs to prompt Gwenole to provide the information?
Still, the approach I took was to look at it from another angle: Basilisk is, if you will, the older brother of SheepShaver and is kind of similar in it what it requires to build. So get the BasiliskII source and build that. BasiliskII has been around for alot longer and is probably more documented in telling you what it needs.
Anwyay, as you (and I) are on Gentoo we are kind of spoiled as we can do a:

Code: Select all

emerge -pv basiliskII
which will tell you what will be merged to satisfy building and installing basiliskII. Of course, doing a

Code: Select all

emerge -v basiliskII
will install basiliskII and leave you in a situation where you have everything you need to build SheepShaver (as I recall ;) ). By the way, emerge search basiliskII gives the url of the home of Gwenole which is kind of a hint.

Hope it helps.
Guest

Post by Guest »

I forget to mention that the version of gtk is most definitely gtk+ 1.2.x and that you could do a

Code: Select all

emerge -pev basiliskII
to find out absolutely all of its dependencies for your system.
Bassie
Space Cadet
Posts: 9
Joined: Mon Jan 26, 2004 11:22 am

error Scott Holder

Post by Bassie »

Hello me too, I'm having the same problem as Scott holder here in first page.
Haven't seen any remarks on this prob yet though.
Could please anyone be of any help.
The ??? stand for another number think it was 452 or 425 but rest of message was the same, I had to urgently log into xp again.
Thx in advance,

Bassie.

g++ -o SheepShaver obj/main_unix.o obj/prefs.o obj/prefs_items.o obj/prefs_unix.o obj/sys_unix.o obj/rom_patches.o obj/rsrc_patches.o obj/emul_op.o obj/name_registry.o obj/macos_util.o obj/timer.o obj/timer_unix.o obj/xpram.o obj/xpram_unix.o obj/adb.o obj/clip_unix.o obj/sony.o obj/disk.o obj/cdrom.o obj/scsi.o obj/scsi_linux.o obj/video.o obj/video_blit.o obj/video_x.o obj/audio.o obj/audio_oss_esd.o obj/ether.o obj/ether_linux.o obj/serial.o obj/serial_unix.o obj/extfs.o obj/extfs_unix.o obj/about_window_unix.o obj/user_strings.o obj/user_strings_unix.o obj/vm_alloc.o obj/sigsegv.o obj/sshpty.o obj/strlcpy.o obj/sheepshaver_glue.o obj/ppc-cpu.o obj/ppc-decode.o obj/ppc-execute.o -lpthread -lSM -lICE -L/usr/X11R6/lib -lX11 -lXext -lXxf86dga -lXxf86vm
obj/main_unix.o(.text+0x2bb): In function `main':
/home/scott/SheepShaver/src/Unix/main_unix.cpp:432: undefined reference to `PrefsEditor()'
collect2: ld returned 1 exit status
make: *** [SheepShaver] Error 1
Bassie
Space Cadet
Posts: 9
Joined: Mon Jan 26, 2004 11:22 am

Post by Bassie »

lXxf86dga -lXxf86vm
obj/main_unix.o(.text+0x2bb): In function `main':
/home/scott/SheepShaver/src/Unix/main_unix.cpp:???: undefined reference to `PrefsEditor()'
Sorry forgot ???
Trancesphere
Space Cadet
Posts: 3
Joined: Fri Jan 23, 2004 9:47 pm

Post by Trancesphere »

./configure: line 3090: syntax error near unexpected token `1.2.0,'
./configure: line 3090: ` AM_PATH_GTK(1.2.0, '
If you are getting this error, make sure you have gnome-libs installed.
Guest

Post by Guest »

If you are getting this error, make sure you have gnome-libs installed.
NO. If you are getting this error make sure you have gtk+ 1.2 installed. See above.

gtk+ 1.2 is not part of gnome-libs.

- I wish people would stop posting uninformed and incorrect advice. No wonder newbies get so confused 8O
Guest

Post by Guest »

Anonymous wrote:
If you are getting this error, make sure you have gnome-libs installed.
NO. If you are getting this error make sure you have gtk+ 1.2 installed. See above.

gtk+ 1.2 is not part of gnome-libs.

- I wish people would stop posting uninformed and incorrect advice. No wonder newbies get so confused 8O
When I installed gtk+ 1.2 i still got the errors, but after installing gnome-libs the errors went away.
Guest

Post by Guest »

When I installed gtk+ 1.2 i still got the errors, but after installing gnome-libs the errors went away.
This means that you installed gtk+ 1.2 through whatever package management your distro uses as a dependency of gnome-libs. So I think *if* your gtk+ *was* installed that it was installed incorrectly. Whatever.
checking for XF86VidModeQueryExtension in -lXxf86vm... yes
./configure: line 3090: syntax error near unexpected token `1.2.0,'
./configure: line 3090: ` AM_PATH_GTK(1.2.0, '
Anyone know what that means? Is it saying that I'm missing GTK+? Thanks in advance.
This means that the configure script could not -previously- find gtk+ 1.2, regardless of if it is installed or not. In this case AM_PATH_... is a macro that should have been replaced with a path to gtk+.
Here are sources:

http://ftp.gnome.org/pub/GNOME/desktop/ ... 1.4.tar.gz

http://ftp.gnome.org/pub/GNOME/desktop/ ... .10.tar.gz

If you install gnome-libs through package management it will install gtk+
ShadowFox
Tinkerer
Posts: 70
Joined: Thu Feb 05, 2004 4:41 am
Location: Connecticut

Post by ShadowFox »

Anonymous wrote:
Anwyay, as you (and I) are on Gentoo we are kind of spoiled as we can do a:

Code: Select all

emerge -pv basiliskII
which will tell you what will be merged to satisfy building and installing basiliskII. Of course, doing a

Code: Select all

emerge -v basiliskII
will install basiliskII and leave you in a situation where you have everything you need to build SheepShaver (as I recall ;) ). By the way, emerge search basiliskII gives the url of the home of Gwenole which is kind of a hint.

Hope it helps.
Mind if I ask what kernel version you're running? I'm on 2.6.2, not sure if that would make a difference, but I emerged everything basilisk depends on, and I'm still getting the same error compiling SheepShaver.

Maybe I'll pop 2.4.22 on and see what happens there.
Guest

Post by Guest »

Mind if I ask what kernel version you're running? I'm on 2.6.2, not sure if that would make a difference, but I emerged everything basilisk depends on, and I'm still getting the same error compiling SheepShaver.
I am using 2.4.22.
Enhancements aside, the version of the kernel that you are running will not make any difference to building SheepShaver.

I assume that you have done a make clean and removed config.cache?

I think I would do some sanity checks:
Check out the sources again into another directory and start again.
# gtk-config --version # this is part of gtk+ 1.2.
Check the integrity of gtk+ with regards to portage. There are different ways of doing this. Here is the way I do it. I have package epm merged. In case you dont know epm is kind of a gentoo rpm equivalent. qpkg (part of gentoolkit) does similar stuff.

This will show packages with all names that start with gtk+
# epm -q gtk+
You possibly have gtk+ 2.2.x installed so you may see two lines
One of them should read something like gtk+1.2.10-r10
To specifically verify this package as above.
# epm -V gtk+1.2.10-r10 # verify package.
A nice feature of epm is that the following will list the files in a package much like rpm
# epm -ql gtk+... # it treats the first few chars as a wildcard btw, showing all gtk+ packages
maybe also useful to know. To find out what package a file belongs to
# epm -qf /path/to/file
Dyne

Compile Error

Post by Dyne »

I tried compiling SheepShaver under Slackware 9.1 but I got this error when running Make



g++ -I../kpx_cpu/include -I../kpx_cpu/src -DUSE_JIT -I../include -I. -DHAVE_CONFIG_H -D_REENTRANT -DDATADIR=\"/usr/local/share/SheepShaver\" -g -O2 -I/usr/include/gtk-1.2 -I/usr/include/glib-1.2 -I/usr/lib/glib/include -I/usr/X11R6/include -fomit-frame-pointer -mpreferred-stack-boundary=2 -falign-functions=0 -mmmx -msse -finline-limit=10000 -fno-reorder-blocks -fno-optimize-sibling-calls -c ../kpx_cpu/src/cpu/ppc/ppc-dyngen-ops.cpp -o obj/ppc-dyngen-ops.o
In file included from ../kpx_cpu/src/cpu/ppc/ppc-dyngen-ops.cpp:1493:
/usr/lib/gcc-lib/i486-slackware-linux/3.2.3/include/xmmintrin.h: In function
`void _mm_stream_pi(vector int*, vector int)':
/usr/lib/gcc-lib/i486-slackware-linux/3.2.3/include/xmmintrin.h:1036: cannot
convert `vector int*' to `long long unsigned int*' for argument `1' to `void
__builtin_ia32_movntq(long long unsigned int*, long long unsigned int)'
make: *** [obj/ppc-dyngen-ops.o] Error
MacNostalgia
Student Driver
Posts: 10
Joined: Wed Jan 21, 2004 10:26 pm

Post by MacNostalgia »

Anonymous wrote: When I installed gtk+ 1.2 i still got the errors, but after installing gnome-libs the errors went away.
Thanks for the tip, I also had gtk installed and got the error. After installing lignome and it's dependencies (gtk was NOT one of them) everything went fine.

And now you wizards, go ahead and tell me off for being a confused newbie... :(
Guest

Post by Guest »

It is good that it is working for you.
I also had gtk installed and got the error. After installing lignome and it's dependencies (gtk was NOT one of them)
It is not clear what error you are referring to. If it is this error:
checking for XF86VidModeQueryExtension in -lXxf86vm... yes
./configure: line 3090: syntax error near unexpected token `1.2.0,'
./configure: line 3090: ` AM_PATH_GTK(1.2.0, '
This means that the configure script could not -previously- find gtk+ 1.2, regardless of if it is installed or not. In this case AM_PATH_... is a macro that should have been replaced with a path to gtk+.
If you had gtk installed it was any or all of the following: not gtk+ 1.2, not installed correctly, gtk2.
gtk+ 1.2 is a dependency of libgnome. If you install libgnome through package management and gtk+ 1.2 is not installed, it will install it.
User avatar
javier_garza4
Tinkerer
Posts: 68
Joined: Thu Nov 28, 2002 8:59 pm
Location: El Paso

Post by javier_garza4 »

too bad installers dont really exist
Stephen Coates
Expert User
Posts: 868
Joined: Sat Aug 30, 2003 4:15 pm
Location: UK
Contact:

Post by Stephen Coates »

javier_garza4 wrote:too bad installers dont really exist
I know.
But you can learn alot by messing about with the compiling.

Would anyone be able to create a proper installer?
Post Reply