Difference between revisions of "Development:Building:Building Dependencies from Source"

From Camino Wiki
Jump to navigation Jump to search
(→‎<code>autoconf-2.1.3</code>: fix typo, and switch to --program suffix)
(→‎libIDL-0.8: add documentfoundation docs, which are more explicit for the 10.6 situation)
 
(9 intermediate revisions by the same user not shown)
Line 1: Line 1:
Some people prefer to build their dependencies (<code>glib2</code>, <code>libIDL-0.8</code>, <code>autoconf-2.1.3</code>) from source instead of using [http://www.finkproject.org/ Fink] or [http://www.macports.org/ MacPorts] and the megabytes of extra software those port systems install by default.  Fortunately, it is rather trivial to build the required dependencies from source.
+
Some people prefer to build their dependencies (<code>libIDL-0.8</code>, <code>autoconf-2.13</code>) from source instead of using [http://www.finkproject.org/ Fink] or [http://www.macports.org/ MacPorts] and the megabytes of extra software those port systems install by default.  Fortunately, it is rather trivial to build the required dependencies from source.
  
 
==Dependency Tree==
 
==Dependency Tree==
  
 
* <code>[ftp://ftp.gnu.org/gnu/autoconf/autoconf-2.13.tar.gz autoconf-2.13]</code>
 
* <code>[ftp://ftp.gnu.org/gnu/autoconf/autoconf-2.13.tar.gz autoconf-2.13]</code>
 +
 +
* <code>[http://www.tortall.net/projects/yasm/releases/yasm-1.0.1.tar.gz yasm]</code>
  
 
* <code>[http://ftp.gnome.org/pub/gnome/sources/libIDL/0.8/ libIDL]</code>
 
* <code>[http://ftp.gnome.org/pub/gnome/sources/libIDL/0.8/ libIDL]</code>
Line 12: Line 14:
 
==Building the Packages==
 
==Building the Packages==
  
You can install all these packages except <code>autoconf-2.1.3</code> in <code>/usr/local</code> (where they should be picked up by your <code>$PATH</code> automatically).  You should probably install <code>autoconf-2.1.3</code> in a location outside your path to prevent accidental usage when scripts want the version of <code>autoconf</code> installed with Xcode.
+
You can install all these packages in <code>/usr/local</code> (where they should be picked up by your <code>$PATH</code> automatically).  You should be very careful when building <code>autoconf-2.13</code> so that you do not create an <code>autoconf</code> binary that will be used accidentally when scripts want the version of <code>autoconf</code> installed with Xcode; make sure you use the <code>--program-suffix=213</code> argument.
  
===<code>autoconf-2.1.3</code>===
+
===<code>autoconf-2.13</code>===
<code>autoconf-2.1.3</code> has no dependencies aside from software installed with Xcode.
+
<code>autoconf-2.13</code> has no dependencies aside from software installed with Xcode.
  
 
# Download the <code>[ftp://ftp.gnu.org/gnu/autoconf/autoconf-2.13.tar.gz autoconf-2.13]</code> tarball and unpack.
 
# Download the <code>[ftp://ftp.gnu.org/gnu/autoconf/autoconf-2.13.tar.gz autoconf-2.13]</code> tarball and unpack.
Line 21: Line 23:
 
# <code>./configure --program-suffix=213<!-- --prefix=/opt/autoconf213--></code>
 
# <code>./configure --program-suffix=213<!-- --prefix=/opt/autoconf213--></code>
 
# <code>make clean all; sudo make install</code>
 
# <code>make clean all; sudo make install</code>
 +
 +
===<code>yasm</code>===
 +
<code>yasm</code> (required for WebM and libjpeg-turbo assembly in Gecko 2.0 and up) has no dependencies aside from software installed with Xcode.
 +
 +
# Download the <code>[http://www.tortall.net/projects/yasm/releases/yasm-1.1.0.tar.gz yasm-1.1.0]</code> tarball and unpack.
 +
# <code>cd</code> to the unpacked directory.
 +
# <code>./configure</code>
 +
# <code>make; sudo make install</code>
  
 
===<code>libIDL-0.8</code>===
 
===<code>libIDL-0.8</code>===
  
 
<code>libIDL-0.8</code> ends up having three dependencies beyond software installed by Xcode, so we will build and install from the dependencies upward.
 
<code>libIDL-0.8</code> ends up having three dependencies beyond software installed by Xcode, so we will build and install from the dependencies upward.
 +
 +
On Mac OS X 10.6, <code>libIDL</code> must be 32-bit (or 32/64-bit Universal) while autotools will by default, build 64-bit binaries.  As a result, additional flags must be passed to <code>configure</code> for <code>libIDL</code> '''and''' all of its dependencies. ([http://code.google.com/p/macfuse/source/browse/trunk/core/macfuse_buildtool.sh#1357 This section] of the MacFUSE build script has useful information for compiling <code>libIDL</code>’s <code>glib2</code> dependencies as Universal Binaries; also, The Document Foundation provides full commands for compiling <code>libIDL</code> and its dependencies, as well as other software not required by libIDL, as 32/64-bit binaries on Mac OS X 10.6 on [http://wiki.documentfoundation.org/Development/Install_Mac_OS_10.6.4_Dependencies this page on its wiki].)
  
 
====<code>pkg-config</code>====
 
====<code>pkg-config</code>====
Line 30: Line 42:
 
<code>pkg-config</code> has no external dependencies.
 
<code>pkg-config</code> has no external dependencies.
  
# Download the latest... and unpack.
+
# Download the latest source tarball from [http://pkgconfig.freedesktop.org/releases/ http://pkgconfig.freedesktop.org/releases/] and unpack.
 +
# <code>cd</code> to the unpacked directory.
 +
# <code>./configure</code>
 +
# <code>make clean all; sudo make install</code>
 +
 
 +
====<code>gettext</code>====
 +
 
 +
<code>gettext</code> has no external dependencies.
 +
 
 +
# Download the latest source tarball from [ftp://ftp.gnu.org/gnu/gettext/ ftp://ftp.gnu.org/gnu/gettext/] and unpack.
 +
# <code>cd</code> to the unpacked directory.
 +
# <code>./configure</code>
 +
# <code>make clean all; sudo make install</code>
 +
 
 +
====<code>glib2</code>====
 +
 
 +
<code>glib2</code> depends on both <code>pkg-config</code> and <code>gettext</code>, which have just been installed.
 +
 
 +
# Download the latest source tarball from [ftp://ftp.gtk.org/pub/glib/ ftp://ftp.gtk.org/pub/glib/] and unpack.
 +
# <code>cd</code> to the unpacked directory.
 +
# ''need to set CFLAGS and LDFLAGS to point to the include dir, and possibly pkg-config path…''

Latest revision as of 22:00, 16 March 2011

Some people prefer to build their dependencies (libIDL-0.8, autoconf-2.13) from source instead of using Fink or MacPorts and the megabytes of extra software those port systems install by default. Fortunately, it is rather trivial to build the required dependencies from source.

Dependency Tree

Building the Packages

You can install all these packages in /usr/local (where they should be picked up by your $PATH automatically). You should be very careful when building autoconf-2.13 so that you do not create an autoconf binary that will be used accidentally when scripts want the version of autoconf installed with Xcode; make sure you use the --program-suffix=213 argument.

autoconf-2.13

autoconf-2.13 has no dependencies aside from software installed with Xcode.

  1. Download the autoconf-2.13 tarball and unpack.
  2. cd to the unpacked directory.
  3. ./configure --program-suffix=213
  4. make clean all; sudo make install

yasm

yasm (required for WebM and libjpeg-turbo assembly in Gecko 2.0 and up) has no dependencies aside from software installed with Xcode.

  1. Download the yasm-1.1.0 tarball and unpack.
  2. cd to the unpacked directory.
  3. ./configure
  4. make; sudo make install

libIDL-0.8

libIDL-0.8 ends up having three dependencies beyond software installed by Xcode, so we will build and install from the dependencies upward.

On Mac OS X 10.6, libIDL must be 32-bit (or 32/64-bit Universal) while autotools will by default, build 64-bit binaries. As a result, additional flags must be passed to configure for libIDL and all of its dependencies. (This section of the MacFUSE build script has useful information for compiling libIDL’s glib2 dependencies as Universal Binaries; also, The Document Foundation provides full commands for compiling libIDL and its dependencies, as well as other software not required by libIDL, as 32/64-bit binaries on Mac OS X 10.6 on this page on its wiki.)

pkg-config

pkg-config has no external dependencies.

  1. Download the latest source tarball from http://pkgconfig.freedesktop.org/releases/ and unpack.
  2. cd to the unpacked directory.
  3. ./configure
  4. make clean all; sudo make install

gettext

gettext has no external dependencies.

  1. Download the latest source tarball from ftp://ftp.gnu.org/gnu/gettext/ and unpack.
  2. cd to the unpacked directory.
  3. ./configure
  4. make clean all; sudo make install

glib2

glib2 depends on both pkg-config and gettext, which have just been installed.

  1. Download the latest source tarball from ftp://ftp.gtk.org/pub/glib/ and unpack.
  2. cd to the unpacked directory.
  3. need to set CFLAGS and LDFLAGS to point to the include dir, and possibly pkg-config path…