Difference between revisions of "Solaris"

From VideoLAN Wiki
Jump to navigation Jump to search
(Undo revision 15706 by Fcartegnie (Talk))
(update)
Line 7: Line 7:
 
===  Solaris 10, SPARC ===
 
===  Solaris 10, SPARC ===
  
===== Requirements =====
+
===== Boostrapping process required packages =====
 +
 
 
<pre>CSWautoconf  autoconf - an extensible package of M4 macros
 
<pre>CSWautoconf  autoconf - an extensible package of M4 macros
 
             (all) 2.65,REV=2009.11.30
 
             (all) 2.65,REV=2009.11.30
Line 24: Line 25:
  
 
</pre>  
 
</pre>  
===== Bootstrapping  =====
 
 
Boostrap script needs to be able to run same subshells as parent.
 
If bootstrap fails on genmf, then the subshell has fallen back to the default /bin/sh which isn't posix compliant.
 
In that case, you need to patch as follow:
 
<pre>
 
@@ -97,7 +97,7 @@ AC_DEFUN([PKG_CHECK_MODULES],[ifelse([\$4], , :, [\$4])])
 
EOF
 
fi
 
 
-modules/genmf `sed -ne 's,modules/\(.*\)/Makefile,\1,p' configure.ac`
 
+$SHELL modules/genmf `sed -ne 's,modules/\(.*\)/Makefile,\1,p' configure.ac`
 
</pre>
 
 
<pre>ACLOCAL_ARGS="-I /usr/local/share/aclocal/"
 
 
export ACLOCAL_ARGS
 
 
/usr/xpg4/bin/sh bootstrap
 
</pre>
 
  
===== Configuring =====
+
===== Config & Build process required packages =====
 
<pre>CSWlua  lua - a powerful light-weight programming language
 
<pre>CSWlua  lua - a powerful light-weight programming language
 
         (sparc) 5.1.3,REV=2008.04.29
 
         (sparc) 5.1.3,REV=2008.04.29
Line 85: Line 66:
 
</pre>  
 
</pre>  
  
Using Sun Studio  
+
===== Setting up your environment  =====
 +
For Sun Studio
 +
Assuming compiler in /opt/sunstudio12.1 and some customly built packages in /opt/vlc
 +
 
 
<pre>
 
<pre>
 +
# Required for bootstrap
 +
export ACLOCAL_ARGS="-I /opt/csw/share/aclocal/"
 +
 +
# Required for configure
 +
export PATH=/opt/sunstudio12.1/bin::/opt/vlc/bin:/opt/csw/bin:/usr/xpg4/bin:/usr/sbin:/usr/bin:/usr/sfw/bin:/usr/ccs/bin:/usr/ucb
 +
 +
export LD_LIBRARY_PATH=/opt/vlc/lib:/opt/sunstudio12.1/lib:/opt/csw/lib
 +
#:/opt/SUNWmlib/lib:/usr/openwin/sfw/lib
  
export PKG_CONFIG_PATH=$PKG_CONFIG_PATH:/opt/csw/lib/pkgconfig/
+
export PKG_CONFIG_PATH=/opt/vlc/lib/pkgconfig:/opt/csw/lib/pkgconfig:/opt/vlc/qt/lib/pkgconfig:/usr/local/lib/pkgconfig
  
export LUA_LIBS='-L/opt/csw/lib/ -llua' LUA_CFLAGS='-I/opt/csw/include/'
+
export LUA_LIBS='-L/opt/vlc/lib -llua' LUA_CFLAGS='-I/opt/vlc/include'
  
export XLIB_XCB_CFLAGS='-I/opt/csw/include/xcb' XLIB_XCB_LIBS='-L/opt/csw/lib/'
+
export MAKE=gmake
 +
export CONFIG_SHELL='/usr/xpg4/bin/sh'
 +
export CCC=/opt/sunstudio12.1/bin/CC CC=/opt/sunstudio12.1/bin/cc MAKE=gmake
  
export CONFIG_SHELL='/usr/xpg4/bin/sh' CCC=/opt/SUNWspro/bin/CC CC=/opt/SUNWspro/bin/cc MAKE=gmake
+
export XLIB_XCB_CFLAGS='-I/opt/vlc/include/xcb/' XLIB_XCB_LIBS='-L/opt/vlc/lib/'
  
/usr/xpg4/bin/sh configure --includedir=/opt/csw/include/ --with-a52=/opt/csw/ --with-mad=/opt/csw/ --disable-libgcrypt --disable-remoteosd
+
# -D_XPG4_2 required for non-sparc code compatible network structs
 +
export CFLAGS="-I/opt/sunstudio12.1/include -I/usr/include -features=extensions -D _XPG4_2 -D __SunOS -D __STDC_ISO_10646__ -D __EXTENSIONS__"
 +
export CXXFLAGS="-I/opt/sunstudio12.1/include -features=extensions -D _XPG4_2 -D __SunOS -D __STDC_ISO_10646__ -D __EXTENSIONS__"
 
</pre>
 
</pre>
  
 
Using GCC
 
Using GCC
 +
Assuming some customly built packages in /opt/vlc
 +
<pre>
 +
# Required for bootstrap
 +
export ACLOCAL_ARGS="-I /opt/csw/share/aclocal/"
 +
 +
# Required for configure
 +
export PATH=/opt/vlc/bin:/opt/csw/bin:/usr/xpg4/bin:/usr/sbin:/usr/bin:/usr/sfw/bin:/usr/ccs/bin:/usr/ucb
 +
 +
export LD_LIBRARY_PATH=/opt/vlc/lib:/opt/csw/lib:/opt/SUNWmlib/lib:/usr/openwin/sfw/lib
 +
 +
export PKG_CONFIG_PATH=/opt/vlc/lib/pkgconfig:/opt/csw/lib/pkgconfig:/opt/vlc/qt/lib/pkgconfig:/usr/local/lib/pkgconfig
 +
 +
export LUA_LIBS='-L/opt/vlc/lib -llua' LUA_CFLAGS='-I/opt/vlc/include'
 +
 +
export MAKE=gmake
 +
export CONFIG_SHELL='/usr/xpg4/bin/sh'
 +
 +
# -D_XPG4_2 required for non-sparc code compatible network structs
 +
export CFLAGS="-D _XPG4_2 -D __SunOS -D __STDC_ISO_10646__ -D __EXTENSIONS__"
 +
export CXXFLAGS=$CFLAGS
  
<pre>
 
export CONFIG_SHELL='/usr/xpg4/bin/sh' CCC=/usr/sfw/bin/gcc CC=/usr/sfw/bin/gcc MAKE=gmake
 
 
</pre>
 
</pre>
  
===== Building =====
+
===== Bootstrapping  =====
  
Using Sun Studio
+
Boostrap script needs to be able to run same subshells as parent.
 +
If bootstrap fails on genmf, then the subshell has fallen back to the default /bin/sh which isn't posix compliant.
 +
In that case, you need to patch as follow:
 
<pre>
 
<pre>
export CFLAGS="-xc99=all -m32 -xarch=v8 -xchip=ultraT1 -xO2 -xcode=pic13 -features=extensions"
+
@@ -97,7 +97,7 @@ AC_DEFUN([PKG_CHECK_MODULES],[ifelse([\$4], , :, [\$4])])
export CXXFLAGS="-v -xlang=c99 -m32 -xarch=v8 -xchip=ultraT1 -xO2 -xcode=pic13 -features=extensions"
+
EOF
export CCASFLAGS=$CXXFLAGS
+
  fi
export MAKEFLAGS="-j32"
+
   
 +
-modules/genmf `sed -ne 's,modules/\(.*\)/Makefile,\1,p' configure.ac`
 +
+$SHELL modules/genmf `sed -ne 's,modules/\(.*\)/Makefile,\1,p' configure.ac`
 
</pre>
 
</pre>
  
Using GCC
+
<pre>ACLOCAL_ARGS="-I /usr/local/share/aclocal/"
<pre>
+
 
export CFLAGS="-D_XPG4_2 -D__EXTENSIONS__"
+
export ACLOCAL_ARGS
export CXXFLAGS="-D_XPG4_2 -D__EXTENSIONS__"
+
 
export CCASFLAGS=$CXXFLAGS
+
/usr/xpg4/bin/sh bootstrap
export MAKEFLAGS="-j32"
 
 
</pre>
 
</pre>

Revision as of 15:43, 25 May 2010

Build VLC on Solaris / OpenSolaris

Needs to be (maybe heavily) patched.

Some old packages exists [1]

Solaris 10, SPARC

Boostrapping process required packages
CSWautoconf  autoconf - an extensible package of M4 macros
             (all) 2.65,REV=2009.11.30
CSWautomake  automake - GNU Makefile generator inspired by 4.4BSD make and include
             (all) 1.10.3,REV=2009.12.09
CSWggettext  ggettext - GNU gettext
             (sparc) 0.17,REV=2009.05.27
CSWgm4       gm4 - The GNU m4 implementation of the traditional Unix macro processor
             (sparc) 1.4.13,REV=2009.04.06
CSWiconv     libiconv - GNU libiconv is a Unicode conversion library
             (sparc) 1.13.1,REV=2009.07.01
CSWlibtool   libtool - Generic shared library support script
             (sparc) 1.5.26,REV=2008.12.22
CSWreadline  readline - GNU readline
             (sparc) 5.2,REV=2009.01.23

Config & Build process required packages
CSWlua  lua - a powerful light-weight programming language
        (sparc) 5.1.3,REV=2008.04.29
**
CSWffmpeg  ffmpeg - very fast video and audio converter (includes libavcodec) - binaries
           (sparc) 0.4.9,REV=2008.06.03_rev=svn12629
**
CSWliba52  liba52 - free ATSC A/52 stream decoder
           (sparc) 0.7.4,REV=2007.03.05
**
CSWlibmad  libmad - MPEG Audio Decoder
           (sparc) 0.15.1,REV=2005.03.26_rev=b
**
CSWlibpthreadstubs  libpthreadstubs - pthread stubs not provided by native libc
                    (sparc) 0.1,REV=2008.11.16
**
CSWx264             x264 - H264/AVC video encoder
                    (sparc) 1.0.0,REV=2009.12.13
**
CSWlibxcb  libxcb - The XCB library
           (sparc) 1.1,REV=2008.11.16
CSWlibxcbdev  libxcb_dev - The XCB library
              (sparc) 1.1,REV=2008.11.16
CSWlibxau     libxau - X11 authorisation library
              (sparc) 1.0.4,REV=2008.11.17
CSWlibxaudev  libxau_dev - X11 authorisation library
              (sparc) 1.0.4,REV=2008.11.17
CSWxproto  xproto - xproto
           (sparc) 7.0.14,REV=2008.11.15
CSWlibxdmcp     libxdmcp - X11 authorisation library
                (sparc) 1.0.2,REV=2008.11.16
CSWlibxdmcpdev  libxdmcp_dev - X11 authorisation library
                (sparc) 1.0.2,REV=2008.11.16
CSWfribidi  fribidi - a free implementation of the Unicode Bidirectional Algorithm
            (sparc) 0.19.2,REV=2009.09.25
**
CSWqt  qt - A Cross-platform application framework for desktop and embedded development
       (sparc) 4.4.3,REV=2009.01.16
Setting up your environment

For Sun Studio Assuming compiler in /opt/sunstudio12.1 and some customly built packages in /opt/vlc

# Required for bootstrap 
export ACLOCAL_ARGS="-I /opt/csw/share/aclocal/" 

# Required for configure 
export PATH=/opt/sunstudio12.1/bin::/opt/vlc/bin:/opt/csw/bin:/usr/xpg4/bin:/usr/sbin:/usr/bin:/usr/sfw/bin:/usr/ccs/bin:/usr/ucb 

export LD_LIBRARY_PATH=/opt/vlc/lib:/opt/sunstudio12.1/lib:/opt/csw/lib
#:/opt/SUNWmlib/lib:/usr/openwin/sfw/lib

export PKG_CONFIG_PATH=/opt/vlc/lib/pkgconfig:/opt/csw/lib/pkgconfig:/opt/vlc/qt/lib/pkgconfig:/usr/local/lib/pkgconfig 

export LUA_LIBS='-L/opt/vlc/lib -llua' LUA_CFLAGS='-I/opt/vlc/include'

export MAKE=gmake 
export CONFIG_SHELL='/usr/xpg4/bin/sh' 
export CCC=/opt/sunstudio12.1/bin/CC CC=/opt/sunstudio12.1/bin/cc MAKE=gmake

export XLIB_XCB_CFLAGS='-I/opt/vlc/include/xcb/' XLIB_XCB_LIBS='-L/opt/vlc/lib/'

# -D_XPG4_2 required for non-sparc code compatible network structs
export CFLAGS="-I/opt/sunstudio12.1/include -I/usr/include -features=extensions -D _XPG4_2 -D __SunOS -D __STDC_ISO_10646__ -D __EXTENSIONS__" 
export CXXFLAGS="-I/opt/sunstudio12.1/include -features=extensions -D _XPG4_2 -D __SunOS -D __STDC_ISO_10646__ -D __EXTENSIONS__" 

Using GCC Assuming some customly built packages in /opt/vlc

# Required for bootstrap 
export ACLOCAL_ARGS="-I /opt/csw/share/aclocal/" 

# Required for configure
export PATH=/opt/vlc/bin:/opt/csw/bin:/usr/xpg4/bin:/usr/sbin:/usr/bin:/usr/sfw/bin:/usr/ccs/bin:/usr/ucb 

export LD_LIBRARY_PATH=/opt/vlc/lib:/opt/csw/lib:/opt/SUNWmlib/lib:/usr/openwin/sfw/lib

export PKG_CONFIG_PATH=/opt/vlc/lib/pkgconfig:/opt/csw/lib/pkgconfig:/opt/vlc/qt/lib/pkgconfig:/usr/local/lib/pkgconfig 

export LUA_LIBS='-L/opt/vlc/lib -llua' LUA_CFLAGS='-I/opt/vlc/include'

export MAKE=gmake 
export CONFIG_SHELL='/usr/xpg4/bin/sh'

# -D_XPG4_2 required for non-sparc code compatible network structs
export CFLAGS="-D _XPG4_2 -D __SunOS -D __STDC_ISO_10646__ -D __EXTENSIONS__" 
export CXXFLAGS=$CFLAGS 

Bootstrapping

Boostrap script needs to be able to run same subshells as parent. If bootstrap fails on genmf, then the subshell has fallen back to the default /bin/sh which isn't posix compliant. In that case, you need to patch as follow:

@@ -97,7 +97,7 @@ AC_DEFUN([PKG_CHECK_MODULES],[ifelse([\$4], , :, [\$4])])
 EOF
 fi
 
-modules/genmf `sed -ne 's,modules/\(.*\)/Makefile,\1,p' configure.ac`
+$SHELL modules/genmf `sed -ne 's,modules/\(.*\)/Makefile,\1,p' configure.ac`
ACLOCAL_ARGS="-I /usr/local/share/aclocal/"

export ACLOCAL_ARGS

/usr/xpg4/bin/sh bootstrap