Changes between Version 7 and Version 8 of CompilationGuide/MacOSX


Ignore:
Timestamp:
Mar 11, 2012, 6:54:13 AM (7 years ago)
Author:
SJ_UnderWater
Comment:

pkg-config changes

Legend:

Unmodified
Added
Removed
Modified
  • CompilationGuide/MacOSX

    v7 v8  
    1313=== Freetype ===
    1414
    15 Mac OS X Lion comes with Freetype already installed (older versions may need 'X11' selected during installation), but in an atypical location: /usr/X11. Running freetype-config in Terminal can give the locations of the individual folders, like headers, and libraries, so be prepared to add lines like {{{CFLAGS=`freetype-config --cflags` LDFLAGS=`freetype-config --libs`}}} before {{{./configure}}} when configuring packages that require freetype like gd and png
     15Mac OS X Lion comes with Freetype already installed (older versions may need 'X11' selected during installation), but in an atypical location: /usr/X11. Running freetype-config in Terminal can give the locations of the individual folders, like headers, and libraries, so be prepared to add lines like {{{CFLAGS=`freetype-config --cflags` LDFLAGS=`freetype-config --libs`}}} before {{{./configure}}} when configuring packages that require freetype like gd and png. To use OS X's included copy of freetype with FFmpeg, you must specifically defeat the configuration test in "configure" (delete everything after "&&"), and add {{{--extra-cflags="`freetype-config --cflags`" --extra-ldflags="`freetype-config --libs`"}}}
    1616
    1717=== Pkg-config & GLib ===
    1818
    19 Pkg-config is necessary for detecting some of the libraries you can compile into FFmpeg, and it requires GLib which is not included in Mac OS X (but almost every other *nix distribution). You may either download pkg-config 0.23, or download the large tarball from [http://ftp.gnome.org/pub/GNOME/sources/glib/ Gnome.org] and compile it. Pkg-config is available from [http://pkgconfig.freedesktop.org/releases/ Freedesktop.org]. After installing pkg-config, you might need to modify your ~/.profile to reflect all pkgconfig locations in your PKG_CONFIG_PATH environment variable {{{export PKG_CONFIG_PATH=$PKG_CONFIG_PATH:/usr/local/lib/pkgconfig:/usr/lib/pkgconfig}}}
     19Pkg-config is necessary for detecting some of the libraries you can compile into FFmpeg, and it requires GLib which is not included in Mac OS X (but almost every other *nix distribution). You may either download pkg-config 0.23, or download the large tarball from [http://ftp.gnome.org/pub/GNOME/sources/glib/ Gnome.org] and compile it. Pkg-config is available from [http://pkgconfig.freedesktop.org/releases/ Freedesktop.org].
    2020
    2121To compile GLib, you must also download gettext from [ftp://ftp.gnu.org/gnu/gettext/ GNU.org] and edit the file stpncpy.c to add "#undef stpncpy" just before "#ifndef weak_alias". Lion has its own (incompatible) version of the stpncpy function, which overlaps in gettext. Compile gettext as usual. Compile GLib with {{{LIBFFI_CFLAGS=-I/usr/include/ffi LIBFFI_LIBS=-lffi ./configure;make && sudo make install}}}
    2222
    23 To compile pkg-config, run {{{GLIB_CFLAGS="-I/usr/local/include/glib-2.0 -I/usr/local/lib/glib-2.0/include" GLIB_LIBS="-lglib-2.0 -lgio-2.0" ./configure;make && sudo make install}}}
     23To compile pkg-config, run {{{GLIB_CFLAGS="-I/usr/local/include/glib-2.0 -I/usr/local/lib/glib-2.0/include" GLIB_LIBS="-lglib-2.0 -lgio-2.0" ./configure --with-pc-path="/usr/X11/lib/pkgconfig:/usr/X11/share/pkgconfig:/usr/lib/pkgconfig:/usr/local/lib/pkgconfig"}}}
    2424
    2525=== Yasm ===