English Amiga Board

English Amiga Board (https://eab.abime.net/index.php)
-   support.OtherUAE (https://eab.abime.net/forumdisplay.php?f=54)
-   -   Compiling P-UAE on Mac OS X (https://eab.abime.net/showthread.php?t=50826)

MagerValp 15 February 2010 21:28

OK, got a little further:

http://mazzy.paradroid.net/tmp/puae-2010-02-15-m32.txt

gilgamesh 15 February 2010 21:34

Quote:

Originally Posted by GnoStiC (Post 642840)
with gtk gui, everything works fine..

Yes, spend some time getting my GTK-2.0.0 32bit stuff to work properly. (Thanks to openSUSE this involves lots of "ln -s" in /usr/lib.)

What can I say? GUI works and PUAE too. For the first time. :spin

(Btw, the "Floppy Disks" tab has an error. The lights for DF1 and DF3 are on while DF1 is empty and DF3 is disabled.)

xaind 16 February 2010 00:58

Quote:

Originally Posted by GnoStiC (Post 642795)
UPDATE:
http://www.gamzeguckiran.com/puaex_2010_02_15.tar.gz

please try this and report :)

@xaind:
if this doesn't work for you, can you please try without
Opening cfgfile '/Users/myname/Amiga/Configs/A500.uaerc'...okay.
and
ROM KEY '/Users/myname/Amiga/Roms/rom.key' 2069 bytes loaded

Ok, this version builds without any modifications! It still freezes though, even with no cfgfile.

Later on I'll try a few things and see if I can figure out where in the code it is freezing.

Quote:

PUAE 2.0.2
Build date: Feb 16 2010 10:42:19
SDLGFX: Initialized.
SDLGFX: Using SDL version 1.2.14.
SDLGFX: Display is 32 bits deep.
SDLGFX: Found screenmode: 1920x1200.
SDLGFX: Found screenmode: 1600x1200.
SDLGFX: Found screenmode: 1600x1000.
SDLGFX: Found screenmode: 1344x1008.
SDLGFX: Found screenmode: 1280x960.
SDLGFX: Found screenmode: 1344x840.
SDLGFX: Found screenmode: 1280x800.
SDLGFX: Found screenmode: 1024x768.
SDLGFX: Found screenmode: 1024x640.
SDLGFX: Found screenmode: 960x600.
SDLGFX: Found screenmode: 800x600.
SDLGFX: Found screenmode: 800x500.
SDLGFX: Found screenmode: 640x480.
Found 0 joystick(s)
Found quartz raw keyboard mapping
Using raw keymap
Opening cfgfile '/Users/myname/default.uaerc'...failed
Opening cfgfile 'default.uaerc'...failed
Testing the RDTSC instruction ... done.
Calibrating TSC frequency...TSC frequency: 2660.814000 MHz
Found quartz raw keyboard mapping
Using raw keymap
Found quartz raw keyboard mapping
Using raw keymap
Entered action_replay_load()
ROM loader..
SDLGFX: Added P96 mode: 640x480x32
SDLGFX: Added P96 mode: 640x480x8
SDLGFX: Added P96 mode: 800x600x32
SDLGFX: Added P96 mode: 800x600x8
SDLGFX: Added P96 mode: 1024x768x32
SDLGFX: Added P96 mode: 1024x768x8
SDLGFX: Added P96 mode: 1920x1200x32
SDLGFX: Added P96 mode: 1920x1200x8
SDLGFX: Added P96 mode: 1600x1200x32
SDLGFX: Added P96 mode: 1600x1200x8
SDLGFX: Added P96 mode: 1600x1000x32
SDLGFX: Added P96 mode: 1600x1000x8
SDLGFX: Added P96 mode: 1344x1008x32
SDLGFX: Added P96 mode: 1344x1008x8
SDLGFX: Added P96 mode: 1280x960x32
SDLGFX: Added P96 mode: 1280x960x8
SDLGFX: Added P96 mode: 1344x840x32
SDLGFX: Added P96 mode: 1344x840x8
SDLGFX: Added P96 mode: 1280x800x32
SDLGFX: Added P96 mode: 1280x800x8
SDLGFX: Added P96 mode: 1024x640x32
SDLGFX: Added P96 mode: 1024x640x8
SDLGFX: Added P96 mode: 960x600x32
SDLGFX: Added P96 mode: 960x600x8
SDLGFX: Added P96 mode: 800x500x32
SDLGFX: Added P96 mode: 800x500x8
No disk in drive 0.
CBuilding CPU table for configuration: 68000 prefetch 24-bit
1876 CPU functions
Building CPU, 44316 opcodes (0 1 1)
CPU=68000, FPU=0, JIT=0.
CPUID level=10, Family=6, Model=15, Mask=6, Vendor=GenuineIntel [0]
JJCSDL: sound driver found and configured at 44100 Hz, buffer is 100 ms (17640 bytes).
BEAMCON0 0000 -> 0020
PAL mode V=50Hz H=15600Hz (227x312)
chipmem cleared
C

xaind 17 February 2010 08:42

Ok, I have found where PUAE is freezing on the Mac.

It is inside the framewait function in custom.c. There is a loop in this function which looks like this:

Code:

for (;;) {
        double v = rpt_vsync () / (syncbase / 1000.0);
        if (v >= -4)
                break;
        uae_msleep (2);
}

This loop never ends in my tests because the syncbase variable is always set to zero, so v always gets set to nan and hence the break instruction is never reached.

I am trying to understand the code that sets syncbase now. It appears to have something to do with TSC frequency... whatever that is. I have noticed that the following lines appear during PUAE's startup:

Quote:

Testing the RDTSC instruction ... done.
Calibrating TSC frequency...TSC frequency: 2660.814000 MHz
.. but these lines do not appear in E-UAE's startup on the Mac (even though code for them seems to be present in E-UAE).

Could this be a build settings problem? Should this TSC stuff be getting used on the Mac?

GnoStiC 17 February 2010 12:21

<p>syncbase = number of ticks per second of the processor clock</p>
<p>TSC = time stamp counter (aka number of ticks since reset)</p>
<p>&nbsp;</p>
<p>&nbsp;</p>
<p><a href="http://www.gamzeguckiran.com/puaex_2010_02_17.tar.gz" target="_blank">http://www.gamzeguckiran.com/puaex_2010_02_17.tar.gz</a></p>
________
volcano classic review

gilgamesh 17 February 2010 12:33

Can't change GamePort2 in GTK gui.

Quote:

CPU=68000, FPU=0, JIT=0.
[...]
JIT: Building Compiler function table
JIT: Supposedly 42101 compileable opcodes!
Isn't that a contradiction?

(Sorry for being short. I'll have a closer look tomorrow.)

GnoStiC 17 February 2010 12:54

<p>1) first JIT=0 does not mean JIT is disabled.</p>
<p>2) &quot;Can't change GamePort2 in GTK gui.&quot; ? can you elaborate on that?</p>
<p>&nbsp;</p>
<p>
Quote:

Originally Posted by gilgamesh (Post 643346)
Can't change GamePort2 in GTK gui.</p>
<p>&nbsp;</p>
<p>Isn't that a contradiction?</p>
<p>&nbsp;</p>
<p>(Sorry for being short. I'll have a closer look tomorrow.)

</p>
________
cheap volcano vaporizer

gilgamesh 17 February 2010 13:23

Quote:

Originally Posted by GnoStiC (Post 643350)
2) "Can't change GamePort2 in GTK gui." ? can you elaborate on that?

Sorry, for being abrupt. Tomorrow will be better. Tried to play Turrican 2 with
"joyport1=kbd2" in uaerc and an equivalent option in the gui. The game does not react on any key but space and esc, though.

GnoStiC 17 February 2010 15:44

<p><img src="images/smilies/smile.gif" border="0" alt="" title="Smile" smilieid="1" class="inlineimg" /></p>
<p>i don't play games, i just watch demos so i may have missed that <img src="images/smilies/smile.gif" border="0" alt="" title="Smile" smilieid="1" class="inlineimg" /></p>
<p>i'll try that when i'm home..</p>
<p>&nbsp;</p>
<p>
Quote:

Originally Posted by gilgamesh (Post 643354)
Sorry, for being abrupt. Tomorrow will be better. Tried to play Turrican 2 with</p>
<p> &quot;joyport1=kbd2&quot; in uaerc and an equivalent option in the gui. The game does not react on any key but space and esc, though.

</p>
<p>&nbsp;</p>
<p>EDIT:</p>
<p>try this;</p>
<p><a href="http://www.gamzeguckiran.com/puaex_2010_02_17-2.tar.gz" target="_blank">http://www.gamzeguckiran.com/puaex_2010_02_17-2.tar.gz</a></p>
________
Honda NSF100

Hungry Horace 17 February 2010 19:21

sorry to veer off slighty, but GnoStiC - can you answer if the amiga mouse -> host joystick mapping is now fixed? It was something that was fixed in the e-uae source used for PSPUAE (which you worked on), but i noticed was still broken in the e-uae build i use on Linux (PS3) and on OSX? (wip 4)

also there was an issue with joy3 and joy4 constantly having 'fire' pressed.... i assume these are fixed with what has been integrated from winUAE?

the mouse/joypad mapping is really useful when running on the PS3!

i look forward to trying builds for OSX-Intel and Linux-PPC in the near future :)

MagerValp 17 February 2010 22:49

OK, I just tried hacking away at the project to get it to work with an SDL.framework installed under /Library/Frameworks, and I'm giving up.

xaind 18 February 2010 03:09

1 Attachment(s)
@MagerValp: You shouldn't need to make any changes to have PUAE work with the SDL framework installed in /Library/Frameworks. That is exactly where I have SDL installed and my builds of PUAE pick it up just fine.

@GnoStiC: I was wondering if uncommenting that line might be all that was needed :)

I have just tried puaex_2010_2_17-2.tar.gz. There are some changes to the joystick code that break the Cocoa GUI code. I have attached a new version of cocoaui.m that fixes these (I think.) I replaced references to JSEM_NONE with JSEM_END, and references to XXXprefs.jport0 with XXXprefs.jports[0].id etc... So if the user selects "None" from the menu for the first joystick port, it will set changed_prefs.jports[0].id to JSEM_END. Is that the right thing to do? Or should I remove the "None" option altogether?

In any case, the attached version of cocoaui.m compiles, at least. The new version seems to get a *lot* further. It comes up, the background flashes from dark-grey to lighter-grey to white, but then the power "led" down the bottom starts flashing and I get an exception message, then it appears to reboot. This just keeps cycling over and over. Output below.

P.S. I don't think anyone has said this yet, but many, many thanks for all your work on this. I think there are quite a few people looking forward to an updated version of UAE for non-windows platforms. :great

Code:

PUAE 2.0.2
Build date: Feb 18 2010 12:47:07
SDLGFX: Initialized.
SDLGFX: Using SDL version 1.2.14.
SDLGFX: Display is 32 bits deep.
SDLGFX: Found screenmode: 1920x1200.
SDLGFX: Found screenmode: 1600x1200.
SDLGFX: Found screenmode: 1600x1000.
SDLGFX: Found screenmode: 1344x1008.
SDLGFX: Found screenmode: 1280x960.
SDLGFX: Found screenmode: 1344x840.
SDLGFX: Found screenmode: 1280x800.
SDLGFX: Found screenmode: 1024x768.
SDLGFX: Found screenmode: 1024x640.
SDLGFX: Found screenmode: 960x600.
SDLGFX: Found screenmode: 800x600.
SDLGFX: Found screenmode: 800x500.
SDLGFX: Found screenmode: 640x480.
Found 0 joystick(s)
Found quartz raw keyboard mapping
Using raw keymap
Opening cfgfile '/Users/myname/default.uaerc'...failed
Opening cfgfile 'default.uaerc'...failed
Testing the RDTSC instruction ... done.
Calibrating TSC frequency...TSC frequency: 2660.777520 MHz
Found quartz raw keyboard mapping
Using raw keymap
Found quartz raw keyboard mapping
Using raw keymap
Entered action_replay_load()
ROM loader..
SDLGFX: Added P96 mode: 640x480x32
SDLGFX: Added P96 mode: 640x480x8
SDLGFX: Added P96 mode: 800x600x32
SDLGFX: Added P96 mode: 800x600x8
SDLGFX: Added P96 mode: 1024x768x32
SDLGFX: Added P96 mode: 1024x768x8
SDLGFX: Added P96 mode: 1920x1200x32
SDLGFX: Added P96 mode: 1920x1200x8
SDLGFX: Added P96 mode: 1600x1200x32
SDLGFX: Added P96 mode: 1600x1200x8
SDLGFX: Added P96 mode: 1600x1000x32
SDLGFX: Added P96 mode: 1600x1000x8
SDLGFX: Added P96 mode: 1344x1008x32
SDLGFX: Added P96 mode: 1344x1008x8
SDLGFX: Added P96 mode: 1280x960x32
SDLGFX: Added P96 mode: 1280x960x8
SDLGFX: Added P96 mode: 1344x840x32
SDLGFX: Added P96 mode: 1344x840x8
SDLGFX: Added P96 mode: 1280x800x32
SDLGFX: Added P96 mode: 1280x800x8
SDLGFX: Added P96 mode: 1024x640x32
SDLGFX: Added P96 mode: 1024x640x8
SDLGFX: Added P96 mode: 960x600x32
SDLGFX: Added P96 mode: 960x600x8
SDLGFX: Added P96 mode: 800x500x32
SDLGFX: Added P96 mode: 800x500x8
No disk in drive 0.
CPU cycleunit: 256 (0.500)
Building CPU table for configuration: 68000 prefetch 24-bit
1876 CPU functions
Building CPU, 44316 opcodes (0 1 1)
CPU=68000, FPU=0, JIT=0.
CPUID level=10, Family=6, Model=15, Mask=6, Vendor=GenuineIntel [0]
JIT: Building Compiler function table
JIT: Supposedly 42101 compileable opcodes!
CPU cycleunit: 256 (0.500)
SDL: sound driver found and configured at 44100 Hz, buffer is 100 ms (17640 bytes).
BEAMCON0 0000 -> 0020
PAL mode V=50Hz H=15600Hz (227x312)
chipmem cleared
CPU cycleunit: 256 (0.500)
Illegal instruction: 4e7b at 00FC0564 -> 00FC0582
PAL mode V=50Hz H=15600Hz (227x312)
Exception 3 (fc0fe3) at fc0fe0 -> fc081a!
PAL mode V=50Hz H=15600Hz (227x312)
Illegal instruction: 4e7b at 00FC0564 -> 00FC0582
PAL mode V=50Hz H=15600Hz (227x312)
Exception 3 (fc0fe3) at fc0fe0 -> fc081a!

  <--- I pressed the "QUIT" button here

DMACON: 23f0 INTENA: 206c INTREQ: 20 VPOS: 0 HPOS: 1
COP1LC: 00000420, COP2LC: 00c00276 COPPTR: 00000420
DIWSTRT: 2c81 DIWSTOP: f4c1 DDFSTRT: 0038 DDFSTOP: 00d0
BPLCON 0: 1000 1: 0000 2: 0024 3: 0c00 4: 0011
Average frame time: 3849420.55 ms [frames: 812 time: -1169237808]

EDIT: I just noticed the "exception 3" I am getting appears to be the same one that gilgamesh was getting. Sounds like it might be something related to the GUI?

GnoStiC 18 February 2010 11:03

<p><u><a href="http://www.gamzeguckiran.com/puaex_2010_02_18.tar.gz" target="_blank">http://www.gamzeguckiran.com/puaex_2010_02_18.tar.gz</a></u></p>
<p>&nbsp;</p>
<p>@Hungry Horace:</p>
<p>it was probably fixed when merging</p>
<p>&nbsp;</p>
<p>@gilgamesh:</p>
<p>this version works fine for me with &quot;--disable-ui&quot;</p>
<p>&nbsp;</p>
<p>@xaind:</p>
<p>this version should run fine for you, too.</p>
<p>btw, i used your cocoa.m</p>
________
volcano vaporizers

xc8 18 February 2010 13:37

Mustafa abi, this is very nice !!

Just managed to compile it on my Mandriva One 2010 box...

BTW, when I 'insert' an adf when the emul is running, the disk is not recognized...
(I have to insert the floppy before to press the start on gui)

also, the stop/pause/reset/quit buttons are not working when the emul is running..

Chris

GnoStiC 18 February 2010 13:51

selam Chris, tesekkur ederim :)

for the fix, my bad, just remove remark from;
gui_handle_events ();

line in src/custom.c

or wait for my next update..

cheers,

Quote:

Originally Posted by xc8 (Post 643678)
Mustafa abi, this is very nice !!

Just managed to compile it on my Mandriva One 2010 box...

BTW, when I 'insert' an adf when the emul is running, the disk is not recognized...
(I have to insert the floppy before to press the start on gui)

also, the stop/pause/reset/quit buttons are not working when the emul is running..

Chris

________
vaporizer pipe

MagerValp 18 February 2010 16:03

Quote:

Originally Posted by xaind (Post 643567)
@MagerValp: You shouldn't need to make any changes to have PUAE work with the SDL framework installed in /Library/Frameworks. That is exactly where I have SDL installed and my builds of PUAE pick it up just fine.

Please paste your configure output for SDL. As the frameworks don't come with an sdl-config script, a "naked" machine just gets you:
Code:

checking for SDL - version >= 1.2.0... no
*** The sdl-config script installed by SDL could not be found
*** If SDL was installed in PREFIX, make sure PREFIX/bin is in
*** your path, or set the SDL_CONFIG environment variable to the
*** full path to sdl-config.
configure: WARNING: SDL support wanted, but libSDL could not be found

With an sdl-config script that outputs the proper -framework SDL, etc, the configure script fails as conftest.c can't find _main (since there's no SDLMain.m either). And even if you hack past that, the project builds without src/od-macosx/main.m...

GnoStiC 18 February 2010 17:05

update:
http://www.gamzeguckiran.com/puaex_2010_02_18-2.tar.gz
________
buying vaporizer

ajacocks 18 February 2010 20:22

I think that there's something wrong with the tar archive, here:

<snip>
puaex/src/sd-none/Makefile
puaex/src/sd-none/sound.c
puaex/src/sd-none/Makefile.am
puaex/src/sd-none/sound.h
puaex/src/sd-none/Makefile.in
puaex/src/guidep/Makefile
tar: puaex/src/guidep/Makefile: Cannot open: Not a directory
puaex/src/guidep/led.h
tar: puaex/src/guidep/led.h: Cannot open: Not a directory
puaex/src/guidep/floppyfileentry.c
tar: puaex/src/guidep/floppyfileentry.c: Cannot open: Not a directory
puaex/src/guidep/chooserwidget.c
tar: puaex/src/guidep/chooserwidget.c: Cannot open: Not a directory
<snip>

Looks like some symbolic links didn't get tarred up properly.

Thanks!

gilgamesh 18 February 2010 20:30

Quote:

Originally Posted by GnoStiC (Post 643626)
@gilgamesh:
this version works fine for me with "--disable-ui"

Yes, no-ui and key bugs were fixed. :cool

GnoStiC 18 February 2010 21:27

when you;
./bootstrap.sh
./configure

they will be re-linked.

Quote:

Originally Posted by ajacocks (Post 643803)
I think that there's something wrong with the tar archive, here:
..
Looks like some symbolic links didn't get tarred up properly.
Thanks!

________
Harley-Davidson Servi-Car


All times are GMT +2. The time now is 10:38.

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.

Page generated in 0.05965 seconds with 11 queries