マソム自宅サーバ構築の記録

  • gpacのインストール
  • 作成日:08/03/24    更新日:09/08/07

前置き

動画変換ツールFFmpegをインストールする為に、H.264のエンコード用コーデックx264をインストールしようとしたら、オプション--enable-mp4-outputにはgpacが必要とのことでした。その他、プログレッシブダウンロードできる3GPPの作成にも、gpacが必要なようなのでインストールすることにしました。
以下を参考にさせて頂きました。有り難うございます。
春一番? いいや、二番目だね!
HowTo: Encode Video for iPod Video
ウィキペディア

前提

gpac には、
  MP4Client・・・・・コマンド・ライン・インタフェース
  Osmo4・・・・・・・・GUIフロントエンド
  MP4Box・・・・・・・MPEG-4のエンコード、デコード用のツール
  Osmozilla・・・・・・Mozillaベースのブラウザのためのプラグイン
があるそうです。MP4BoxとMP4Clientが使えれば良さそうです。
なお、LAME、Ogg Vorbis、MPEG-4 AAC、AMR のインストールは済んでいます。

インストールの手順

まず、gpacをダウンロードしソースを展開して、必要なライブラリやインストールの手順を確認します。
次に、必要なライブラリをインストールします。
1.FreeType2・・・・・TrueType フォントのレンダリング用ライブラリ。必須ではありません。無くてもgpacのmakeは通りました。
2.SDL・・・・・・・・・・グラフィックやサウンド等のAPIを提供するライブラリ。多分必須ではありません。無くてもgpacのmakeは通りました。
最後にgpacをインストールします。

gpacをダウンロード

私はユーザディレクトリにソース置き場を作ってあるので、そこに移動してからダウンロードします。

$ cd /home/ユーザ名/src
$ wget http://downloads.sourceforge.net/gpac/gpac_extra_libs-0.4.4.tar.gz?modtime=1180633664&big_mirror=0
ソースを展開し、ソースディレクトリに移動します。
$ tar -xvzf gpac-0.4.4.tar.gz
$ cd gpac
インストール方法をソース内のINSTALLで確認します。
$ vi INSTALL
  Installation instructions for GPAC 0.4.4 - Mai 2007:

  * Foreword

    GPAC may be compiled without any third party libraries, but in this case its functionalities are very
    limited (no still image, no audio, no video, no text, no scripting). It is therefore recommended to download the
    extra lib package available at http://sourceforge.net/projects/gpac. Compilation instructions for these libraries
    are provided per library in the package.
    The current extra_lib package to use with gpac 0.4.4 is gpac_extra_libs 0.4.4.

    In case you have some of these libs already installed on your system, the detailed list of dependencies is
    * freetype2 from version 2.1.4 on.
    * SpiderMonkey v1.5 RC 4 (libjs from mozilla - you will need gmake to compile this one). RC5 and RC6 can be used but need
    changes in /include/gpac/setup.h or configure script
    * libjpg version 6b
    * Libpng version 1.2.5
    * MAD version 0.15.1b (older versions should work)
    * xvid version 1.0 (0.9.0 / .1 / .2 should also work)
    * ffmpeg 08 February 2007 snapshot
    * libogg 1.1, libvorbis 1.1 and libtheora 1.0 from Xiph.org
    * faad2, version 2.0 or 2.1 (CVS from www.audiocoding.com)

    Windows user are invited to download and install the Microsoft Platform SDK at
    http://www.microsoft.com/msdownload/platformsdk/sdkupdate
    If you don't have enough bandwidth (it's big) the GDIplus SDK is also included in the gpac_extra_lib package

  * Installing GPAC

  Detailed instruction for Win32 MSVC Compilation are available in gpac/doc/INSTALL.w32

  Detailed instruction for WinCE eVC Compilation are available in gpac/doc/INSTALL.wCE

  Detailed instruction for GCC Compilation are available in gpac/doc/INSTALL.gcc

  Detailed instruction for GCC cross-compilation for familiar+GPE systems are available in gpac/doc/INSTALL.gpe

  Detailed instruction for GCCE/Symbian cross-compilation for Symbian v9.1 systems are available in gpac/doc/INSTALL.symbian

  * Configuring GPAC

  GPAC's client configuration is documented in gpac/doc/configuration.html
  MP4Box documentation is available online at http://gpac.sourceforge.net
gpac_extra_libs をダウンロードしてサードパーティのライブラリーを入手できるようです。
一応そうしておきます。
$ cd /home/ユーザ名/src
$ wget http://downloads.sourceforge.net/gpac/gpac_extra_libs-0.4.4.tar.gz?modtime=1180633664&big_mirror=0
$ tar -xvzf gpac_extra_libs-0.4.4.tar.gz
$ cd gpac_extra_libs
$ cp -r * ../gpac/extra_lib
$ cd ../gpac
しかし、それとは別に必要なライブラリは別途インストールしておくことにしました。以下がインストールの有無を検討した結果です。
  FreeType2:TrueType フォントのレンダリング用ライブラリ
          PHPのGDでも使う可能性も考え、システム上にインストールすることにしました。yumでRPMパッケージをインストールします。
  SpiderMonkey:Gecko の JavaScript エンジンだそうです。インストールしません。
  libjpg:PHPのGDで使う為にRPMパッケージをインストール済みです。
  Libpng:PHPのGDで使う為にRPMパッケージをインストール済みです。
  MAD:MPEG オーディオ(MP3) デコーダーだそうです。FFmpegでは必要ないようなのでインストールしません。
  xvid:MPEG-4 ASP 準拠のビデオコーデックで、商用ソフトで使う時はソースの公開が必要だそうです。インストールしません。
  ffmpeg:FFmpegはこの後インストールする予定です。バージョンが違いますし、取り合えずインストールしません。
  libogg、libvorbis:RPMパッケージがインストールされています。
  libtheora:開発中のビデオコーデックTheoraの実装だそうです。インストールしません。
  faad2:MPEG-4 AACのライブラリ。FFmpegで使う為にインストール済みです。

次に、GCCコンパイラを使う場合の詳細が、doc/INSTALL.gcc に載っているようです。見てみます。
$ vi doc/INSTALL.gcc
  Installation instructions for GPAC 0.4.4 on GCC-powered platforms
  last modified: October 2005

  0 Foreword
    The output directory for all plugins and applications is gpac/bin/gcc

    As of 0.2.2, GPAC cannot be compiled without ZLIB. You'd better make sure it is installed on your system (zlib is provided in gpac_extra_libs package)

  I Extra lib installation
    It is recommended to download and compile all extra libs needed by gpac not installed on your system.

  II GPAC compilation

   II.1 SDL Support
    GPAC can use SDL for audio/video output. If SDL is not installed on your system, you may indicate configure to build with a local copy:
    --sdl-cfg=path/to/local/sdlcfg/
    (make sure to update the local sdl-cfg according to your needs)

    If you can't get SDL and don't have OSS or WAV audio nor DirectX or X11 video support on your system, you won't be able to play any presentation with GPAC,
    but you can still use MP4Box.

   II.2 wxWidgets Support
    GPAC comes with a GUI player called Osmo4. To compile this player you will need wxWidgets 2.6.0 (2.5.2 should work) installed on your system.
    Both unicode and ANSI versions of wxWidgets should be supported.
  If you don't use wxWidgets, you can always use GPAC command-line player MP4Client.

   II.3 libxml2 Support
    GPAC can be used to play some SVG files. You may want to use libXML2 for SVG loading, although this is not a requirement (If this library is not installed on the system,
    SVG support will still be enabled with GPAC's own XML parser).
    If you have libxml2 but it is not installed on your system, you will have to modify gpac/configure or gpac/modules/svg_loader/Makefile scripts to compile by hand.
    MINGW users: libXML2 is quite impossible to compile under MinGW, you'll usuall get plenty of errors and only a partial compil. Sorry about that.

   II.4 MinGW DirectX support
    When building GPAC under MinGW, it is also possible to compile the DirectX plugin. You will need the MinGW versions of DX libs
    (available at http://alleg.sourceforge.net/files/). Get dx70_mgw or dx80_mgw (dx8 is provided in gpac_extra_libs package)
    copy the archive content in your MSys tree (for ex, /usr/local/DirectX) and configure gpac with the option --dxsdk-path=/usr/local/DirectX
    ** you must keep include and lib folders under the same directory for the configure script to detect DirectX **

   II.5 Building GPAC
    go to root of gpac distribution
    ./configure (--help for options) - you may need to "chmod +x" this file...
    make

    any fixes to configure are welcome :)

   II.6 Installing GPAC
    get root
    type "make install" in gpac/

    This will install MP4Client, Osmo4 if configured, MP4Box and all plugins as well as GPAC documentation man: MP4Box(1), MP4Client(1) and GPAC(1).
    type "make uninstall" to remove gpac from your system

   II.7 Installing GPAC SDK
    get root
    type "make install-lib" in gpac/

    This will install gpac base headers (<gpac/*.h>), gpac development headers (<gpac/internal/*.h> and libgpac_static - the static version of libgpac shared library.
    type "make uninstall-lib" to remove gpac from your system
    There is no documentation regarding headers/SDK for now, you will have to rely on function descriptions in each header.

  III Running GPAC

   III.1 MP4Client
    MP4Client is a command-line interface to GPAC. Note that the player cannot work without video support (so you'd better get SDL)
    GPAC comes with 2 renderers: a 2D only renderer, stable and complete and a 2D/3D renderer still in development. You can switch the renderer
    used by typing in MP4CLient:
  "2" to switch to GPAC 2D renderer
  "3" to switch to GPAC 3D renderer

    You need a GPAC configuration file to run MP4Client, and you will need it each time.

    First launch of MP4Client
    go to gpac/bin/gcc if not using the install.
    type MP4Client
    the prompt will ask for
    1- GPAC plugin dir: enter the path from / to gpac/bin/gcc. This is skipped when using the install version of MP4Client (the plugin path is hardcoded to
    the plugins install location on the system)
    2- Font directory: enter the path to a truetype font directory on your system (note that if you don't have compiled with freetype any directory will do)
    3- cache directory: any directory with write access
    You now have a valid config file for GPAC, more info on this try "man GPAC" or check gpac/doc/configuration.html.

    The config file is called ".gpacrc" and is located in the user home directory. You may run the client with a different config file by using the "-c" option.

    *If you don't see any output window, check the config file doesn't use raw_out.so as a video renderer (or simply remove raw_out.so).

    MINGW USERS: there are known and terrible bugs with MSys rxvt stdio buffering, do NOT use it to run MP4Client unless you want to understand
    these bugs. Use w32 CMD.exe instead. Other GPAC apps are no pb for MSys rxvt.

   III.2 Osmo4
    Osmo4 is the GUI frontend to GPAC. If you have installed Osmo4 on your system, the first launch of the player should ask you to locate a
    directory with TrueType fonts and a cache directory for internet downloads if no configuration file is found.

   III.3 MP4Box
    MP4Box is a tool to encode, decode and manipulate MPEG-4 systems data. It does not need a configuration file.
    Help for MP4Box is available on GPAC web site, with man MP4Box (except on MinGW) and with 'MP4Box -h'

   III.4 Osmozilla
    Osmozilla is GPAC plugin for Mozilla-based browsers. It is by default installed to the user mozilla directory ~/.mozilla
    To install the plugin on the system
    * get root
    * ./configure --mozdir=/path/to/mozilla
    for example --mozdir=/usr/lib/mozilla-firefox
    * make -C applications/osmozilla install

    * OR you may copy by hand bin/gcc/nposmozilla.so to /usr/lib/moz**/plugins and bin/gcc/nposmozilla.xpt to /usr/lib/moz**/components

  IV Configuration

   IV.0 Foreword
    All configuration information is described in gpac/doc/configuration.html, or man gpac.

   IV.1 OpenGL
    OpenGL is badly known for performing quite poorly as far as high data rate texturing is involved. This is a big issue when displaying a typical movie and you will likely find the GPAC 3D Renderer very slow on your system. If your GPU supports non power of 2 texturing or rectangular texturing (most Win32 drivers do)
    you shouldn't have any problem with video. Otherwise here are some tips to configure GPAC on your system:
    1- set the "BitmapCopyPixels" option on: some cards perform rather well at direct pixel transfer. If no improvement, set it off.
    2- set the "BitmapCopyPixels" option off and the "EmulatePOW2" option on. This will trick the GL texturing by using only Power Of 2 textures when converting from YUV to RGB.
    3- If this does not improve video playback, you're only chance is through discussion forums & co to gather info about your system, your GL implementation and how to fine-tune it.

  V Misc

    There is a demo 2D authoring tool called V4Studio. No makefiles available yet but should compile without pbs (only needs M4Systems
    and wxWidgets 2.5.2). It is not usable to design content but is a funny toy.
コンパイルの説明を見ると、
 SDL : グラフィックやサウンド等のAPIを提供するライブラリだそうです。
      MP4Boxを使う為には無くても良いようです。MP4Client(GPACへのコマンド・ライン・インタフェース)を使う為にはあった方が良いようです。
     yumでインストールできるので、入れてみることにしました。
 wxWidgets : Osmo4というGUIプレーヤーをコンパイルするなら wxWidgets 2.6.0 が必要だそうです。
         これがなくても、コマンドラインからはコマンド・ライン版プレーヤーのMP4Clientが使えるそうです。
         インストールしません。
 libXML2 : SVGとはXMLで記述されるベクターグラフック言語、又はそのフォーマットであるだそうです。
        ブラウザのサポートも進んでいるそうで、面白そうです。
        gpacである程度表示?できるそうで、その為に libXML2 があった方が良いそうです。
        しかし、SVGはFFmpegとは別問題のようなので無くても良さそうです。但し私の環境では、既に libxml2 がPRMパッケージで入っていました。

ライブラリをインストール

FreeType2のライブラリをインストールします。必須ではありません。無くてもgpacのmakeは通りました。
$ su

# yum list freetype*
Loading "installonlyn" plugin
fedora 100% |=========================| 2.1 kB 00:00
updates 100% |=========================| 2.3 kB 00:00
Installed Packages
freetype.i386 2.3.4-3.fc7 installed
Available Packages
freetype-demos.i386 2.3.4-3.fc7 updates
freetype-devel.i386 2.3.4-3.fc7 updates
freetype1.i386 1.4-0.2.pre.fc7 fedora
freetype1-devel.i386 1.4-0.2.pre.fc7 fedora
freetype1-utils.i386 1.4-0.2.pre.fc7 fedora

# yum install freetype-devel
Loading "installonlyn" plugin
Setting up Install Process
Parsing package install arguments
Resolving Dependencies
--> Running transaction check
---> Package freetype-devel.i386 0:2.3.4-3.fc7 set to be updated

Dependencies Resolved

=============================================================================
Package Arch Version Repository Size
=============================================================================
Installing:
freetype-devel i386 2.3.4-3.fc7 updates 156 k

Transaction Summary
=============================================================================
Install 1 Package(s)
Update 0 Package(s)
Remove 0 Package(s)

Total download size: 156 k
Is this ok [y/N]: y
Downloading Packages:
(1/1): freetype-devel-2.3 100% |=========================| 156 kB 00:01
Running Transaction Test
Finished Transaction Test
Transaction Test Succeeded
Running Transaction
Installing: freetype-devel ######################### [1/1]

Installed: freetype-devel.i386 0:2.3.4-3.fc7
Complete!

 


SDLをインストールします。多分必須ではありません。無くてもgpacのmakeは通りました。

$ su

# yum install SDL SDL-devel
Loading "installonlyn" plugin
Setting up Install Process
Parsing package install arguments
fedora 100% |=========================| 2.1 kB 00:00
updates 100% |=========================| 2.3 kB 00:00
Resolving Dependencies
--> Running transaction check
---> Package SDL.i386 0:1.2.12-1.fc7 set to be updated
---> Package SDL-devel.i386 0:1.2.12-1.fc7 set to be updated
--> Processing Dependency: libXext-devel for package: SDL-devel
--> Processing Dependency: libGLU-devel for package: SDL-devel
--> Processing Dependency: libXrandr-devel for package: SDL-devel
--> Processing Dependency: alsa-lib-devel for package: SDL-devel
--> Processing Dependency: libXrender-devel for package: SDL-devel
--> Restarting Dependency Resolution with new changes.
--> Running transaction check
---> Package libXrandr-devel.i386 0:1.2.0-3.fc7 set to be updated
---> Package mesa-libGLU-devel.i386 0:6.5.2-13.fc7 set to be updated
---> Package alsa-lib-devel.i386 0:1.0.14-3.fc7 set to be updated
---> Package SDL-devel.i386 0:1.2.12-1.fc7 set to be updated
---> Package libXrender-devel.i386 0:0.9.2-1.fc7 set to be updated
---> Package libXext-devel.i386 0:1.0.1-2.1 set to be updated
--> Processing Dependency: mesa-libGLU = 6.5.2-13.fc7 for package: mesa-libGLU-devel
--> Processing Dependency: libGLU.so.1 for package: mesa-libGLU-devel
--> Restarting Dependency Resolution with new changes.
--> Running transaction check
---> Package mesa-libGLU-devel.i386 0:6.5.2-13.fc7 set to be updated
---> Package mesa-libGLU.i386 0:6.5.2-13.fc7 set to be updated

Dependencies Resolved

=============================================================================
Package Arch Version Repository Size
=============================================================================
Installing:
SDL i386 1.2.12-1.fc7 updates 219 k
SDL-devel i386 1.2.12-1.fc7 updates 620 k
Installing for dependencies:
alsa-lib-devel i386 1.0.14-3.fc7 updates 1.4 M
libXext-devel i386 1.0.1-2.1 fedora 57 k
libXrandr-devel i386 1.2.0-3.fc7 fedora 16 k
libXrender-devel i386 0.9.2-1.fc7 fedora 9.0 k
mesa-libGLU i386 6.5.2-13.fc7 updates 204 k
mesa-libGLU-devel i386 6.5.2-13.fc7 updates 93 k

Transaction Summary
=============================================================================
Install 8 Package(s)
Update 0 Package(s)
Remove 0 Package(s)

Total download size: 2.6 M
Is this ok [y/N]: y
Downloading Packages:
(1/8): libXext-devel-1.0. 100% |=========================| 57 kB 00:00
(2/8): mesa-libGLU-6.5.2- 100% |=========================| 204 kB 00:00
(3/8): libXrender-devel-0 100% |=========================| 9.0 kB 00:00
(4/8): SDL-1.2.12-1.fc7.i 100% |=========================| 219 kB 00:00
(5/8): SDL-devel-1.2.12-1 100% |=========================| 620 kB 00:00
(6/8): alsa-lib-devel-1.0 100% |=========================| 1.4 MB 00:00
(7/8): mesa-libGLU-devel- 100% |=========================| 93 kB 00:00
(8/8): libXrandr-devel-1. 100% |=========================| 16 kB 00:00
Running Transaction Test
Finished Transaction Test
Transaction Test Succeeded
Running Transaction
Installing: libXext-devel ######################### [1/8]
Installing: mesa-libGLU ######################### [2/8]
Installing: mesa-libGLU-devel ######################### [3/8]
Installing: libXrender-devel ######################### [4/8]
Installing: SDL ######################### [5/8]
Installing: alsa-lib-devel ######################### [6/8]
Installing: libXrandr-devel ######################### [7/8]
Installing: SDL-devel ######################### [8/8]

Installed: SDL.i386 0:1.2.12-1.fc7 SDL-devel.i386 0:1.2.12-1.fc7
Dependency Installed: alsa-lib-devel.i386 0:1.0.14-3.fc7 libXext-devel.i386 0:1.0.1-2.1 libXrandr-devel.i386 0:1.2.0-3.fc7 libXrender-devel.i386 0:0.9.2-1.fc7 mesa-libGLU.i386 0:6.5.2-13.fc7 mesa-libGLU-devel.i386 0:6.5.2-13.fc7
Complete!

なお、SDLを入れたら、gpac の configure で openGL もyesになりました。多分ヘッダーファイルが入ったからでは・・・

gpacをインストール

configureに実行権限がないので、まずそれを付けます。
$ chmod 544 configure
configureのヘルプを見てみます。
  Usage: configure [options]
    Options: [defaults in brackets after descriptions]

  GPAC configuration options:
    --help print this message
    --prefix=PREFIX install in PREFIX [/usr/local]
    --mandir=DIR man documentation in DIR [PREFIX/man]

    --source-path=PATH path of source code []
    --cross-prefix=PREFIX use PREFIX for compile tools []
    --cc=CC use C compiler CC [gcc]
    --make=MAKE use specified make [make]
    --extra-cflags=ECFLAGS add ECFLAGS to CFLAGS []
    --extra-ldflags=ELDFLAGS add ELDFLAGS to LDFLAGS [ -Wl,--warn-common]
    --extra-libs=ELIBS add ELIBS []
    --cpu=CPU force cpu to CPU [i686]
    --sdl-cfg=SDL_PATH specify path to sdl-config for local install []
    --enable-sdl-static use static SDL linking [default=no]
    --X11-path=X11_PATH specify path for X11 includes and libraries [/usr/X11R6]
    --dxsdk-path=DX_PATH specify directX SDK for MinGW []
    --mozdir=MOZ_PATH specify mozilla main directory path for system install

    --enable-debug produce debug version
    --enable-gprof enable profiling
    --track-memory enables tracking of all memory allocated by gpac
    --disable-fragments disable movie fragments in ISO media support
    --disable-opt disable GCC optimizations
    --disable-ipv6 disable IPV6 support
    --disable-wx disable wxWidgets support
    --disable-oss-audio disable OSS audio
    --disable-x11-shm disable X11 shared memory support
    --disable-fragments disable movie fragments in ISO media support
    --enable-readonly force ISO media to be read-only
    --disable-svg disable SVG support
    --enable-fixed-point enable fixed-point math (THIS MODIFIES GPAC MATH.H HEADER)
    --force-fixed-point force fixed-point math without changing gpac math.h header
    --disable-opengl disable OpenGL support
    --disable-ssl disable OpenSSL support
    --enable-amr-nb-fixed enable AMR NB fixed-point decoder
    --enable-amr-nb enable AMR NB library
    --enable-amr-wb enable AMR WB library
    --enable-amr enable both AMR NB and WB libraries

  Extra libraries configuration. You can turn a libray off or force using the local version in gpac/extra_lib/
    --use-js=OPT force SpiderMonkey ECMAScript OPT=[no,local]
    --use-ft=OPT force FreeType OPT=[no,local]
    --use-jpeg=OPT force JPEG OPT=[no,local]
    --use-png=OPT force PNG OPT=[no,local]
    --use-faad=OPT force FAAD OPT=[no,local]
    --use-mad=OPT force MAD OPT=[no,local]
    --use-xvid=OPT force XVID OPT=[no,local]
    --use-ffmpeg=OPT force FFMPEG OPT=[no,local]

  NOTE: The object files are build at the place where configure is launched

コンパイルオプションは以下を指定することにしました。
  --disable-wx : wxWidgetsを使いません。
 ディレクトリの指定はデフォルトのままなので/usr/local 以下にインストールされることになります。
configureします。

$ ./configure --disable-wx 2>&1 |tee configure.log
which: no wx-config in (環境変数PATHのリスト)

** System Configuration
Install prefix: /usr/local
Source path: /home/ユーザ名/src/gpac
C compiler: gcc
make: make
CPU: x86
Big Endian: no

** GPAC 0.4.4 Core Configuration **
debug version: no
GProf enabled: no
Memory tracking enabled: no
read-only version: no
fixed-point version: no
IPV6 Support: yes
IsoMedia MovieFragments support: yes
SVG Support disabled: no

** Detected libraries **
zlib: system
OSS Audio: yes
ALSA Audio: yes
X11 Shared Memory support: yes (path: /usr/X11R6)
SDL Support: yes
libXML2: yes
OpenGL support: yes
OpenSSL support: yes
DVB Support: yes
wxWidgets support: no

** Extra Libraries used **
SpiderMonkey: no
FreeType: system
JPEG: system
OpenJPEG: no
PNG: system
MAD: no
FAAD: system
XVID: no
FFMPEG: no
Xiph OGG: system
Xiph Vorbis: system
Xiph Theora: no

Creating config.mak
Done - type 'make help' for make info, 'make' to build
make します。make (= all) だと、インストールの必要がないOsmo4とosmozillaでエラーが出るので、 make lib と make apps を行います。こちらを参考にしました。
$ make lib 2>&1 |tee make_lib.log
$ make apps 2>&1 |tee make_apps.log
make lib は警告が出ましたが、一応通りました。
しかし、make apps でエラーが山程出ました。以下例です。
  ・・・/gpac/extra_lib/include/gecko-sdk/plugin/include/npapi.h:119:24: error: X11/Xlib.h: そのようなファイルやディレクトリはありません
  ・・・/gpac/extra_lib/include/gecko-sdk/plugin/include/npapi.h:120:25: error: X11/Xutil.h: そのようなファイルやディレクトリはありません
  osmozilla.h:50:27: error: X11/Intrinsic.h: そのようなファイルやディレクトリはあ りません
私の環境にはこれらのヘッダーファイルはありません。X11R6ウィンドウディスプレイシステム(= X Window System)用だそうです。
確かにFedora7をインストールする時に、 X 関係のパッケージグループを選んでいません。こんなところで必要になるとは・・・良い勉強になりました。
libX11関係のライブラリをインストールします。
$ su

# yum install libX11*
Loading "installonlyn" plugin
Setting up Install Process
Parsing package install arguments
fedora 100% |=========================| 2.1 kB 00:00
updates 100% |=========================| 2.3 kB 00:00
Resolving Dependencies
--> Running transaction check
---> Package libX11-devel.i386 0:1.0.3-8.fc7 set to be updated
--> Processing Dependency: libXdmcp-devel for package: libX11-devel
--> Processing Dependency: xorg-x11-proto-devel >= 7.1-2 for package: libX11-devel
--> Processing Dependency: libXau-devel for package: libX11-devel
--> Restarting Dependency Resolution with new changes.
--> Running transaction check
---> Package libXau-devel.i386 0:1.0.3-1.fc7 set to be updated
---> Package libX11-devel.i386 0:1.0.3-8.fc7 set to be updated
---> Package xorg-x11-proto-devel.i386 0:7.2-9.fc7 set to be updated
---> Package libXdmcp-devel.i386 0:1.0.2-2.fc7 set to be updated
--> Processing Dependency: mesa-libGL-devel for package: xorg-x11-proto-devel
--> Restarting Dependency Resolution with new changes.
--> Running transaction check
---> Package mesa-libGL-devel.i386 0:6.5.2-13.fc7 set to be updated
---> Package xorg-x11-proto-devel.i386 0:7.2-9.fc7 set to be updated

Dependencies Resolved

=============================================================================
Package Arch Version Repository Size
=============================================================================
Installing:
libX11-devel i386 1.0.3-8.fc7 fedora 664 k
Installing for dependencies:
libXau-devel i386 1.0.3-1.fc7 fedora 11 k
libXdmcp-devel i386 1.0.2-2.fc7 fedora 7.8 k
mesa-libGL-devel i386 6.5.2-13.fc7 updates 442 k
xorg-x11-proto-devel i386 7.2-9.fc7 fedora 284 k

Transaction Summary
=============================================================================
Install 5 Package(s)
Update 0 Package(s)
Remove 0 Package(s)

Total download size: 1.4 M
Is this ok [y/N]: y
Downloading Packages:
(1/5): libXdmcp-devel-1.0 100% |=========================| 7.8 kB 00:00
(2/5): xorg-x11-proto-dev 100% |=========================| 284 kB 00:00
(3/5): libX11-devel-1.0.3 100% |=========================| 664 kB 00:00
(4/5): libXau-devel-1.0.3 100% |=========================| 11 kB 00:00
(5/5): mesa-libGL-devel-6 100% |=========================| 442 kB 00:01
Running Transaction Test
Finished Transaction Test
Transaction Test Succeeded
Running Transaction
Installing: libXau-devel ######################### [1/5]
Installing: xorg-x11-proto-devel ######################### [2/5]
Installing: mesa-libGL-devel ######################### [3/5]
Installing: libX11-devel ######################### [4/5]
Installing: libXdmcp-devel ######################### [5/5]

Installed: libX11-devel.i386 0:1.0.3-8.fc7
Dependency Installed: libXau-devel.i386 0:1.0.3-1.fc7 libXdmcp-devel.i386 0:1.0.2-2.fc7 mesa-libGL-devel.i386 0:6.5.2-13.fc7 xorg-x11-proto-devel.i386 0:7.2-9.fc7
Complete!

libXt関係のライブラリもインストールします。
$ su

# yum install libXt*
Loading "installonlyn" plugin
Setting up Install Process
Parsing package install arguments
Resolving Dependencies
--> Running transaction check
---> Package libXt-devel.i386 0:1.0.4-1.fc7 set to be updated
---> Package libXtst-devel.i386 0:1.0.1-3.1 set to be updated
--> Processing Dependency: libSM-devel for package: libXt-devel
--> Restarting Dependency Resolution with new changes.
--> Running transaction check
---> Package libXt-devel.i386 0:1.0.4-1.fc7 set to be updated
---> Package libSM-devel.i386 0:1.0.2-1 set to be updated
--> Processing Dependency: libICE-devel for package: libSM-devel
--> Restarting Dependency Resolution with new changes.
--> Running transaction check
---> Package libICE-devel.i386 0:1.0.3-2.1.fc7 set to be updated
---> Package libSM-devel.i386 0:1.0.2-1 set to be updated
--> Processing Dependency: libICE = 1.0.3-2.1.fc7 for package: libICE-devel
--> Restarting Dependency Resolution with new changes.
--> Running transaction check
---> Package libICE-devel.i386 0:1.0.3-2.1.fc7 set to be updated
---> Package libICE.i386 0:1.0.3-2.1.fc7 set to be updated

Dependencies Resolved

=============================================================================
Package Arch Version Repository Size
=============================================================================
Installing:
libXt-devel i386 1.0.4-1.fc7 fedora 331 k
libXtst-devel i386 1.0.1-3.1 fedora 5.2 k
Installing for dependencies:
libICE-devel i386 1.0.3-2.1.fc7 updates 13 k
libSM-devel i386 1.0.2-1 fedora 9.5 k
Updating for dependencies:
libICE i386 1.0.3-2.1.fc7 updates 53 k

Transaction Summary
=============================================================================
Install 4 Package(s)
Update 1 Package(s)
Remove 0 Package(s)

Total download size: 411 k
Is this ok [y/N]: y
Downloading Packages:
(1/5): libXt-devel-1.0.4- 100% |=========================| 331 kB 00:00
(2/5): libSM-devel-1.0.2- 100% |=========================| 9.5 kB 00:00
(3/5): libICE-1.0.3-2.1.f 100% |=========================| 53 kB 00:00
(4/5): libXtst-devel-1.0. 100% |=========================| 5.2 kB 00:00
(5/5): libICE-devel-1.0.3 100% |=========================| 13 kB 00:00
Running Transaction Test
Finished Transaction Test
Transaction Test Succeeded
Running Transaction
Updating : libICE ######################### [1/6]
Installing: libICE-devel ######################### [2/6]
Installing: libSM-devel ######################### [3/6]
Installing: libXtst-devel ######################### [4/6]
Installing: libXt-devel ######################### [5/6]
Cleanup : libICE ######################### [6/6]

Installed: libXt-devel.i386 0:1.0.4-1.fc7 libXtst-devel.i386 0:1.0.1-3.1
Dependency Installed: libICE-devel.i386 0:1.0.3-2.1.fc7 libSM-devel.i386 0:1.0.2-1
Dependency Updated: libICE.i386 0:1.0.3-2.1.fc7
Complete!

再度、make apps を行うと何とか通りました。しかし、やはり警告は出ています。
インストールします。
$ su
# make install 2>&1 |tee install.log

インストールされました。 但し、以下のワーニングが出ていました。
  main.c:791: 警告: value computed is not used (計算された値が使われていません)
なお、libgpac_static.a やヘッダーファイルはコピーされませんので、手動でコピーしておきます。

# cp /home/ユーザ名/src/gpac/bin/gcc/libgpac_static.a /usr/local/lib
# cp -r /home/ユーザ名/src/gpac/include/gpac /usr/local/include/

動作確認

バージョンを確認してみます。
# MP4Box -version
MP4Box - GPAC version 0.4.4
GPAC Copyright: (c) Jean Le Feuvre 2000-2005
(c) ENST 2005-200X

.表示されました。OKなようです。

 


紆余曲折Tips