Technical support > Mac

[FIXED in macports trunk] SDL_mixer + OGG broken? Fix in macports!

<< < (2/5) > >>

keybounce:
I'm not able to test this right now (time and priorities), but I'm thinking that we may need to switch from the MacPorts version of SDL to the official binary of SDL -- some changes were made back in November about how it links in some sound supports. (Just found this out last night).

keybounce:
Bump

I can confirm the following:
1. Modifying the configure.ac to use the frameworks is a pain, but doable.
2. It fixes all sound issues -- no more complaints about unable to load a sound file.
3. Graphics are still messed up on the battlefield.
4. The 3D world is still too dark.
5. I could not get ufomodel to build -- SDLMain vs main issues.
6. Some of the libraries that configure tests for don't need to be tested for. System built with them turned off. (Zlib and XviD.)

To get this to work, I had to do the following:

PKG_CONFIG_PATH=/usr/X11/lib/pkgconfig:/usr/lib/pkgconfig ; export PKG_CONFIG_PATH
aclocal --verbose -I /opt/local/share/aclocal/
autoconf
./configure --disable-uforadiant --enable-universal

Pkg-config was the really odd one. It's in /opt/local (so it came from macports), and will not check the system directories by default. There are config files in the system directories, but apparently no system supplied pkg-config.

The combination of pkg-config and aclocal is needed to fix ...

--- Quote ---#---------------------------------------------------------------------------------------
------
# defined some defaults for users (mac-users..) who might not have pkg-config.
#---------------------------------------------------------------------------------------
------

m4_define_default([PKG_CHECK_MODULES],
        [AC_MSG_ERROR([For current build options, pkg-config is required. Did you maybe
forget to run aclocal with the current include path?])])


--- End quote ---

Mattn:
which m4 files in /opt/local/share/aclocal/ are needed? i will add them to our svn in the versions we need them (to be able to rebuild aclocal.m4 in a "correct" way on each system)

pkg-config stuff is really strange, is that written on the macports homepage somewhere?

zlib should not be deactivated - xlib can be

Mattn:
should we completely switch over to the frameworks?

keybounce:
As for the frameworks:
1. The sound issue is linking related, and it's fixed in the frameworks. Potentially it could be fixed in the library versions.
2. It does nothing to fix the graphics issues
3. I found the hard way that you need the development frameworks. It's not "This is used to develop the SDL code", it's "This is used if you are developing a program that uses SDL".

In particular, there are _MULTIPLE_ implementations of main() (in the development frameworks) that set things up and call SDL_main(). Just as a quick example, the code that is used for ufo fails to work for ufomodel. And, sdl-config doesn't exist in the end user framework version.
4. You still have to copy the stuff into the .dmg for distribution.

At the moment, using the frameworks version for sound might make sense, but not if the .dmg packaging breaks their linking fix. (Not tested yet).

As for pkg-config, it was trial and error. I'm still learning how aclocal, autoconf, and automake all fit together (and automake isn't even used here.)

Aclocal needed
# pkg.m4 - Macros to locate and utilise pkg-config.            -*- Autoconf -*-
# serial 1 (pkg-config-0.24)
...
# PKG_PROG_PKG_CONFIG([MIN-VERSION])
# ----------------------------------
AC_DEFUN([PKG_PROG_PKG_CONFIG],
[m4_pattern_forbid([^_?PKG_[A-Z_]+$])
...

I hope that's enough to tell you what it needed. A comparison of the config files produced by my autoconf versus your autoconf shows that my version is out of date. (Hmm, checking ... yep, I'm using the stock version from 10.5.8, not the macports version.)

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version