UFO:Alien Invasion

Technical support => Mac => Topic started by: keybounce on March 15, 2009, 12:05:10 am

Title: Log of an attempt to compile a universal binary for 10.5.6 for 2.3-dev (trunk)
Post by: keybounce on March 15, 2009, 12:05:10 am
Alright, I took some detailed notes while trying to get this put together. I'm hoping this will be of use to the devs.

The first round:

Log of compilation of Ufo-AI for Mac

12:10 Start installing latest Xcode (312 2621)

Odd errors seen in the logs:
Mar 11 12:36:19 Kleiman-ibook Installer[489]: run preupgrade script for DeveloperToolsCLI
Mar 11 12:36:20 Kleiman-ibook michael[751]: Upgrade scripts will be run.
Mar 11 12:36:20 Kleiman-ibook Installer[489]: Removing obsoleted files
Mar 11 12:36:20 Kleiman-ibook runner[493]: trying to delete: /Developer/^Husr/sbin/vmmap64
Mar 11 12:36:20 Kleiman-ibook runner[493]: trying to delete: /Developer/ usr/libexec/gdb/plugins/MacsBug/MacsBug_plugin
Mar 11 12:36:20 Kleiman-ibook runner[493]: trying to delete: /Developer/ usr/libexec/gdb/gdb-powerpc-apple-darwin
Mar 11 12:36:20 Kleiman-ibook runner[493]: trying to delete: /Developer/ usr/libexec/gdb/gdb-i386-apple-darwin
Mar 11 12:36:20 Kleiman-ibook runner[493]: trying to delete: /Developer/ usr/libexec/gdb/gdb-for-codewarrior
Mar 11 12:36:20 Kleiman-ibook runner[493]: trying to delete: /Developer/^Husr/bin/malloc_history
Mar 11 12:36:20 Kleiman-ibook runner[493]: trying to delete: /Developer/^Husr/bin/leaks
Mar 11 12:36:20 Kleiman-ibook runner[493]: trying to delete: /Developer/^Husr/bin/heap
Mar 11 12:36:20 Kleiman-ibook runner[493]: trying to delete: /Developer/^Husr/bin/atos
Mar 11 12:36:20 Kleiman-ibook runner[493]: trying to delete: /Developer/PLibrary/Developer/3.0/distcc/distcclaunchdconfig

Yes, those are ^H's in the filenames. Go figure.

Large number of missing man pages complained by makewhatis

After install:

Kleiman-ibook:~ michael$ df -l
Filesystem   1024-blocks     Used Available Capacity  Mounted on
/dev/disk0s3    42745372 36480732   6008640    86%    /
/dev/disk0s5    15597564 14497592   1099972    93%    /Volumes/Time Machine Drive

Just under 6 GB (Finder says 5.73).

Step 2: Install MacPorts 1.7.0
Step 3: Install latest X11 (2.3.2.1)

Mar 11 16:22:51 Kleiman-ibook kernel[0]: Finder[129] Unable to clear quarantine `X11-2.3.2.1.pkg': 30

Can someone explain what that means?

Step 4: "sudo port selfupdate"

At this point, I have a "standardized" development environment.

Kleiman-ibook:~ michael$ sudo port selfupdate

MacPorts base version 1.700 installed
Downloaded MacPorts base version 1.700

The MacPorts installation is not outdated so it was not updated
Kleiman-ibook:~ michael$ df -l
Filesystem   1024-blocks     Used Available Capacity  Mounted on
/dev/disk0s3    42745372 36655848   5833524    87%    /
/dev/disk0s5    15597564 14604000    993564    94%    /Volumes/Time Machine Drive
/dev/disk1s2       85860    78380      7480    92%    /Volumes/X11-2.3.2.1
Kleiman-ibook:~ michael$

(TM snapshot done)

Now, follow the instructions on the wiki:

Kleiman-ibook:~ michael$ sudo port install libsdl_ttf libsdl_mixer

NB: Installing libsdl_mixer also installs gettext

Mar 11 20:21:48 Kleiman-ibook ReportCrash[60141]: thread_get_state() returned 268435459: (ipc/send) invalid destination port
Mar 11 20:21:48 Kleiman-ibook ReportCrash[60141]: Failed to create VMUSymbolicator for mach_kernel[0]
Mar 11 20:21:48 Kleiman-ibook ReportCrash[60141]: Formulating crash report for process mach_kernel[0]
Mar 11 20:21:48 Kleiman-ibook ReportCrash[60141]: Saved crashreport to /Library/Logs/CrashReporter/mach_kernel_2009-03-11-202148_Kleiman-ibook.crash using uid: 0 gid: 0, euid: 0 egid: 0

Yes, that showed up in the console log -- while compiling smpeg for libsdl_mixer.

"libjpeg" does not exist in macports ; the name is "jpeg".
"libpng3" does not exist in macports. A look into the fink database shows that "libpng3 1.2.29-1" has a web page at http://www.libpng.org/pub/png/libpng.html; checking there shows that it is "libpng" (no 3) and lists 1.2.35 as the current version. That version is fetched from port as libpng

Kleiman-ibook:macports michael$ date ; sudo port install libsdl_ttf +universal libsdl_mixer +universal jpeg +universal libpng +universal ; date

Woot! A complete recompile of everything for universal still triggers this:
Mar 12 00:10:41 Kleiman-ibook ReportCrash[26792]: thread_get_state() returned 268435459: (ipc/send) invalid destination port
Mar 12 00:10:42 Kleiman-ibook ReportCrash[26792]: Failed to create VMUSymbolicator for mach_kernel[0]
Mar 12 00:10:42 Kleiman-ibook ReportCrash[26792]: Formulating crash report for process mach_kernel[0]
Mar 12 00:10:42 Kleiman-ibook ReportCrash[26792]: Saved crashreport to /Library/Logs/CrashReporter/mach_kernel_2009-03-12-001041_Kleiman-ibook.crash using uid: 0 gid: 0, euid: 0 egid: 0

It is repeatable! Congrats, you found a real kernel bug!

Kleiman-ibook:development michael$ mkdir -p ufoai/trunk
Kleiman-ibook:development michael$ cd ufoai/trunk
Kleiman-ibook:trunk michael$ svn co https://ufoai.svn.sourceforge.net/svnroot/ufoai/ufoai/trunk .
Error validating server certificate for 'https://ufoai.svn.sourceforge.net:443':
 - The certificate is not issued by a trusted authority. Use the
   fingerprint to validate the certificate manually!
Certificate information:
 - Hostname: *.svn.sourceforge.net
 - Valid: from Wed, 12 Nov 2008 04:25:27 GMT until Tue, 12 Jan 2010 04:25:27 GMT
 - Issuer: Equifax Secure Certificate Authority, Equifax, US
 - Fingerprint: 04:b2:70:e9:ba:cf:70:fc:e8:8a:22:86:14:13:51:97:1b:6a:de:38
(R)eject, accept (t)emporarily or accept (p)ermanently?

Ok, so no one has even mentioned what fingerprint we should see.
Come on folks, HTTPS: is only half of the security solution, and is almost useless by itself.
It prevents a stream from being corrupted during transmission, but does nothing to protect against a man-in-the-middle.
Without something to verify the certificate -- either a trusted authority, *or knowing what the fingerprint should be* -- it doesn't do what everyone thinks it does.

Gaah. Even firefox now rejects "self signed" certificates with that big bad police officer.

svn: PROPFIND request failed on '/svnroot/ufoai/ufoai/trunk'
svn: PROPFIND of '/svnroot/ufoai/ufoai/trunk': Could not read status line: connection was closed by server. (https://ufoai.svn.sourceforge.net)

Sigh. Documenting what you see as you go runs into trouble. :-)

./configure --disable-uforadiant  --enable-universal
make && make lang

There are a LOT of warnings on this make:

 * [UFO] src/ports/unix/unix_main.c
 * [UFO] src/ports/macosx/osx_main.m
src/ports/macosx/osx_main.m:107: warning: cannot find interface declaration for ‘SDLApplication’
src/ports/macosx/osx_main.m:107: warning: cannot find interface declaration for ‘SDLApplication’

 * [DED] src/ports/macosx/osx_main.m
src/ports/macosx/osx_main.m:107: warning: cannot find interface declaration for ‘SDLApplication’
src/ports/macosx/osx_main.m:107: warning: cannot find interface declaration for ‘SDLApplication’
 * [DED] ... linking -rdynamic (-lz -lcurl -lssl -lcrypto -lz -lcurses  )
 * [MAP] src/tools/ufo2map/ufo2map.c
In file included from /opt/local/include/jpeglib.h:28,
                 from src/tools/ufo2map/common/imagelib.h:31,
                 from src/tools/ufo2map/lighting.h:28,
                 from src/tools/ufo2map/ufo2map.c:33:
/opt/local/include/jconfig.h:12:1: warning: "HAVE_STDLIB_H" redefined
In file included from src/tools/ufo2map/common/../../../shared/shared.h:30,
                 from src/tools/ufo2map/common/shared.h:32,
                 from src/tools/ufo2map/lighting.h:25,
                 from src/tools/ufo2map/ufo2map.c:33:
src/tools/ufo2map/common/../../../shared/../../config.h:71:1: warning: this is the location of the previous definition
In file included from /opt/local/include/jpeglib.h:28,
                 from src/tools/ufo2map/common/imagelib.h:31,
                 from src/tools/ufo2map/lighting.h:28,
                 from src/tools/ufo2map/ufo2map.c:33:
/opt/local/include/jconfig.h:12:1: warning: "HAVE_STDLIB_H" redefined
In file included from src/tools/ufo2map/common/../../../shared/shared.h:30,
                 from src/tools/ufo2map/common/shared.h:32,
                 from src/tools/ufo2map/lighting.h:25,
                 from src/tools/ufo2map/ufo2map.c:33:
src/tools/ufo2map/common/../../../shared/../../config.h:71:1: warning: this is the location of the previous definition

These errors continue for almost all of [ MAP ] . Odd, I didn't tell it to "make maps".

Kleiman-ibook:trunk michael$  contrib/scripts/map-get
Usage: map-get [options] command

Commands:
 upgrade - make sure all maps are up to date
 generate DST - generate or update repository dir DST
                (probably not what you want)

Options:
  -h, --help     show this help message and exit
  -v, --verbose 
Kleiman-ibook:trunk michael$  contrib/scripts/map-get upgrade
getting list of available maps
WARNING ufo2map version mismatch                   
Continue? [Y|n]n

Alright, this is a flaw. The "How to compile" page says to use this script, but it doesn't work!


Time:
Macports took 3 hours to download, compile and install the needed libraries.
Svn took 2 hours and 20 minutes just to check out a copy of the Ufo AI tree

Dealing with Time Machine blowing up (backup too large for the backup drive; having to cut both the newly installed stuff AND enough of the old stuff that a future backup can backup the new stuff): Days :-). (Small backup drive.)

Final disk space:
/dev/disk0s3    42745372 41292664   1196708    98%    /

Starting:
/dev/disk0s3    42745372 36480732   6008640    86%    /

That's just about 5 gig. Wow.


===
The second round:

Fixing the maps (thank you geever): It compiles.

I have a .dmg. And I can run the program.

Attempting to run a skirmish, results in this in the console:

Mar 14 13:04:01 Kleiman-ibook [0x0-0x2e12e1].net.sourceforge.UFOAI[12328]: R_LoadProgram: 'default' loaded.
Mar 14 13:04:01 Kleiman-ibook [0x0-0x2e12e1].net.sourceforge.UFOAI[12328]: R_LoadProgram: 'warp' loaded.
Mar 14 13:04:01 Kleiman-ibook [0x0-0x2e12e1].net.sourceforge.UFOAI[12328]: SDL_ttf version 2.0.9 - we need at least 2.0.7
Mar 14 13:04:01 Kleiman-ibook [0x0-0x2e12e1].net.sourceforge.UFOAI[12328]: ...registering 10 fonts
Mar 14 13:04:01 Kleiman-ibook [0x0-0x2e12e1].net.sourceforge.UFOAI[12328]: Could not find cvar 'cl_3dmap'
Mar 14 13:04:34: --- last message repeated 3 times ---
Mar 14 13:04:01 Kleiman-ibook [0x0-0x2e12e1].net.sourceforge.UFOAI[12328]: Could not find cvar 'g_actorspeed'
Mar 14 13:04:01 Kleiman-ibook [0x0-0x2e12e1].net.sourceforge.UFOAI[12328]: Change gametype to 'Skirmish mode'
Mar 14 13:04:01 Kleiman-ibook [0x0-0x2e12e1].net.sourceforge.UFOAI[12328]: Could not find rank 'rifleman'
Mar 14 13:04:34: --- last message repeated 7 times ---
Mar 14 13:04:01 Kleiman-ibook [0x0-0x2e12e1].net.sourceforge.UFOAI[12328]: ------- Loading game.dylib -------
Mar 14 13:04:01 Kleiman-ibook [0x0-0x2e12e1].net.sourceforge.UFOAI[12328]: LoadLibrary (./base/game.dylib)
Mar 14 13:04:01 Kleiman-ibook [0x0-0x2e12e1].net.sourceforge.UFOAI[12328]: ==== InitGame ====
Mar 14 13:04:01 Kleiman-ibook [0x0-0x2e12e1].net.sourceforge.UFOAI[12328]: SV_ParseAssembly: warning - cvar 'rm_drop' value doesn't seam to be a valid tile id '' - set to default '+drop_firebird'
Mar 14 13:04:01 Kleiman-ibook [0x0-0x2e12e1].net.sourceforge.UFOAI[12328]: CM_LoadMap: "-africa/af_ +main +drop_firebird" "-40 -16 0 -40 -16 0"
Mar 14 13:04:01 Kleiman-ibook [0x0-0x2e12e1].net.sourceforge.UFOAI[12328]: Map:africa/af_main  Offset:(-40, -16, 0)
Mar 14 13:04:01 Kleiman-ibook [0x0-0x2e12e1].net.sourceforge.UFOAI[12328]: wpMins:(128, 128, 0) wpMaxs:(215, 159, 4)
Mar 14 13:04:01 Kleiman-ibook [0x0-0x2e12e1].net.sourceforge.UFOAI[12328]: Shifted wpMins:(88, 112, 0) wpMaxs:(175, 143, 4)
Mar 14 13:04:01 Kleiman-ibook [0x0-0x2e12e1].net.sourceforge.UFOAI[12328]: Tile bounds: (88, 112, 0) to (175, 143, 4)
Mar 14 13:04:01 Kleiman-ibook [0x0-0x2e12e1].net.sourceforge.UFOAI[12328]: Source bounds: (128, 128, 0) to (215, 159, 4)
Mar 14 13:04:01 Kleiman-ibook [0x0-0x2e12e1].net.sourceforge.UFOAI[12328]: Done copying data.
Mar 14 13:04:01 Kleiman-ibook [0x0-0x2e12e1].net.sourceforge.UFOAI[12328]: Loaded routing for tile africa/af_main in   0.0s
Mar 14 13:04:01 Kleiman-ibook [0x0-0x2e12e1].net.sourceforge.UFOAI[12328]: Map:africa/af_drop_firebird  Offset:(-40, -16, 0)
Mar 14 13:04:01 Kleiman-ibook [0x0-0x2e12e1].net.sourceforge.UFOAI[12328]: wpMins:(128, 128, 0) wpMaxs:(143, 151, 3)
Mar 14 13:04:01 Kleiman-ibook [0x0-0x2e12e1].net.sourceforge.UFOAI[12328]: Shifted wpMins:(88, 112, 0) wpMaxs:(103, 135, 3)
Mar 14 13:04:01 Kleiman-ibook [0x0-0x2e12e1].net.sourceforge.UFOAI[12328]: Tile bounds: (88, 112, 0) to (103, 135, 3)
Mar 14 13:04:01 Kleiman-ibook [0x0-0x2e12e1].net.sourceforge.UFOAI[12328]: Source bounds: (128, 128, 0) to (143, 151, 3)
Mar 14 13:04:01 Kleiman-ibook [0x0-0x2e12e1].net.sourceforge.UFOAI[12328]: Done copying data.
Mar 14 13:04:01 Kleiman-ibook [0x0-0x2e12e1].net.sourceforge.UFOAI[12328]: Loaded routing for tile africa/af_drop_firebird in   1.0s
Mar 14 13:04:01 Kleiman-ibook [0x0-0x2e12e1].net.sourceforge.UFOAI[12328]: checksum for the map '+africa': 2906337093
Mar 14 13:04:01 Kleiman-ibook [0x0-0x2e12e1].net.sourceforge.UFOAI[12328]: ufo script checksum 285034083
Mar 14 13:04:01 Kleiman-ibook [0x0-0x2e12e1].net.sourceforge.UFOAI[12328]: Created AI player (team 0)
Mar 14 13:04:01 Kleiman-ibook [0x0-0x2e12e1].net.sourceforge.UFOAI[12328]: Created AI player (team 7)
Mar 14 13:04:01 Kleiman-ibook [0x0-0x2e12e1].net.sourceforge.UFOAI[12328]: -------------------------------------
Mar 14 13:04:01 Kleiman-ibook [0x0-0x2e12e1].net.sourceforge.UFOAI[12328]: Connecting to localhost...
Mar 14 13:04:01 Kleiman-ibook [0x0-0x2e12e1].net.sourceforge.UFOAI[12328]: Map: +africa
Mar 14 13:04:01 Kleiman-ibook [0x0-0x2e12e1].net.sourceforge.UFOAI[12328]: load material file: 'materials/africa.mat'
Mar 14 13:04:01 Kleiman-ibook [0x0-0x2e12e1].net.sourceforge.UFOAI[12328]: Starting the game...
Mar 14 13:04:01 Kleiman-ibook [0x0-0x2e12e1].net.sourceforge.UFOAI[12328]: michael has joined team 0
Mar 14 13:04:01 Kleiman-ibook [0x0-0x2e12e1].net.sourceforge.UFOAI[12328]: (player 0) It's team 1's round
Mar 14 13:04:01 Kleiman-ibook [0x0-0x2e12e1].net.sourceforge.UFOAI[12328]: michael has taken control over team 1.
Mar 14 13:04:01 Kleiman-ibook [0x0-0x2e12e1].net.sourceforge.UFOAI[12328]: Didn't find parent menu "main"
Mar 14 13:04:01 Kleiman-ibook [0x0-0x2e12e1].net.sourceforge.UFOAI[12328]: music change to PsymongO4 (from van_theme)
Mar 14 13:04:02 Kleiman-ibook [0x0-0x2e12e1].net.sourceforge.UFOAI[12328]: 0   ufo                                 0x00198d04 Sys_Mkdir + 180
Mar 14 13:04:03 Kleiman-ibook [0x0-0x2e12e1].net.sourceforge.UFOAI[12328]: Error: Received signal 6.
Mar 14 13:04:03 Kleiman-ibook [0x0-0x2e12e1].net.sourceforge.UFOAI[12328]: Wrote keys.cfg
Mar 14 13:04:03 Kleiman-ibook com.apple.launchd[112] ([0x0-0x2e12e1].net.sourceforge.UFOAI[12328]): Exited with exit code: 1


Alright: Attempting to start a skirmish resulted in the game crashing. It detects and traps a signal 6. Had that signal actually arrived, Mac Os would have given me a nice, easy to submit debugging trace; as it is, I can only report this. And the truth is, I don't know if it's that the africa map from map-get is not compatible with the mac compiled code, or if it's something serious.

Alright, lets go to a campaign game. Playing around with options, ufopedia, etc

Mar 14 14:25:33 Kleiman-ibook [0x0-0x2e52e5].net.sourceforge.UFOAI[12423]: Campaign data loaded - size 4131324 bytes
Mar 14 14:25:33 Kleiman-ibook [0x0-0x2e52e5].net.sourceforge.UFOAI[12423]: ...techs: 192
Mar 14 14:25:33 Kleiman-ibook [0x0-0x2e52e5].net.sourceforge.UFOAI[12423]: ...buildings: 22
Mar 14 14:25:33 Kleiman-ibook [0x0-0x2e52e5].net.sourceforge.UFOAI[12423]: ...ranks: 16
Mar 14 14:25:33 Kleiman-ibook [0x0-0x2e52e5].net.sourceforge.UFOAI[12423]: ...nations: 8
Mar 14 14:25:33 Kleiman-ibook [0x0-0x2e52e5].net.sourceforge.UFOAI[12423]: ...cities: 7
Mar 14 14:25:33 Kleiman-ibook [0x0-0x2e52e5].net.sourceforge.UFOAI[12423]: Sanity check for script data
Mar 14 14:25:33 Kleiman-ibook [0x0-0x2e52e5].net.sourceforge.UFOAI[12423]: ...... no mappart for building 'building_aliencontainment2' given
Mar 14 14:25:33 Kleiman-ibook [0x0-0x2e52e5].net.sourceforge.UFOAI[12423]: ...... no mappart for building 'building_hangar2' given
Mar 14 14:25:33 Kleiman-ibook [0x0-0x2e52e5].net.sourceforge.UFOAI[12423]: ...... no mappart for building 'building_large_ufo_hangar2' given
Mar 14 14:25:33 Kleiman-ibook [0x0-0x2e52e5].net.sourceforge.UFOAI[12423]: ...... no mappart for building 'building_workshop2' given
Mar 14 14:25:33 Kleiman-ibook [0x0-0x2e52e5].net.sourceforge.UFOAI[12423]: ...buildings failed
Mar 14 14:25:33 Kleiman-ibook [0x0-0x2e52e5].net.sourceforge.UFOAI[12423]: ...tech ok
Mar 14 14:25:33 Kleiman-ibook [0x0-0x2e52e5].net.sourceforge.UFOAI[12423]: ...aircraft ok
Mar 14 14:25:33 Kleiman-ibook [0x0-0x2e52e5].net.sourceforge.UFOAI[12423]: ...items ok

...

Mar 14 14:25:33 Kleiman-ibook [0x0-0x2e52e5].net.sourceforge.UFOAI[12423]: Can't find pic: techs/base_AA51_launcher
Mar 14 14:26:47: --- last message repeated 24 times ---
Mar 14 14:25:33 Kleiman-ibook [0x0-0x2e52e5].net.sourceforge.UFOAI[12423]: Can't find pic: techs/base_ammo_AA51
Mar 14 14:26:48: --- last message repeated 14 times ---

...

Mar 14 14:26:12 Kleiman-ibook [0x0-0x2e52e5].net.sourceforge.UFOAI[12423]: Can't find pic: techs/craft_ammo_shiva_1
Mar 14 14:26:51: --- last message repeated 373 times ---
Mar 14 14:26:12 Kleiman-ibook [0x0-0x2e52e5].net.sourceforge.UFOAI[12423]: Can't find pic: techs/craft_ammo_shiva_2
Mar 14 14:26:51: --- last message repeated 23 times ---
Mar 14 14:26:12 Kleiman-ibook [0x0-0x2e52e5].net.sourceforge.UFOAI[12423]: Can't find pic: techs/craft_ammo_s
Mar 14 14:26:21 Kleiman-ibook [0x0-0x2e52e5].net.sourceforge.UFOAI[12423]: hiva_2
Mar 14 14:26:21 Kleiman-ibook [0x0-0x2e52e5].net.sourceforge.UFOAI[12423]: Can't find pic: techs/craft_ammo_shiva_2
Mar 14 14:26:51: --- last message repeated 398 times ---

The shiva pics complaints (1 and 2) show up thousands of times in the logs, in batches of 400.

I never advance the clock past the starting moment. I'm just looking around in the in-game docs, moving the map, playing around with flat vs. 3d world view, building new places in the base, equiping the aircraft, etc. I'm expecting that the first ufo encounter will crash when the map loads.

After playing around, (about an hour), the world map gets messed up. I'm no longer seeing continents, land and water, etc. Instead, colored rectangles -- darn, I should have taken a screen shot.

I'm not sure how much of these problems are from code issues, and how much is from compilation issues.

Kleiman-ibook:trunk michael$ svn info
Path: .
URL: https://ufoai.svn.sourceforge.net/svnroot/ufoai/ufoai/trunk
Repository Root: https://ufoai.svn.sourceforge.net/svnroot/ufoai
Repository UUID: 39b98707-f80d-0410-bc7e-c6b02f5409da
Revision: 23524
Node Kind: directory
Schedule: normal
Last Changed Author: bayo-fr
Last Changed Rev: 23524
Last Changed Date: 2009-03-14 09:19:22 -0700 (Sat, 14 Mar 2009)


Ohh,here's something:

Kleiman-ibook:trunk michael$ ls ~/.ufoai/2.3-dev/base/
total 372
  0 Users/        4 keys.cfg      364 ufoconsole.log
  4 config.cfg        0 save/
  0 history        0 stats.log
Kleiman-ibook:trunk michael$

Yep, that console.log file is a duplicate of what got written to the system.log.

Title: Re: Log of an attempt to compile a universal binary for 10.5.6 for 2.3-dev (trunk)
Post by: keybounce on March 15, 2009, 12:19:31 am
Ok, lets try this:

Kleiman-ibook:trunk michael$ svn update
U    src/client/menu/m_parse.c
U    src/client/menu/m_menus.c
U    src/client/menu/m_menus.h
U    src/client/cl_actor.c
U    base/ufos/menu_geoscape.ufo
Updated to revision 23530.

Recompiling ....
Title: Re: Log of an attempt to compile a universal binary for 10.5.6 for 2.3-dev (trunk)
Post by: keybounce on March 15, 2009, 04:55:44 am
Alright, it is failing, and failing spectacularly.

I've tried many different maps. I've tried many different graphics options.

Every time, the graphics are garbled. I can see enough to know that the shapes are there, but all the images on the shapes are bunk.

I don't know if it's my compilation environment, the fact that I have an ATI Mobile Radeon 9550 and the game wants more, that I'm using maps from map-get rather than locally compiled, or a bug in the game's graphic display.

I've attached three (err, make that one -- it won't let me attach more) sample screenshots, as well as logs from running it. Other than one case where there were more particles from fire than the video card can support, nothing in the logs shows a problem.

Two or three times, the game crashed with signal 6. It was not consistent -- sometimes a given map would cause a problem, sometimes not.

This is trunk, 23530.

Mac developers: What was the last version that you knew ran properly on G4's? I want to see if I can get that version to compile properly on my system.

[attachment deleted by admin]
Title: Re: Log of an attempt to compile a universal binary for 10.5.6 for 2.3-dev (trunk)
Post by: keybounce on March 16, 2009, 10:26:59 pm
Same graphics issue, 23541.
Title: Re: Log of an attempt to compile a universal binary for 10.5.6 for 2.3-dev (trunk)
Post by: Mattn on March 17, 2009, 08:49:51 am
did you already try to compile the maps yourself? or only via map-get script? if not, please try to compile one map yourself: ./ufo2map maps/africa

if you still have problems, please also deactivate the glsl shaders - type r_programs 0 to the game console

still no luck? type r_checkerror 1 (or was is r_error 1?!)
Title: Re: Log of an attempt to compile a universal binary for 10.5.6 for 2.3-dev (trunk)
Post by: keybounce on March 18, 2009, 03:39:10 am
Here's what I have:

Kleiman-ibook:trunk michael$ ./ufo2map base/maps/africa
---- ufo2map 1.2.4 ----
path: 'base/maps/africa'

---- filesystem initialization -----
Adding game dir: /usr/local/lib/ufoai/base
Adding game dir: /usr/local/share/ufoai/base
Adding game dir: /Users/michael/.ufoai/2.3-dev/base
Adding game dir: ./base
Added packfile ./base/0base.pk3 (17 files)
Added packfile ./base/0maps.pk3 (391 files)
Added packfile ./base/0materials.pk3 (33 files)
Added packfile ./base/0media.pk3 (10 files)
Added packfile ./base/0models.pk3 (1444 files)
Added packfile ./base/0music.pk3 (40 files)
Added packfile ./base/0pics.pk3 (2035 files)
Added packfile ./base/0snd.pk3 (177 files)
Added packfile ./base/0ufos.pk3 (90 files)
using ./base for writing
...map: 'base/maps/africa.map'
...bsp: 'base/maps/africa.bsp'
Error: file 'base/maps/africa.map' doesn't exist
Kleiman-ibook:trunk michael$ ls base/maps
total 185892
    0 africa/             4 ice.ump
    4 africa.ump          0 industrial/
    0 alienb/             4 industrial.ump

Africa is a directory, with several maps in there. And I don't know how to force a specific one in the skirmish.

Yes, I only used map-get. (We're basically told not to compile them on the Mac, so I didn't :-).
Title: Re: Log of an attempt to compile a universal binary for 10.5.6 for 2.3-dev (trunk)
Post by: keybounce on March 18, 2009, 03:50:54 am
Alright, something's wrong:

Kleiman-ibook:trunk michael$ ./ufo2map base/maps/fueldump
---- ufo2map 1.2.4 ----
path: 'base/maps/fueldump'

---- filesystem initialization -----
Adding game dir: /usr/local/lib/ufoai/base
Adding game dir: /usr/local/share/ufoai/base
Adding game dir: /Users/michael/.ufoai/2.3-dev/base
Adding game dir: ./base
Added packfile ./base/0base.pk3 (17 files)
Added packfile ./base/0maps.pk3 (391 files)
Added packfile ./base/0materials.pk3 (33 files)
Added packfile ./base/0media.pk3 (10 files)
Added packfile ./base/0models.pk3 (1444 files)
Added packfile ./base/0music.pk3 (40 files)
Added packfile ./base/0pics.pk3 (2035 files)
Added packfile ./base/0snd.pk3 (177 files)
Added packfile ./base/0ufos.pk3 (90 files)
using ./base for writing
...map: 'base/maps/fueldump.map'
...bsp: 'base/maps/fueldump.bsp'
Error: file 'base/maps/fueldump.map' doesn't exist
Kleiman-ibook:trunk michael$ ls base/maps/fueldump.*
3156 base/maps/fueldump.bsp    284 base/maps/fueldump.map
Kleiman-ibook:trunk michael$

Title: Re: Log of an attempt to compile a universal binary for 10.5.6 for 2.3-dev (trunk)
Post by: keybounce on March 18, 2009, 06:54:34 am
Updated to 23583

Map "lake_ice" was modified, and "make maps" rebuilt it.

Trying a skirmish. Logfile is attached. Game crashed after I clicked on start, before any map was displayed.

NB: The little map previews show up just fine.

Grr. Can the forums please accept ".log" attachments, or else change that extension on ufoconsole.log?

Double Grr: After a post here fails because it doesn't like the attachment's extension, it won't let me post at all.

[attachment deleted by admin]
Title: Re: Log of an attempt to compile a universal binary for 10.5.6 for 2.3-dev (trunk)
Post by: geever on March 18, 2009, 11:08:08 am
note that ufo2map needs path relative to base:
Code: [Select]
$ ./ufo2map maps/fueldump

-geever
Title: Re: Log of an attempt to compile a universal binary for 10.5.6 for 2.3-dev (trunk)
Post by: Mattn on March 19, 2009, 08:11:09 am
you have a lot errors in your script files - see the Com_ParseEquipment output in the log. are you sure that you are using up-to-date binary with up-to-date script files (base/ufos)

please don't mix anything from older revisions or versions with new binaries or vice versa.
Title: Re: Log of an attempt to compile a universal binary for 10.5.6 for 2.3-dev (trunk)
Post by: keybounce on March 19, 2009, 05:11:43 pm
As far as I know I have a completely clean install.

Current issue:
ERROR: CM_AddMapTile: wilderness has wrong version number (76 should be 77)

This on an update to 23601. Updating again to 23603, and :


Kleiman-ibook:trunk michael$ svn up
U    src/client/cl_menu.c
U    src/client/renderer/r_main.c
U    src/client/cl_joystick.c
Updated to revision 23603.
Kleiman-ibook:trunk michael$ make ufo2map
make: `ufo2map' is up to date.
Kleiman-ibook:trunk michael$

Somewhere a dependency got missed; the map compiler needs to be recompiled with a new version, and all the maps need to be redone with the new compiler.

I will blow it all away, and try again.
Title: Re: Log of an attempt to compile a universal binary for 10.5.6 for 2.3-dev (trunk)
Post by: keybounce on March 19, 2009, 11:54:04 pm
Trying to compile bunker.map was aborted after more than an hour!
Trying wilderness.map next ...

AHH:

Doing "make maps" passes a few extra options. In particular, extra light sources.

Any reason that the lighting is not the default? Or why the extra light isn't the default?
Title: Re: Log of an attempt to compile a universal binary for 10.5.6 for 2.3-dev (trunk)
Post by: keybounce on March 20, 2009, 02:04:30 am
did you already try to compile the maps yourself? or only via map-get script? if not, please try to compile one map yourself: ./ufo2map maps/africa

if you still have problems, please also deactivate the glsl shaders - type r_programs 0 to the game console

still no luck? type r_checkerror 1 (or was is r_error 1?!)
Alright, how do you bring up the console? I thought it was "esc", but that's just cycling the tips of the day.

Latest compile (after blowing away everything)
 2186  svn up
 2188  ./configure --disable-uforadiant  --enable-universal
 2189  make lang
 2190  make
 2192  contrib/scripts/map-get upgrade
 2193  touch base/maps/bunker.map
 2194  make maps
 2197  ./ufo2map maps/wilderness.map
 2198  ./ufo2map maps/bunker.map
 2203  make macinstaller
 2204  open /Users/michael/development/ufoai/trunk/src/ports/macosx/installer/ufoai-2.3-dev-macosx-universal.dmg

Version 23603

What happens: As soon as the map loads, the game exits. Not crashing this time, just exiting with error code 1.

Log:
----- network initialization -------
libcurl/7.16.3 OpenSSL/0.9.7l zlib/1.2.3 initialized.
------ server initialization -------
----- console initialization -------
Console initialized.
------- video initialization -------
SDL version: 1.2.13
I: desktop depth: 32bpp
I: video memory: 0
I: video driver: Quartz
I: setting mode 5: 960x720 (fullscreen: no)
I: set swap control to 0
I: got 8 bits of stencil
I: got 24 bits of depth buffer
I: got double buffer
I: got 8 bits for red
I: got 8 bits for green
I: got 8 bits for blue
I: got 8 bits for alpha
I: got 0 multisample buffers
GL_VENDOR: ATI Technologies Inc.
GL_RENDERER: ATI Radeon 9550 OpenGL Engine
GL_VERSION: 2.0 ATI-1.5.36
GL_EXTENSIONS: GL_ARB_transpose_matrix GL_ARB_vertex_program GL_ARB_vertex_blend GL_ARB_window_pos GL_ARB_shader_objects GL_ARB_vertex_shader GL_ARB_shading_language_100 GL_EXT_multi_draw_arrays GL_EXT_clip_volume_hint GL_EXT_rescale_normal GL_EXT_draw_range_elements GL_EXT_fog_coord GL_EXT_gpu_program_parameters GL_EXT_geometry_shader4 GL_EXT_transform_feedback GL_APPLE_client_storage GL_APPLE_specular_vector GL_APPLE_transform_hint GL_APPLE_packed_pixels GL_APPLE_fence GL_APPLE_vertex_array_object GL_APPLE_vertex_program_evaluators GL_APPLE_element_array GL_APPLE_flush_render GL_APPLE_aux_depth_stencil GL_NV_texgen_reflection GL_NV_light_max_exponent GL_IBM_rasterpos_clip GL_SGIS_generate_mipmap GL_ARB_imaging GL_ARB_point_parameters GL_ARB_texture_env_crossbar GL_ARB_texture_border_clamp GL_ARB_multitexture GL_ARB_texture_env_add GL_ARB_texture_cube_map GL_ARB_texture_env_dot3 GL_ARB_multisample GL_ARB_texture_env_combine GL_ARB_texture_compression GL_ARB_texture_mirrored_repeat GL_ARB_shadow GL_ARB_depth_texture GL_ARB_shadow_ambient GL_ARB_fragment_program GL_ARB_fragment_program_shadow GL_ARB_fragment_shader GL_ARB_occlusion_query GL_ARB_point_sprite GL_ARB_texture_non_power_of_two GL_ARB_vertex_buffer_object GL_ARB_pixel_buffer_object GL_ARB_draw_buffers GL_EXT_compiled_vertex_array GL_EXT_framebuffer_object GL_EXT_texture_rectangle GL_ARB_texture_rectangle GL_EXT_texture_env_add GL_EXT_blend_color GL_EXT_blend_minmax GL_EXT_blend_subtract GL_EXT_texture_lod_bias GL_EXT_abgr GL_EXT_bgra GL_EXT_stencil_wrap GL_EXT_texture_filter_anisotropic GL_EXT_separate_specular_color GL_EXT_secondary_color GL_EXT_blend_func_separate GL_EXT_shadow_funcs GL_EXT_texture_compression_s3tc GL_EXT_texture_compression_dxt1 GL_EXT_texture_sRGB GL_EXT_blend_equation_separate GL_EXT_texture_mirror_clamp GL_EXT_packed_depth_stencil GL_APPLE_flush_buffer_range GL_APPLE_ycbcr_422 GL_APPLE_vertex_array_range GL_APPLE_texture_range GL_APPLE_float_pixels GL_ATI_texture_float GL_ARB_texture_float GL_ARB_half_float_pixel GL_APPLE_pixel_buffer GL_APPLE_object_purgeable GL_NV_blend_square GL_NV_fog_distance GL_ATI_texture_mirror_once GL_ATI_text_fragment_shader GL_ATI_blend_equation_separate GL_ATI_blend_weighted_minmax GL_ATI_texture_env_combine3 GL_ATI_separate_stencil GL_SGIS_texture_edge_clamp GL_SGIS_texture_lod GL_SGI_color_matrix
max texture units: 8
max texture size: detected 2048
R_LoadProgram: 'default' loaded.
R_LoadProgram: 'warp' loaded.
SDL_ttf version 2.0.9 - we need at least 2.0.7
------- sound initialization -------
SDL_mixer version: 1.2.8
... audio rate: 44100
... audio channels: 2
... driver: 'coreaudio'
... channels to mix sounds: 8
------- input initialization -------
0 possible joysticks
no joystick found.
----------- parse scripts ----------
Shared Client/Server Info loaded
...110 items parsed
... 32 damage types parsed
... 67 map definitions parsed
... 29 equipment definitions parsed
... 10 inventory definitions parsed
... 22 team definitions parsed
music change to van_theme (from PsymongN3)
S_Music_Start: Playing music: 'music/van_theme'
R_RegisterModelShort: Could not find: 'weapons/autocannon/autocannon'
CL_LanguageInit: language settings are stored in configuration: en
...using language: en_US.UTF-8
SDL_ttf version 2.0.9 - we need at least 2.0.7
...registering 10 fonts
126 static models loaded
====== UFO Initialized ======

Switch grab input off
Change gametype to 'Skirmish mode'
Could not find rank 'rifleman'
Could not find rank 'rifleman'
Could not find rank 'rifleman'
Could not find rank 'rifleman'
Could not find rank 'rifleman'
Could not find rank 'rifleman'
Could not find rank 'rifleman'
Could not find rank 'rifleman'
------- Loading game.dylib -------
LoadLibrary (./base/game.dylib)
==== InitGame ====
Map:wilderness  Offset:(0, 0, 0)
wpMins:(128, 118, 0) wpMaxs:(193, 197, 7)
Shifted wpMins:(128, 118, 0) wpMaxs:(193, 197, 7)
Tile bounds: (128, 118, 0) to (193, 197, 7)
Source bounds: (128, 118, 0) to (193, 197, 7)
Done copying data.
Wrote keys.cfg


[attachment deleted by admin]
Title: Re: Log of an attempt to compile a universal binary for 10.5.6 for 2.3-dev (trunk)
Post by: keybounce on March 20, 2009, 02:19:16 am
did you already try to compile the maps yourself? or only via map-get script? if not, please try to compile one map yourself: ./ufo2map maps/africa

if you still have problems, please also deactivate the glsl shaders - type r_programs 0 to the game console

still no luck? type r_checkerror 1 (or was is r_error 1?!)
Ah -- Backtick brings up the console.

Console does not support "paste" -- apple-V does not paste " r_programs 0" in. Gotta type by hand :-)

Ok, r_programs and r_checkerror set (0 and 1).

Trying a skirmish ...
And it crashes again.

----- network initialization -------
libcurl/7.16.3 OpenSSL/0.9.7l zlib/1.2.3 initialized.
------ server initialization -------
----- console initialization -------
Console initialized.
------- video initialization -------
SDL version: 1.2.13
I: desktop depth: 32bpp
I: video memory: 0
I: video driver: Quartz
I: setting mode 5: 960x720 (fullscreen: no)
I: set swap control to 0
I: got 8 bits of stencil
I: got 24 bits of depth buffer
I: got double buffer
I: got 8 bits for red
I: got 8 bits for green
I: got 8 bits for blue
I: got 8 bits for alpha
I: got 0 multisample buffers
GL_VENDOR: ATI Technologies Inc.
GL_RENDERER: ATI Radeon 9550 OpenGL Engine
GL_VERSION: 2.0 ATI-1.5.36
GL_EXTENSIONS: GL_ARB_transpose_matrix GL_ARB_vertex_program GL_ARB_vertex_blend GL_ARB_window_pos GL_ARB_shader_objects GL_ARB_vertex_shader GL_ARB_shading_language_100 GL_EXT_multi_draw_arrays GL_EXT_clip_volume_hint GL_EXT_rescale_normal GL_EXT_draw_range_elements GL_EXT_fog_coord GL_EXT_gpu_program_parameters GL_EXT_geometry_shader4 GL_EXT_transform_feedback GL_APPLE_client_storage GL_APPLE_specular_vector GL_APPLE_transform_hint GL_APPLE_packed_pixels GL_APPLE_fence GL_APPLE_vertex_array_object GL_APPLE_vertex_program_evaluators GL_APPLE_element_array GL_APPLE_flush_render GL_APPLE_aux_depth_stencil GL_NV_texgen_reflection GL_NV_light_max_exponent GL_IBM_rasterpos_clip GL_SGIS_generate_mipmap GL_ARB_imaging GL_ARB_point_parameters GL_ARB_texture_env_crossbar GL_ARB_texture_border_clamp GL_ARB_multitexture GL_ARB_texture_env_add GL_ARB_texture_cube_map GL_ARB_texture_env_dot3 GL_ARB_multisample GL_ARB_texture_env_combine GL_ARB_texture_compression GL_ARB_texture_mirrored_repeat GL_ARB_shadow GL_ARB_depth_texture GL_ARB_shadow_ambient GL_ARB_fragment_program GL_ARB_fragment_program_shadow GL_ARB_fragment_shader GL_ARB_occlusion_query GL_ARB_point_sprite GL_ARB_texture_non_power_of_two GL_ARB_vertex_buffer_object GL_ARB_pixel_buffer_object GL_ARB_draw_buffers GL_EXT_compiled_vertex_array GL_EXT_framebuffer_object GL_EXT_texture_rectangle GL_ARB_texture_rectangle GL_EXT_texture_env_add GL_EXT_blend_color GL_EXT_blend_minmax GL_EXT_blend_subtract GL_EXT_texture_lod_bias GL_EXT_abgr GL_EXT_bgra GL_EXT_stencil_wrap GL_EXT_texture_filter_anisotropic GL_EXT_separate_specular_color GL_EXT_secondary_color GL_EXT_blend_func_separate GL_EXT_shadow_funcs GL_EXT_texture_compression_s3tc GL_EXT_texture_compression_dxt1 GL_EXT_texture_sRGB GL_EXT_blend_equation_separate GL_EXT_texture_mirror_clamp GL_EXT_packed_depth_stencil GL_APPLE_flush_buffer_range GL_APPLE_ycbcr_422 GL_APPLE_vertex_array_range GL_APPLE_texture_range GL_APPLE_float_pixels GL_ATI_texture_float GL_ARB_texture_float GL_ARB_half_float_pixel GL_APPLE_pixel_buffer GL_APPLE_object_purgeable GL_NV_blend_square GL_NV_fog_distance GL_ATI_texture_mirror_once GL_ATI_text_fragment_shader GL_ATI_blend_equation_separate GL_ATI_blend_weighted_minmax GL_ATI_texture_env_combine3 GL_ATI_separate_stencil GL_SGIS_texture_edge_clamp GL_SGIS_texture_lod GL_SGI_color_matrix
max texture units: 8
max texture size: detected 2048
R_LoadProgram: 'default' loaded.
R_LoadProgram: 'warp' loaded.
SDL_ttf version 2.0.9 - we need at least 2.0.7
------- sound initialization -------
SDL_mixer version: 1.2.8
... audio rate: 44100
... audio channels: 2
... driver: 'coreaudio'
... channels to mix sounds: 8
------- input initialization -------
0 possible joysticks
no joystick found.
----------- parse scripts ----------
Shared Client/Server Info loaded
...110 items parsed
... 32 damage types parsed
... 67 map definitions parsed
... 29 equipment definitions parsed
... 10 inventory definitions parsed
... 22 team definitions parsed
music change to van_theme (from PsymongN3)
S_Music_Start: Playing music: 'music/van_theme'
R_RegisterModelShort: Could not find: 'weapons/autocannon/autocannon'
CL_LanguageInit: language settings are stored in configuration: en
...using language: en_US.UTF-8
SDL_ttf version 2.0.9 - we need at least 2.0.7
...registering 10 fonts
126 static models loaded
====== UFO Initialized ======

Switch grab input off
music change to van_theme (from van_theme)
music change to van_theme (from van_theme)
music change to van_theme (from van_theme)
Unknown command "mn_textupdated" - wasn't sent to server
music change to van_theme (from van_theme)
music change to van_theme (from van_theme)
music change to van_theme (from van_theme)
music change to van_theme (from van_theme)
music change to van_theme (from van_theme)
r
Unknown command "r" - wasn't sent to server
`
Unknown command "`" - wasn't sent to server
vvvv
Unknown command "vvvv" - wasn't sent to server
cv
Unknown command "cv" - wasn't sent to server
r_program
Unknown command "r_program" - wasn't sent to server
r_programs
"r_programs" is "1"
r_programs 0
r_error
Unknown command "r_error" - wasn't sent to server
r_chkerror
Unknown command "r_chkerror" - wasn't sent to server
r_checkerror
"r_checkerror" is "0"
r_checkerror 1
Change gametype to 'Skirmish mode'
Could not find rank 'rifleman'
Could not find rank 'rifleman'
Could not find rank 'rifleman'
Could not find rank 'rifleman'
Could not find rank 'rifleman'
Could not find rank 'rifleman'
Could not find rank 'rifleman'
Could not find rank 'rifleman'
------- Loading game.dylib -------
LoadLibrary (./base/game.dylib)
==== InitGame ====
Map:wilderness  Offset:(0, 0, 0)
wpMins:(128, 118, 0) wpMaxs:(193, 197, 7)
Shifted wpMins:(128, 118, 0) wpMaxs:(193, 197, 7)
Tile bounds: (128, 118, 0) to (193, 197, 7)
Source bounds: (128, 118, 0) to (193, 197, 7)
Done copying data.
Wrote keys.cfg
Title: Re: Log of an attempt to compile a universal binary for 10.5.6 for 2.3-dev (trunk)
Post by: keybounce on March 20, 2009, 08:18:23 pm
Here's a full backtrace.

Kleiman-ibook:trunk michael$ gdb ufo
GNU gdb 6.3.50-20050815 (Apple version gdb-962) (Sat Jul 26 08:17:57 UTC 2008)
Copyright 2004 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "powerpc-apple-darwin"...Reading symbols for shared libraries .................... done

(gdb) run
Starting program: /Users/michael/development/ufoai/trunk/ufo
Reading symbols for shared libraries +++++++++++++++++++.............................................................................. done
Reading symbols for shared libraries . done

---- filesystem initialization -----
Adding game dir: /usr/local/lib/ufoai/base
Adding game dir: /usr/local/share/ufoai/base
Adding game dir: ./base
Added packfile ./base/0base.pk3 (16 files)
Added packfile ./base/0maps.pk3 (390 files)
Added packfile ./base/0materials.pk3 (33 files)
Added packfile ./base/0media.pk3 (10 files)
Added packfile ./base/0models.pk3 (1444 files)
Added packfile ./base/0music.pk3 (40 files)
Added packfile ./base/0pics.pk3 (2035 files)
Added packfile ./base/0snd.pk3 (177 files)
Added packfile ./base/0ufos.pk3 (90 files)
Adding game dir: /Users/michael/.ufoai/2.3-dev/base
using /Users/michael/.ufoai/2.3-dev/base for writing
executing default.cfg
executing config.cfg
executing keys.cfg

----- network initialization -------
libcurl/7.16.3 OpenSSL/0.9.7l zlib/1.2.3 initialized.

------ server initialization -------
added 7 maps to the mapcycle

----- console initialization -------
Console initialized.

------- video initialization -------
Reading symbols for shared libraries . done
Reading symbols for shared libraries . done
Reading symbols for shared libraries . done
SDL version: 1.2.13
I: desktop depth: 32bpp
I: video memory: 0
I: video driver: Quartz
I: setting mode 5: 960x720 (fullscreen: no)
I: set swap control to 0
Reading symbols for shared libraries . done
Reading symbols for shared libraries . done
Reading symbols for shared libraries . done
Reading symbols for shared libraries . done
I: got 8 bits of stencil
I: got 24 bits of depth buffer
I: got double buffer
I: got 8 bits for red
I: got 8 bits for green
I: got 8 bits for blue
I: got 8 bits for alpha
I: got 0 multisample buffers
GL_VENDOR: ATI Technologies Inc.
GL_RENDERER: ATI Radeon 9550 OpenGL Engine
GL_VERSION: 2.0 ATI-1.5.36
GL_EXTENSIONS: GL_ARB_transpose_matrix GL_ARB_vertex_program GL_ARB_vertex_blend GL_ARB_window_pos GL_ARB_shader_objects GL_ARB_vertex_shader GL_ARB_shading_language_100 GL_EXT_multi_draw_arrays GL_EXT_clip_volume_hint GL_EXT_rescale_normal GL_EXT_draw_range_elements GL_EXT_fog_coord GL_EXT_gpu_program_parameters GL_EXT_geometry_shader4 GL_EXT_transform_feedback GL_APPLE_client_storage GL_APPLE_specular_vector GL_APPLE_transform_hint GL_APPLE_packed_pixels GL_APPLE_fence GL_APPLE_vertex_array_object GL_APPLE_vertex_program_evaluators GL_APPLE_element_array GL_APPLE_flush_render GL_APPLE_aux_depth_stencil GL_NV_texgen_reflection GL_NV_light_max_exponent GL_IBM_rasterpos_clip GL_SGIS_generate_mipmap GL_ARB_imaging GL_ARB_point_parameters GL_ARB_texture_env_crossbar GL_ARB_texture_border_clamp GL_ARB_multitexture GL_ARB_texture_env_add GL_ARB_texture_cube_map GL_ARB_texture_env_dot3 GL_ARB_multisample GL_ARB_texture_env_combine GL_ARB_texture_compression GL_ARB_texture_mirrored_repeat GL_ARB_shadow GL_ARB_depth_texture GL_ARB_shadow_ambient GL_ARB_fragment_program GL_ARB_fragment_program_shadow GL_ARB_fragment_shader GL_ARB_occlusion_query GL_ARB_point_sprite GL_ARB_texture_non_power_of_two GL_ARB_vertex_buffer_object GL_ARB_pixel_buffer_object GL_ARB_draw_buffers GL_EXT_compiled_vertex_array GL_EXT_framebuffer_object GL_EXT_texture_rectangle GL_ARB_texture_rectangle GL_EXT_texture_env_add GL_EXT_blend_color GL_EXT_blend_minmax GL_EXT_blend_subtract GL_EXT_texture_lod_bias GL_EXT_abgr GL_EXT_bgra GL_EXT_stencil_wrap GL_EXT_texture_filter_anisotropic GL_EXT_separate_specular_color GL_EXT_secondary_color GL_EXT_blend_func_separate GL_EXT_shadow_funcs GL_EXT_texture_compression_s3tc GL_EXT_texture_compression_dxt1 GL_EXT_texture_sRGB GL_EXT_blend_equation_separate GL_EXT_texture_mirror_clamp GL_EXT_packed_depth_stencil GL_APPLE_flush_buffer_range GL_APPLE_ycbcr_422 GL_APPLE_vertex_array_range GL_APPLE_texture_range GL_APPLE_float_pixels GL_ATI_texture_float GL_ARB_texture_float GL_ARB_half_float_pixel GL_APPLE_pixel_buffer GL_APPLE_object_purgeable GL_NV_blend_square GL_NV_fog_distance GL_ATI_texture_mirror_once GL_ATI_text_fragment_shader GL_ATI_blend_equation_separate GL_ATI_blend_weighted_minmax GL_ATI_texture_env_combine3 GL_ATI_separate_stencil GL_SGIS_texture_edge_clamp GL_SGIS_texture_lod GL_SGI_color_matrix
max texture units: 8
max texture size: detected 2048
R_LoadProgram: 'default' loaded.
R_LoadProgram: 'warp' loaded.
SDL_ttf version 2.0.9 - we need at least 2.0.7

------- sound initialization -------
SDL_mixer version: 1.2.8
Reading symbols for shared libraries . done
Reading symbols for shared libraries . done
Reading symbols for shared libraries . done
Reading symbols for shared libraries . done
Reading symbols for shared libraries . done
... audio rate: 44100
... audio channels: 2
... driver: 'coreaudio'
... channels to mix sounds: 8
Reading symbols for shared libraries warning: Could not find object file "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_audio_libvorbis/work/libvorbis-1.2.0/lib/.libs/vorbisfile.o" - no debug information available for "vorbisfile.c".

.warning: Could not find object file "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_audio_libvorbis/work/libvorbis-1.2.0/lib/.libs/mdct.o" - no debug information available for "mdct.c".

...

warning: Could not find object file "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_audio_libvorbis/work/libvorbis-1.2.0/lib/.libs/bitrate.o" - no debug information available for "bitrate.c".

.. done
Reading symbols for shared libraries warning: Could not find object file "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_audio_libvorbis/work/libvorbis-1.2.0/lib/.libs/vorbisfile.o" - no debug information available for "vorbisfile.c".

.warning: Could not find object file "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_audio_libvorbis/work/libvorbis-1.2.0/lib/.libs/mdct.o" - no debug information available for "mdct.c".

...

warning: Could not find object file "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_audio_libvorbis/work/libvorbis-1.2.0/lib/.libs/bitrate.o" - no debug information available for "bitrate.c".

.. done
Reading symbols for shared libraries warning: Could not find object file "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_audio_libvorbis/work/libvorbis-1.2.0/lib/.libs/vorbisfile.o" - no debug information available for "vorbisfile.c".

.warning: Could not find object file "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_audio_libvorbis/work/libvorbis-1.2.0/lib/.libs/mdct.o" - no debug information available for "mdct.c".

...

warning: Could not find object file "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_audio_libvorbis/work/libvorbis-1.2.0/lib/.libs/bitrate.o" - no debug information available for "bitrate.c".

.. done

------- input initialization -------
Reading symbols for shared libraries . done
0 possible joysticks
no joystick found.

----------- parse scripts ----------
Shared Client/Server Info loaded
...110 items parsed
... 32 damage types parsed
... 67 map definitions parsed
... 29 equipment definitions parsed
... 10 inventory definitions parsed
... 22 team definitions parsed
music change to van_theme (from PsymongN3)
executing autoexec.cfg
"version" is "UFO: Alien Invasion 2.3-dev Unknown Mar 19 2009 MacOSX DEBUG"
Reading symbols for shared libraries warning: Could not find object file "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_audio_libvorbis/work/libvorbis-1.2.0/lib/.libs/vorbisfile.o" - no debug information available for "vorbisfile.c".

.warning: Could not find object file "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_audio_libvorbis/work/libvorbis-1.2.0/lib/.libs/mdct.o" - no debug information available for "mdct.c".

...

warning: Could not find object file "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_audio_libvorbis/work/libvorbis-1.2.0/lib/.libs/bitrate.o" - no debug information available for "bitrate.c".

.. done
S_Music_Start: Playing music: 'music/van_theme'
R_RegisterModelShort: Could not find: 'weapons/autocannon/autocannon'
CL_LanguageInit: language settings are stored in configuration: en
...using language: en_US.UTF-8
SDL_ttf version 2.0.9 - we need at least 2.0.7
...registering 10 fonts
126 static models loaded
====== UFO Initialized ======

Switch grab input off
Reading symbols for shared libraries .. done
Reading symbols for shared libraries . done
Change gametype to 'Skirmish mode'
Could not find rank 'rifleman'
Could not find rank 'rifleman'
Could not find rank 'rifleman'
Could not find rank 'rifleman'
Could not find rank 'rifleman'
Could not find rank 'rifleman'
Could not find rank 'rifleman'
Could not find rank 'rifleman'
------- Loading game.dylib -------
Reading symbols for shared libraries . done
LoadLibrary (./base/game.dylib)
==== InitGame ====
Map:wilderness  Offset:(0, 0, 0)
wpMins:(128, 118, 0) wpMaxs:(193, 197, 7)
Shifted wpMins:(128, 118, 0) wpMaxs:(193, 197, 7)
Tile bounds: (128, 118, 0) to (193, 197, 7)
Source bounds: (128, 118, 0) to (193, 197, 7)
Done copying data.

Program received signal EXC_BAD_ACCESS, Could not access memory.
Reason: KERN_INVALID_ADDRESS at address: 0x3964f02c
0x001473cc in TR_TestBoxInBrush (trace_data=0xbfffa3bc, brush=0x1062e7bc) at src/common/tracing.c:800
800         plane = side->plane;
(gdb) bt
#0  0x001473cc in TR_TestBoxInBrush (trace_data=0xbfffa3bc, brush=0x1062e7bc) at src/common/tracing.c:800
#1  0x001479a4 in TR_TestInLeaf (trace_data=0xbfffa3bc, leafnum=11) at src/common/tracing.c:900
#2  0x00148694 in TR_BoxTrace (tile=0x5bfbf54, start=0xbfffba10, end=0xbfffba10, mins=0xbfffb9f8, maxs=0xbfffba04, headnode=0, brushmask=-1, brushreject=0, fraction=2) at src/common/tracing.c:1106
#3  0x00148fa4 in TR_TileBoxTrace (myTile=0x5bfbf54, start=0xbfffba10, end=0xbfffba10, mins=0xbfffb9f8, maxs=0xbfffba04, levelmask=511, brushmask=-1, brushreject=0, fraction=2) at src/common/tracing.c:1238
#4  0x00149760 in TR_CompleteBoxTrace (start=0xbfffba10, end=0xbfffba10, mins=0xbfffb9f8, maxs=0xbfffba04, levelmask=511, brushmask=-1, brushreject=0) at src/common/tracing.c:1321
#5  0x0011c7f8 in CM_EntCompleteBoxTrace (start=0xbfffba10, end=0xbfffba10, mins=0xbfffb9f8, maxs=0xbfffba04, levelmask=511, brushmask=-1, brushreject=0) at src/common/cmodel.c:710
#6  0x0014a5cc in RT_GetMapSize (map_min=0x4431014, map_max=0x4431008) at src/common/routing.c:177
#7  0x0011dd2c in CMod_LoadRouting (name=0xbfffbde0 "wilderness", l=0xbfffbce8, sX=0, sY=0, sZ=0) at src/common/cmodel.c:884
#8  0x0011e904 in CM_AddMapTile (name=0xbfffbde0 "wilderness", day=qtrue, sX=0, sY=0, sZ=0 '\0') at src/common/cmodel.c:1076
#9  0x0011f488 in CM_LoadMap (tiles=0xbfffbf9a "", day=qtrue, pos=0x0, mapchecksum=0xbfffbed0) at src/common/cmodel.c:1227
#10 0x00156e1c in SV_SpawnServer (day=qtrue, server=0xbfffbf90 "wilderness", param=0x0) at src/server/sv_init.c:1111
#11 0x00157450 in SV_Map (day=qtrue, levelstring=0xbfffbf90 "wilderness", assembly=0x0) at src/server/sv_init.c:1224
#12 0x00151024 in SV_Map_f () at src/server/sv_ccmds.c:187
#13 0x00116168 in Cmd_ExecuteString (text=0xbffff254 "map day wilderness ") at src/common/cmd.c:912
#14 0x0011465c in Cbuf_Execute () at src/common/cmd.c:229
#15 0x000362f8 in CL_SendCommand () at src/client/cl_main.c:931
#16 0x00036b64 in CL_Frame (now=280893, data=0x0) at src/client/cl_main.c:1111
#17 0x00127974 in tick_timer (now=280893, data=0x183a0c1c) at src/common/common.c:1084
#18 0x00127d98 in Qcommon_Frame () at src/common/common.c:1165
#19 0x0019bcc8 in main (argc=1, argv=0xbffff8ac) at src/ports/macosx/osx_main.m:142
(gdb)


Map was compiled locally as
 2022  ./ufo2map maps/wilderness.map
without a "make pk3" afterwards.

(However, the version of the map used before that, and in the .pk3, was from map-get and was flagged as the wrong version -- so I think the right file got used.)

Version 23615
Title: Re: Log of an attempt to compile a universal binary for 10.5.6 for 2.3-dev (trunk)
Post by: keybounce on March 21, 2009, 06:20:45 am
I am the first to admit that I do not know what to look for. But, playing around with GDB, I found something that looks interesting.

It looks like the map data is being generated bad.
Code: [Select]
(gdb) down
#0  0x00147458 in TR_TestBoxInBrush (trace_data=0xbfffa3bc, brush=0x1062e9bc) at src/common/tracing.c:800
800 plane = side->plane;
(gdb) down
Bottom (i.e., innermost) frame selected; you cannot go down.
(gdb) list
795 return;
796
797 for (i = 0; i < brush->numsides; i++) {
798 side = &myTile->brushsides[brush->firstbrushside + i];
799 #ifdef COMPILE_UFO
800 plane = side->plane;
801 #else
802 plane = myTile->planes + side->planenum;
803 #endif
804
(gdb) p i
$15 = 0
(gdb) p side
$16 = (cBspBrushSide_t *) 0x3a8ab02c
(gdb) p *side
Cannot access memory at address 0x3a8ab02c

(gdb) p *brush
$17 = {
  contentFlags = 16777216,
  numsides = 134217728,
  firstbrushside = 571998208,
  checkcount = 1
}

(gdb) up
#1  0x00147a30 in TR_TestInLeaf (trace_data=0xbfffa3bc, leafnum=11) at src/common/tracing.c:900
900 TR_TestBoxInBrush(trace_data, b);
(gdb) list
895 continue; /* already checked this brush in another leaf */
896 b->checkcount = checkcount;
897
898 if (!(trace_data->contents && b->contentFlags & trace_data->contents) || (b->contentFlags & trace_data->rejects))
899 continue;
900 TR_TestBoxInBrush(trace_data, b);
901 if (!trace_data->trace.fraction)
902 return;
903 }
904 }
(gdb) p b
$18 = (cBspBrush_t *) 0x1062e9bc
(gdb) p *b
$19 = {
  contentFlags = 16777216,
  numsides = 134217728,
  firstbrushside = 571998208,
  checkcount = 1
}

877 static void TR_TestInLeaf (boxtrace_t *trace_data, int leafnum)
878 {
879 int k;
880 const TR_LEAF_TYPE *leaf;
881 TR_TILE_TYPE *myTile = trace_data->tile;
882
883 assert(leafnum > LEAFNODE);
884 assert(leafnum <= myTile->numleafs);
(gdb)
885
886 leaf = &myTile->leafs[leafnum];
887 if (!(leaf->contentFlags & trace_data->contents) || (leaf->contentFlags & trace_data->rejects))
888 return;
889
890 /* trace line against all brushes in the leaf */
891 for (k = 0; k < leaf->numleafbrushes; k++) {
892 const int brushnum = myTile->leafbrushes[leaf->firstleafbrush + k];
893 cBspBrush_t *b = &myTile->brushes[brushnum];
894 if (b->checkcount == checkcount)
(gdb) p brushnum
$20 = 537
(gdb) p leaf
$21 = (const cBspLeaf_t *) 0x29c6f084
(gdb) p *leaf
$22 = {
  contentFlags = 1,
  firstleafbrush = 2,
  numleafbrushes = 1
}

Leaf looks good, but brushnum looks bad. So part of trace_data looks good, and part of it scrambled.

(gdb) p myTile
$23 = (mapTile_t *) 0x5bfbf54
(gdb) p *myTile
$24 = {
  name = "wilderness", '\0' <repeats 53 times>,
  numbrushsides = 8155,
  brushsides = 0x29cab02c,
  numtexinfo = 1767,
  surfaces = 0x29c4e02c,
  numplanes = 9290,
  planes = 0x29c7d02c,
  numnodes = 6939,
  nodes = 0x29cbb02c,
  numleafs = 6946,
  leafs = 0x29c6f02c,
  emptyleaf = 1,
  numleafbrushes = 2598,
  leafbrushes = 0x1062b22c,
  nummodels = 258,
  models = 0x2950902c,
  numbrushes = 732,
  brushes = 0x1062c82c,
  box_planes = 0x29caa5f4,
  box_headnode = 6939,
  box_brush = 0x1062f5ec,
  box_leaf = 0x29c7c93c,
  tnodes = 0x29cf902c,
  numtheads = 6,
  thead = {0, 24, 920, 1680, 6412, 6478, 0 <repeats 252 times>},
  theadlevel = {0 <repeats 258 times>},
  numcheads = 153,
  cheads = {{
      cnode = 0,
      level = 0
    }, {
      cnode = 17,
      level = 0
    }, {
      cnode = 24,
      level = 252
    }, {
      cnode = 157,
      level = 252
    }, {
      cnode = 331,
      level = 252
    }, {
      cnode = 361,
      level = 252
    }, {
... snip ...
    }, {
      cnode = 6922,
      level = 257
    }, {
      cnode = 6928,
      level = 257
    }, {
      cnode = 0,
      level = 0
    } <repeats 65383 times>},
  wpMins = {128, 118, 0},
  wpMaxs = {193, 197, 7}
}

There's enough obvious meaningful information in there that I don't suspect an invalid pointer, but some of the data in there is invalid -- it's crashing in the next subroutine down.

(gdb) p k
$25 = 0
(gdb) p leafnum
$26 = 11
(gdb) p leaf
$27 = (const cBspLeaf_t *) 0x29c6f084
(gdb) p *leaf
$28 = {
  contentFlags = 1,
  firstleafbrush = 2,
  numleafbrushes = 1
}
(gdb) p brushnum
$29 = 537

Looks a little high

Some earlier looking around:

(gdb) up
#2  0x00148720 in TR_BoxTrace (tile=0x5bfbf54, start=0xbfffba10, end=0xbfffba10, mins=0xbfffb9f8, maxs=0xbfffba04, headnode=0, brushmask=-1, brushreject=0, fraction=2) at src/common/tracing.c:1106
1106 TR_TestInLeaf(&trace_data, leafs[i]);
(gdb) list
1101 c2[i] += 1;
1102 }
1103
1104 numleafs = TR_BoxLeafnums_headnode(&trace_data, c1, c2, leafs, MAX_LEAFS, headnode, &topnode);
1105 for (i = 0; i < numleafs; i++) {
1106 TR_TestInLeaf(&trace_data, leafs[i]);
1107 if (trace_data.trace.allsolid)
1108 break;
1109 }
1110 VectorCopy(start, trace_data.trace.endpos);
(gdb) p i
$12 = 4
(gdb) p numleafs
$13 = 11
(gdb) p leafs
$14 = {1, 6, 8, 10, 11, 12, 13, 14, 15, 17, 18, 0, 0, 0, 0, -- snip --
Numleafs looks good, and this isn't the first time through the loop. So the data seems to be partially valid, and partially invalid.

As a side note: Do not use "i" as an array subscript. Reason: The notation "[ i ]" in code triggers bbcode ...
Title: Re: Log of an attempt to compile a universal binary for 10.5.6 for 2.3-dev (trunk)
Post by: Mattn on March 21, 2009, 08:03:29 am
the brush num doesn't look bad - i mean 537 isn't really that high.

if you activate the developer mode (developer cvar to 1) you can see how many nodes, leafs brushes and so on are loaded on map start. please try to compare them with the numsides, numbrushes, numleafs and so on. i had a look too, and i can't find any missing endian swap for the bsp data. maybe there is some memory corruption. did you ever use valgrind (is it even available for macosx?). if you could run it in valgrind (execute ./contrib/scritps/valgrind.sh ufo from trunk/), please send the output (but be warned, it's damn slow in valgrind ;))

did you compile the wilderness map yourself?
Title: Re: Log of an attempt to compile a universal binary for 10.5.6 for 2.3-dev (trunk)
Post by: keybounce on March 21, 2009, 04:51:04 pm
Valgrind turned out to be real fast:
Kleiman-ibook:trunk michael$ ./contrib/scripts/valgrind.sh ufo
readlink: illegal option -- f
usage: readlink [-n] [file ...]
 is no executable
Kleiman-ibook:trunk michael$

Kleiman-ibook:trunk michael$ valgrind
-bash: valgrind: command not found
Kleiman-ibook:trunk michael$ man valgrind
No manual entry for valgrind

I don't think it's there.

Yes, I compiled wilderness myself.
===

Now a question on "make maps" versus "./ufo2map". "Make maps" normally adds in "-extra", and we were told by another mac developer that it takes about 5 days. I have used ./ufo2map, without -extra; when I removed that from the makefile, it only took overnight.

I'm going to try a map with -extra, and see what that's like.
Title: Re: Log of an attempt to compile a universal binary for 10.5.6 for 2.3-dev (trunk)
Post by: keybounce on March 21, 2009, 06:09:02 pm
I think something got missed on a recent check-in:

This is from a make clean.

...
 * [GAM] src/game/lua/lvm.c
 * [GAM] src/game/lua/lzio.c
 * [GAM] src/game/lua/print.c
 * [GAM] ... linking -rdynamic ()
Undefined symbols:
  "_AI_Cleanup", referenced from:
      _G_EndGame in g_main.o
ld: symbol(s) not found
collect2: ld returned 1 exit status
Undefined symbols:
  "_AI_Cleanup", referenced from:
      _G_EndGame in g_main.o
ld: symbol(s) not found
collect2: ld returned 1 exit status
lipo: can't open input file: /var/folders/rE/rEdMXgrOG7WDErrJmyTTEE+++TM/-Tmp-//ccYDb4iZ.out (No such file or directory)
make: *** [base/game.dylib] Error 1
Kleiman-ibook:trunk michael$ svn up
At revision 23625.
Kleiman-ibook:trunk michael$
Title: Re: Log of an attempt to compile a universal binary for 10.5.6 for 2.3-dev (trunk)
Post by: keybounce on March 21, 2009, 07:57:18 pm
Alright, if you can tell me what to look for, I can provide you with any information you want. I've got a null pointer dereference right now.

Svn: 23627.
All maps compiled locally.
"Wilderness" compiled with -extra

Currently sitting there in GDB, waiting for instructions.
Code: [Select]
.. done
S_Music_Start: Playing music: 'music/van_theme'
R_RegisterModelShort: Could not find: 'weapons/autocannon/autocannon'
CL_LanguageInit: language settings are stored in configuration: en
...using language: en_US.UTF-8
SDL_ttf version 2.0.9 - we need at least 2.0.7
...registering 10 fonts
126 static models loaded
====== UFO Initialized ======

Switch grab input off
Reading symbols for shared libraries .. done
Reading symbols for shared libraries . done
r console
Unknown command "r" - wasn't sent to server
r_checkerror 1
r_programs 0
r_developer 1
Unknown command "r_developer" - wasn't sent to server
developer 1
^C
Program received signal SIGINT, Interrupt.
0x92f17d20 in select$DARWIN_EXTSN ()
(gdb) break CM_AddMapTile
Breakpoint 1 at 0x11f26c: file src/common/cmodel.c, line 1033.
(gdb) c
Continuing.
ExecuteString: '+leftmouse 200 626573'
ExecuteString: 'mn_push singleplayer'
ExecuteString: ''
ExecuteString: '-leftmouse 200 626747'
ExecuteString: '-select 200 626747'
ExecuteString: '+leftmouse 200 641034'
ExecuteString: 'mn_push skirmish'
ExecuteString: ''
ExecuteString: 'game_setmode'
Change gametype to 'Skirmish mode'
ExecuteString: 'set ai_numaliens 8'
ExecuteString: 'set difficulty 0'
ExecuteString: ''
ExecuteString: 'set mn_serverday 1'
ExecuteString: 'mn_getmaps'
ExecuteString: ''
ExecuteString: '-leftmouse 200 641546'
ExecuteString: '-select 200 641546'
ExecuteString: '+leftmouse 200 645356'
ExecuteString: 'mn_prevmap'
ExecuteString: ''
ExecuteString: '-leftmouse 200 645490'
ExecuteString: '-select 200 645490'
ExecuteString: '+leftmouse 200 650140'
ExecuteString: 'sk_start'
Could not find rank 'rifleman'
No valid name definitions for gender 0 in category 'phalanx'
Could not find rank 'rifleman'
Could not find rank 'rifleman'
Could not find rank 'rifleman'
Could not find rank 'rifleman'
No valid name definitions for gender 0 in category 'phalanx'
Could not find rank 'rifleman'
Could not find rank 'rifleman'
Could not find rank 'rifleman'
No valid name definitions for gender 0 in category 'phalanx'
ExecuteString: ''
ExecuteString: 'map day wilderness '
Set server state to 0
------- Loading game.dylib -------
Reading symbols for shared libraries . done
LoadLibrary (./base/game.dylib)
==== InitGame ====
SpawnServer: wilderness
Set server state to 0
CM_LoadMap: token: wilderness

Breakpoint 1, 0x0011f26c in CM_AddMapTile (name=0xbfffbde0 "wilderness", day=qtrue, sX=0, sY=0, sZ=0 '\0') at src/common/cmodel.c:1033
1033 {
(gdb) # First call
Current language:  auto; currently c
(gdb) c
Continuing.
CM_AddMapTile: wilderness at 0,0,0
...surfaces: 1767
...leafs: 6946
...leafbrushes: 2598
...planes: 9290
...brushes: 732
...brushsides: 8155
...submodels: 258
...nodes: 6939
Map:wilderness  Offset:(0, 0, 0)
wpMins:(128, 118, 0) wpMaxs:(193, 197, 7)
Shifted wpMins:(128, 118, 0) wpMaxs:(193, 197, 7)
Tile bounds: (128, 118, 0) to (193, 197, 7)
Source bounds: (128, 118, 0) to (193, 197, 7)
Done copying data.

Program received signal EXC_BAD_ACCESS, Could not access memory.
Reason: KERN_PROTECTION_FAILURE at address: 0x00000000
0x0014839c in TR_TestBoxInBrush (trace_data=0xbfffa3bc, brush=0x10613dbc) at src/common/tracing.c:808
808 if (plane->normal[j] < 0)
(gdb) p j
$1 = 0
(gdb) p plane
$2 = (cBspPlane_t *) 0x0
(gdb) bt
#0  0x0014839c in TR_TestBoxInBrush (trace_data=0xbfffa3bc, brush=0x10613dbc) at src/common/tracing.c:808
#1  0x00148950 in TR_TestInLeaf (trace_data=0xbfffa3bc, leafnum=11) at src/common/tracing.c:899
#2  0x00149640 in TR_BoxTrace (tile=0x5bfcf54, start=0xbfffba10, end=0xbfffba10, mins=0xbfffb9f8, maxs=0xbfffba04, headnode=0, brushmask=-1, brushreject=0, fraction=2) at src/common/tracing.c:1105
#3  0x00149f50 in TR_TileBoxTrace (myTile=0x5bfcf54, start=0xbfffba10, end=0xbfffba10, mins=0xbfffb9f8, maxs=0xbfffba04, levelmask=511, brushmask=-1, brushreject=0, fraction=2) at src/common/tracing.c:1237
#4  0x0014a70c in TR_CompleteBoxTrace (start=0xbfffba10, end=0xbfffba10, mins=0xbfffb9f8, maxs=0xbfffba04, levelmask=511, brushmask=-1, brushreject=0) at src/common/tracing.c:1319
#5  0x0011d7a4 in CM_EntCompleteBoxTrace (start=0xbfffba10, end=0xbfffba10, mins=0xbfffb9f8, maxs=0xbfffba04, levelmask=511, brushmask=-1, brushreject=0) at src/common/cmodel.c:741
#6  0x0014b578 in RT_GetMapSize (map_min=0x4432014, map_max=0x4432008) at src/common/routing.c:177
#7  0x0011ecd8 in CMod_LoadRouting (name=0xbfffbde0 "wilderness", l=0xbfffbce8, sX=0, sY=0, sZ=0) at src/common/cmodel.c:915
#8  0x0011f8b0 in CM_AddMapTile (name=0xbfffbde0 "wilderness", day=qtrue, sX=0, sY=0, sZ=0 '\0') at src/common/cmodel.c:1107
#9  0x00120434 in CM_LoadMap (tiles=0xbfffbf9a "", day=qtrue, pos=0x0, mapchecksum=0xbfffbed0) at src/common/cmodel.c:1258
#10 0x00157dc8 in SV_SpawnServer (day=qtrue, server=0xbfffbf90 "wilderness", param=0x0) at src/server/sv_init.c:1111
#11 0x001583fc in SV_Map (day=qtrue, levelstring=0xbfffbf90 "wilderness", assembly=0x0) at src/server/sv_init.c:1224
#12 0x00151fd0 in SV_Map_f () at src/server/sv_ccmds.c:187
#13 0x00116d58 in Cmd_ExecuteString (text=0xbffff254 "map day wilderness ") at src/common/cmd.c:912
#14 0x0011524c in Cbuf_Execute () at src/common/cmd.c:229
#15 0x00036f28 in CL_SendCommand () at src/client/cl_main.c:931
#16 0x00037794 in CL_Frame (now=650140, data=0x0) at src/client/cl_main.c:1111
#17 0x00128920 in tick_timer (now=650140, data=0x183a071c) at src/common/common.c:1084
#18 0x00128d44 in Qcommon_Frame () at src/common/common.c:1165
#19 0x0019ccd8 in main (argc=1, argv=0xbffff8ac) at src/ports/macosx/osx_main.m:142
(gdb)
Title: Re: Log of an attempt to compile a universal binary for 10.5.6 for 2.3-dev (trunk)
Post by: keybounce on March 21, 2009, 08:17:48 pm
I'd like help understanding "numTiles" in the file src/common/cmodel.c

As far as I can tell, this is a global that counts the current tile being loaded into the map.

It is initialized to zero in CM_LoadMap.
It gets incremented in CM_AddMapTile
It is increased just before calling CMod_LoadRouting
It is down in CMod_LoadRouting that I'm crashing.

Is this a trivial "Oppsie", or am I looking at the wrong thing?
Title: Re: Log of an attempt to compile a universal binary for 10.5.6 for 2.3-dev (trunk)
Post by: keybounce on March 21, 2009, 11:46:32 pm
Ok, I really think this is a bug.


As mentioned, AddMapTile increments numTiles and then makes these calls:

Stack trace:
Code: [Select]
#8  0x0011f8b0 in CM_AddMapTile (name=0xbfffbde0 "wilderness", day=qtrue, sX=0, sY=0, sZ=0 '\0') at src/common/cmodel.c:1107
1107 CMod_LoadRouting(name, &header.lumps[LUMP_ROUTING], sX, sY, sZ);
(gdb) down
#7  0x0011ecd8 in CMod_LoadRouting (name=0xbfffbde0 "wilderness", l=0xbfffbce8, sX=0, sY=0, sZ=0) at src/common/cmodel.c:915
915 RT_GetMapSize(map_min, map_max);
(gdb) down
#6  0x0014b578 in RT_GetMapSize (map_min=0x4432014, map_max=0x4432008) at src/common/routing.c:177
177 trace = RT_COMPLETEBOXTRACE(origin, origin, mins, maxs, 0x1FF, MASK_ALL, 0);
(gdb) down
#5  0x0011d7a4 in CM_EntCompleteBoxTrace (start=0xbfffba10, end=0xbfffba10, mins=0xbfffb9f8, maxs=0xbfffba04, levelmask=511, brushmask=-1, brushreject=0) at src/common/cmodel.c:741
741 trace = TR_CompleteBoxTrace(start, end, mins, maxs, levelmask, brushmask, brushreject);
(gdb) down
#4  0x0014a70c in TR_CompleteBoxTrace (start=0xbfffba10, end=0xbfffba10, mins=0xbfffb9f8, maxs=0xbfffba04, levelmask=511, brushmask=-1, brushreject=0) at src/common/tracing.c:1319
1319 newtr = TR_TileBoxTrace(myTile, start, end, mins, maxs, levelmask, brushmask, brushreject, tr.fraction);

At this point, we have this code:

Code: [Select]
1281 trace_t TR_CompleteBoxTrace (const vec3_t start, const vec3_t end, const vec3_t mins,
     const vec3_t maxs, const int levelmask, const int brushmask, const int brushreject)
1282 {
1283     trace_t newtr, tr;
1284     int tile, i;
1285     vec3_t smin, smax, emin, emax, wpmins, wpmaxs;
1286     const vec3_t offset = {UNIT_SIZE / 2, UNIT_SIZE / 2, UNIT_HEIGHT / 2};
1287
1288     memset(&tr, 0, sizeof(tr));
1289     tr.fraction = 2.0f;
1290
1291     /* Prep the mins and maxs */
1292     for (i = 0; i < 3; i++) {
1293         smin[i] = start[i] + min(mins[i], maxs[i]);
1294         smax[i] = start[i] + max(mins[i], maxs[i]);
1295         emin[i] = end[i] + min(mins[i], maxs[i]);
1296         emax[i] = end[i] + max(mins[i], maxs[i]);
1297     }
1298
1299     /* trace against all loaded map tiles */
1300     for (tile = 0; tile < numTiles; tile++) {

And we're looking one tile past anything that has been loaded.

Testing ...
Title: Re: Log of an attempt to compile a universal binary for 10.5.6 for 2.3-dev (trunk)
Post by: keybounce on March 22, 2009, 02:21:59 am
It got a lot farther.

Code: [Select]
====== UFO Initialized ======

Switch grab input off
developer 1
ExecuteString: '+leftmouse 200 81775'
ExecuteString: 'mn_push options'
ExecuteString: ''
ExecuteString: 'mn_init_keylist'
ExecuteString: 'mn_textupdated keylist'
Unknown command "mn_textupdated" - wasn't sent to server
ExecuteString: 'optionkey_count 0'
ExecuteString: ''
ExecuteString: '-leftmouse 200 81951'
ExecuteString: '-select 200 81951'
ExecuteString: '+leftmouse 200 86667'
ExecuteString: 'copy mn_vidmode vid_mode'
ExecuteString: ''
ExecuteString: '-leftmouse 200 86820'
ExecuteString: '-select 200 86820'
ExecuteString: '+leftmouse 200 90735'
ExecuteString: '-leftmouse 200 90905'
ExecuteString: '-select 200 90905'
ExecuteString: '+leftmouse 200 98807'
ExecuteString: 'mn_pop'
ExecuteString: ''
ExecuteString: '-leftmouse 200 98958'
ExecuteString: '-select 200 98958'
ExecuteString: 'toggleconsole'
ExecuteString: '-turnup 114 258507'
ExecuteString: '-hudradar 104 259605'
ExecuteString: '-turnup 114 261267'
ExecuteString: '-turnup 114 261457'
ExecuteString: '-turnup 114 261760'
r_checkerror 1
ExecuteString: 'r_checkerror 1'
ExecuteString: '-turnup 114 269564'
ExecuteString: '-turnup 114 275134'
ExecuteString: '-turnup 114 276309'
ExecuteString: '-shiftleft 97 276428'
ExecuteString: '-shiftdown 115 276754'
r_programs
ExecuteString: 'r_programs '
"r_programs" is "0"
ExecuteString: '-turnup 114 286054'
ExecuteString: '-turnup 114 286872'
ExecuteString: '-turnup 114 287434'
ExecuteString: '-shiftleft 97 287570'
ExecuteString: '-shiftdown 115 287931'
r_programs 1
ExecuteString: 'r_programs 1'
R_LoadProgram: 'default' loaded.
R_LoadProgram: 'warp' loaded.
ExecuteString: '-turnup 114 308121'
ExecuteString: '-turnup 114 309742'
ExecuteString: '-turnup 114 310329'
ExecuteString: '-shiftleft 97 310569'
ExecuteString: '-shiftdown 115 311208'
r_programs 0
ExecuteString: 'r_programs 0'
ExecuteString: '+leftmouse 200 326474'
ExecuteString: 'mn_push singleplayer'
ExecuteString: ''
ExecuteString: '-leftmouse 200 326620'
ExecuteString: '-select 200 326620'
ExecuteString: '+leftmouse 200 327685'
ExecuteString: 'mn_push skirmish'
ExecuteString: ''
ExecuteString: 'game_setmode'
Change gametype to 'Skirmish mode'
ExecuteString: 'set ai_numaliens 8'
ExecuteString: 'set difficulty 0'
ExecuteString: ''
ExecuteString: 'set mn_serverday 1'
ExecuteString: 'mn_getmaps'
ExecuteString: ''
ExecuteString: '-leftmouse 200 328351'
ExecuteString: '-select 200 328351'
ExecuteString: '+leftmouse 200 331987'
ExecuteString: 'mn_prevmap'
ExecuteString: ''
ExecuteString: '-leftmouse 200 332114'
ExecuteString: '-select 200 332114'
ExecuteString: '+leftmouse 200 334809'
ExecuteString: 'sk_start'
Could not find rank 'rifleman'
Could not find rank 'rifleman'
Could not find rank 'rifleman'
Could not find rank 'rifleman'
No valid name definitions for gender 0 in category 'phalanx'
Could not find rank 'rifleman'
Could not find rank 'rifleman'
Could not find rank 'rifleman'
Could not find rank 'rifleman'
ExecuteString: ''
ExecuteString: 'map day wilderness '
Set server state to 0
------- Loading game.dylib -------
LoadLibrary (./base/game.dylib)
==== InitGame ====
SpawnServer: wilderness
Set server state to 0
CM_LoadMap: token: wilderness
CM_AddMapTile: wilderness at 0,0,0
...surfaces: 1767
...leafs: 6946
...leafbrushes: 2598
...planes: 9290
...brushes: 732
...brushsides: 8155
...submodels: 258
...nodes: 6939
Map:wilderness  Offset:(0, 0, 0)
wpMins:(128, 118, 0) wpMaxs:(193, 197, 7)
Shifted wpMins:(128, 118, 0) wpMaxs:(193, 197, 7)
Tile bounds: (128, 118, 0) to (193, 197, 7)
Source bounds: (128, 118, 0) to (193, 197, 7)
Done copying data.
Loaded routing for tile wilderness in   0.0s
checksum for the map 'wilderness': 261412033
ufo script checksum 849594367
Set server state to 1
Entity:0 class:(null) key:classname
entity: model () num: 0 solid:0 mins: 0 0 0 maxs: 0 0 0 absmins: 0 0 0 absmaxs: 0 0 0 origin: 0 0 0
Entity:1 class:noclass key:angle
Entity:1 class:noclass key:origin
Entity:1 class:noclass key:classname
entity: model () num: 0 solid:0 mins: 0 0 0 maxs: 0 0 0 absmins: 0 0 0 absmaxs: 0 0 0 origin: 176 912 292
Entity:2 class:noclass key:model
Entity:2 class:noclass key:spawnflags
Entity:2 class:noclass key:origin
Entity:2 class:noclass key:classname
entity: model (models/aircraft/drop_firebird/firebird_top.md2) num: 0 solid:0 mins: 0 0 0 maxs: 0 0 0 absmins: 0 0 0 absmaxs: 0 0 0 origin: 448 2080 292
Entity:2 class:noclass key:model
Entity:2 class:noclass key:origin
Entity:2 class:noclass key:spawnflags
Entity:2 class:noclass key:classname
entity: model (models/aircraft/drop_firebird/firebird_glass.md2) num: 0 solid:0 mins: 0 0 0 maxs: 0 0 0 absmins: 0 0 0 absmaxs: 0 0 0 origin: 448 2080 292
Entity:2 class:noclass key:spawnflags
Entity:2 class:noclass key:model
Entity:2 class:noclass key:origin
Entity:2 class:noclass key:classname
entity: model (models/aircraft/drop_firebird/firebird.md2) num: 0 solid:0 mins: 0 0 0 maxs: 0 0 0 absmins: 0 0 0 absmaxs: 0 0 0 origin: 448 2080 292
Entity:2 class:noclass key:origin
Entity:2 class:noclass key:classname
entity: model () num: 0 solid:0 mins: 0 0 0 maxs: 0 0 0 absmins: 0 0 0 absmaxs: 0 0 0 origin: 304 1904 284
Entity:3 class:noclass key:team

... snip ...

Entity:19 class:noclass key:classname
entity: model () num: 0 solid:0 mins: 0 0 0 maxs: 0 0 0 absmins: 0 0 0 absmaxs: 0 0 0 origin: 2064 1520 92
Entity:20 class:noclass key:angles
Entity:20 class:noclass key:origin
Entity:20 class:noclass key:model
Entity:20 class:noclass key:spawnflags
Entity:20 class:noclass key:classname
entity: model (models/objects/vegi/tropic/tropic01.md2) num: 0 solid:0 mins: 0 0 0 maxs: 0 0 0 absmins: 0 0 0 absmaxs: 0 0 0 origin: 1862 1926 170
Entity:20 class:noclass key:spawnflags
Entity:20 class:noclass key:angle
Entity:20 class:noclass key:model
Entity:20 class:noclass key:origin
Entity:20 class:noclass key:classname
entity: model (models/objects/vegi/plants/plant_a.md2) num: 0 solid:0 mins: 0 0 0 maxs: 0 0 0 absmins: 0 0 0 absmaxs: 0 0 0 origin: 516 474 116
Entity:20 class:noclass key:modelscale_vec
ED_ParseField: modelscale_vec is not a valid field
Entity:20 class:noclass key:spawnflags
Entity:20 class:noclass key:model
Entity:20 class:noclass key:origin
Entity:20 class:noclass key:classname
entity: model (models/objects/vegi/plant/plant2.md2) num: 0 solid:0 mins: 0 0 0 maxs: 0 0 0 absmins: 0 0 0 absmaxs: 0 0 0 origin: 689 1232 222
Entity:20 class:noclass key:modelscale_vec
ED_ParseField: modelscale_vec is not a valid field
Entity:20 class:noclass key:skin
ED_ParseField: skin is not a valid field
Entity:20 class:noclass key:model
Entity:20 class:noclass key:origin
Entity:20 class:noclass key:spawnflags
Entity:20 class:noclass key:classname
entity: model (models/objects/vegi/fir/fir.md2) num: 0 solid:0 mins: 0 0 0 maxs: 0 0 0 absmins: 0 0 0 absmaxs: 0 0 0 origin: 1904 1072 90
Entity:20 class:noclass key:modelscale_vec
ED_ParseField: modelscale_vec is not a valid field
Entity:20 class:noclass key:angle
Entity:20 class:noclass key:model
Entity:20 class:noclass key:origin
Entity:20 class:noclass key:spawnflags
Entity:20 class:noclass key:classname
entity: model (models/objects/vegi/tree02/tree2_a.md2) num: 0 solid:0 mins: 0 0 0 maxs: 0 0 0 absmins: 0 0 0 absmaxs: 0 0 0 origin: 1744 944 88
Entity:20 class:noclass key:angle
Entity:20 class:noclass key:model
Entity:20 class:noclass key:origin

... massive snip ...

Entity:20 class:noclass key:classname
entity: model (models/objects/vegi/tree02/tree2_a.md2) num: 0 solid:0 mins: 0 0 0 maxs: 0 0 0 absmins: 0 0 0 absmaxs: 0 0 0 origin: 400 1232 216
Entity:20 class:noclass key:angles
Entity:20 class:noclass key:origin
Entity:20 class:noclass key:model
Entity:20 class:noclass key:spawnflags
Entity:20 class:noclass key:classname
entity: model (models/objects/vegi/tropic/tropic04.md2) num: 0 solid:0 mins: 0 0 0 maxs: 0 0 0 absmins: 0 0 0 absmaxs: 0 0 0 origin: 276 1218 236
Entity:20 class:noclass key:angle
Entity:20 class:noclass key:team
Entity:20 class:noclass key:origin
Entity:20 class:noclass key:classname
entity: model () num: 0 solid:0 mins: 0 0 0 maxs: 0 0 0 absmins: 0 0 0 absmaxs: 0 0 0 origin: 1904 272 76
Entity:20 class:noclass key:angle
Entity:20 class:noclass key:team
Entity:20 class:noclass key:origin
Eter
new event '12' for mask 0
new event '12' for mask 0
new event '12' for mask 0
new event '12' for mask 0
new event '12' for mask 0
new event '12' for mask 0
new event '12' for mask 0
new event '12' for mask 0
new event '22' for mask 0
new event '22' for mask 0
new event '22' for mask 0
new event '22' for mask 0
new event '22' for mask 0
new event '22' for mask 0
new event '22' for mask 0
new event '22' for mask 0
Created AI player (team 7)
0 groups with 0 entities
Set server state to 2
-------------------------------------
CL_SetClientState: Set new state to 3 (old was: 1)
s key:classname
entity: model (models/objects/vegi/water_lily/lily_leaf.md2) num: 0 solid:0 mins: 0 0 0 maxs: 0 0 0 absmins: 0 0 0 absmaxs: 0 0 0 origin: 1712 512 32
No civilian spawn points in this map or civilians deactivated
No valid name definitions for gender 2 in category 'ortnok'
No valid name definitions for gender 1 in category 'ortnok'
No valid name definitions for gender 2 in category 'ortnok'
No valid name definitions for gender 1 in category 'ortnok'
No valid name definitions for gender 2 in category 'ortnok'
No valid name definitions for gender 2 in category 'ortnok'
No valid name definitions for gender 2 in category 'ortnok'
No valid name definitions for gender 1 in category 'ortnok'
CHRSH_CharGetBody: use 'aliens/ortnok/body01' as body model path for character
CHRSH_CharGetBody: use 'aliens/ortnok/head02' as head model path for character
INVSH_EquipActor: no weapon picked in equipment 'multiplayer_alien', defaulting to the most expensive secondary weapon without reload.
No valid name definitions for gender 1 in category 'ortnok'
No valid name definitions for gender 1 in category 'ortnok'
CHRSH_CharGetBody: use 'aliens/ortnok/body01' as body model path for character
CHRSH_CharGetBody: use 'aliens/ortnok/head01' as head model path for character
INVSH_EquipActor: no weapon picked in equipment 'multiplayer_alien', defaulting to the most expensive secondary weapon without reload.

... snip ...

CHRSH_CharGetBody: use 'aliens/ortnok/body01' as body model path for character
CHRSH_CharGetBody: use 'aliens/ortnok/head01' as head model path for character
No valid name definitions for gender 2 in category 'ortnok'
CHRSH_CharGetBody: use 'aliens/ortnok/body01' as body model path for character
CHRSH_CharGetBody: use 'aliens/ortnok/head01' as head model path for charac2) num: 0 solid:0 mins: 0 0 0 maxs: 0 0 0 absmins: 0 0 0 absmaxs: 0 0 0 origin: 1712 480 32
Entity:20 class:noclass key:angle
Entity:20 class:noclass key:spawnflags
Entity:20 class:noclass key:model
Entity:20 class:noclass key:origin
Entity:20 class:noclass key:classname
entity: model (models/objects/vegi/water_lily/lily_stem.md2) num: 0 solid:0 mins: 0 0 0 maxs: 0 0 0 absmins: 0 0 0 absmaxs: 0 0 0 origin: 1712 480 32
Entity:20 class:noclass key:spawnflags
Entity:20 class:noclass key:model
Entity:20 class:noclass key:origin
Entity:20 class:noclass key:classname
entity: model (models/objects/vegi/water_lily/lily_stem.md2) num: 0 solid:0 mins: 0 0 0 maxs: 0 0 0 absmins: 0 0 0 absmaxs: 0 0 0 origin: 1744 496 32
Entity:20 class:noclass key:modelscale_vec
ED_ParseField: modelscale_vec is not a valid field
Entity:20 class:noclass key:spawnflags
Entity:20 class:noclass key:model
Entity:20 class:noclass key:origin
Entity:20 class:noclass key:classname
entity: model (models/objects/vegi/water_lily/lily_leaf.md2) num: 0 solid:0 mins: 0 0 0 maxs: 0 0 0 absmins: 0 0 0 absmaxs: 0 0 0 origin: 1744 496 32
Entity:20 class:noclass key:angle
Entity:20 class:noclass key:spawnflags
Entity:20 class:noclass key:model
Entity:20 class:noclass key:origin
Entity:20 class:noclass key:classname
entity: model (models/objects/vegi/water_lily/lily_stem.md2) num: 0 solid:0 mins: 0 0 0 maxs: 0 0 0 absmins: 0 0 0 absmaxs: 0 0 0 origin: 1712 512 32
Entity:20 class:noclass key:modelscale_vec
ED_ParseField: modelscale_vec is not a valid field
Entity:20 class:noclass key:angle
Entity:20 class:noclass key:spawnflags
Entity:20 class:noclass key:model
Entity:20 class:noclass key:origin
Entity:20 class:noclass key:classname
entity: model (models/objects/vegi/water_lily/lily_leaf.md2) num: 0 solid:0 mins: 0 0 0 maxs: 0 0 0 absmins: 0 0 0 absmaxs: 0 0 0 origin: 1712 512 32
No civilian spawn points in this map or civilians deactivated
No valid name definitions for gender 2 in category 'ortnok'
No valid name definitions for gender 1 in category 'ortnok'
No valid name definitions for gender 2 in category 'ortnok'
No valid name definitions for gender 1 in category 'ortnok'
No valid name definitions for gender 2 in category 'ortnok'
No valid name definitions for gender 2 in category 'ortnok'
No valid name definitions for gender 2 in category 'ortnok'
No valid name definitions for gender 1 in category 'ortnok'
CHRSH_CharGetBody: use 'aliens/ortnok/body01' as body model path for character
CHRSH_CharGetBody: use 'aliens/ortnok/head02' as head model path for character
INVSH_EquipActor: no weapon picked in equipment 'multiplayer_alien', defaulting to the most expensive secondary weapon without reload.
... snip ...

CHRSH_CharGetBody: use 'aliens/ortnok/body01' as body model path for character
CHRSH_CharGetBody: use 'aliens/ortnok/head01' as head model path for character
new event '12' for mask 0
new event '12' for mask 0
new event '12' for mask 0
new event '12' for mask 0
new event '12' for mask 0
new event '12' for mask 0
new event '12' for mask 0
new event '12' for mask 0
new event '22' for mask 0
new event '22' for mask 0
new event '22' for mask 0
new event '22' for mask 0
new event '22' for mask 0
new event '22' for mask 0
new event '22' for mask 0
new event '22' for mask 0
Created AI player (team 7)
0 groups with 0 entities
Set server state to 2
-------------------------------------
CL_SetClientState: Set new state to 3 (old was: 1)
Connecting to localhost...
New stream at index: 0
New stream at index: 1
Packet : connect
SVC_DirectConnect()
Set state for client 'michael' to 1
server OOB:
CL_SetClientState: Set new state to 4 (old was: 3)
0   ufo                                 0x0019c790 Sys_Mkdir + 180
1   ufo                                 0x0019c808 Sys_Mkdir + 300
2   libSystem.B.dylib                   0x92f3399c _sigtramp + 68
Wrote keys.cfg

^CReceived signal 2, quitting..
recursive shutdown
Kleiman-ibook:trunk michael$

Yep, it really takes that long and does that much on entity 20.

Now, sometimes I can get it to display a black map (cannot even see my team), and sometimes it crashes like this.
However, it does get that little bit farther -- the map does load now.

Investigation continues ...
Title: Re: Log of an attempt to compile a universal binary for 10.5.6 for 2.3-dev (trunk)
Post by: keybounce on March 22, 2009, 06:25:18 am
I think I see the problem.

There are some places where "numTiles" is used as "past the upper limit of valid tiles" -- things like for(i=0; i<numTiles; i++), where if "numTiles == 0", for the start of the level load, will be skipped completely; and other places where "numTiles" is used as a valid current index into an array.

I don't pretend to know all of it, but it seems that numTiles is being used inconsistently, like its meaning has changed over the course of the code development.
Title: Re: Log of an attempt to compile a universal binary for 10.5.6 for 2.3-dev (trunk)
Post by: Mattn on March 22, 2009, 07:23:51 am
as a reference, please also see: https://sourceforge.net/tracker2/?func=detail&aid=2695771&group_id=157793&atid=805244