diff options
author | Marc Weber <marco-oweber@gmx.de> | 2008-12-20 01:20:35 +0000 |
---|---|---|
committer | Marc Weber <marco-oweber@gmx.de> | 2008-12-20 01:20:35 +0000 |
commit | e996113be7f41f067aaefac881c540b5ceb8d2d4 (patch) | |
tree | 177f16552ca2d05020c3d45a0b45502556a09502 /pkgs/applications | |
parent | 5ab6464edb9bbc2a9aa15122ffc02b57ad236bb7 (diff) |
removed mkDerivationByConfiguration, using composableDerivation instead
qgis, vim_configurable both work now
svn path=/nixpkgs/trunk/; revision=13661
Diffstat (limited to 'pkgs/applications')
-rw-r--r-- | pkgs/applications/editors/vim/configurable.nix | 130 | ||||
-rw-r--r-- | pkgs/applications/misc/audio/sox/default.nix | 81 | ||||
-rw-r--r-- | pkgs/applications/misc/mrxvt/default.nix | 19 | ||||
-rw-r--r-- | pkgs/applications/misc/qgis/0.11.0.nix | 45 | ||||
-rw-r--r-- | pkgs/applications/misc/qgis_svn/default.nix | 74 | ||||
-rw-r--r-- | pkgs/applications/video/MPlayer/newconfig.nix | 255 |
6 files changed, 160 insertions, 444 deletions
diff --git a/pkgs/applications/editors/vim/configurable.nix b/pkgs/applications/editors/vim/configurable.nix index b27bb157f75a..0eac7ea5979f 100644 --- a/pkgs/applications/editors/vim/configurable.nix +++ b/pkgs/applications/editors/vim/configurable.nix @@ -1,72 +1,78 @@ # TODO tidy up eg The patchelf code is patching gvim even if you don't build it.. # but I have gvim with python support now :) - Marc -args: -let edf = args.lib.enableDisableFeature; in -( args.mkDerivationByConfiguration { - # most interpreters aren't tested yet.. (see python for example how to do it) - flagConfig = { - mandatory = { cfgOption = "--enable-gui=auto --with-features=${args.features}"; - buildInputs = ["ncurses" "pkgconfig"]; - }; - X11 = { buildInputs = [ "libX11" "libXext" "libSM" "libXpm" "libXt" "libXaw" "libXau" "libXmu" ]; }; +args: with args; +let inherit (args.composableDerivation) composableDerivation edf; in +composableDerivation { + initial = { - } // edf "darwin" "darwin" { } #Disable Darwin (Mac OS X) support. - // edf "xsmp" "xsmp" { } #Disable XSMP session management - // edf "xsmp_interact" "xsmp_interact" { } #Disable XSMP interaction - // edf "mzscheme" "mzschemeinterp" { } #Include MzScheme interpreter. - // edf "perl" "perlinterp" { } #Include Perl interpreter. - // edf "python" "pythoninterp" { pass = "python"; } #Include Python interpreter. - // edf "tcl" "tclinterp" { } #Include Tcl interpreter. - // edf "ruby" "rubyinterp" { } #Include Ruby interpreter. - // edf "cscope" "cscope" { } #Include cscope interface. - // edf "workshop" "workshop" { } #Include Sun Visual Workshop support. - // edf "netbeans" "netbeans" { } #Disable NetBeans integration support. - // edf "sniff" "sniff" { } #Include Sniff interface. - // edf "multibyte" "multibyte" { } #Include multibyte editing support. - // edf "hangulinput" "hangulinput" { } #Include Hangul input support. - // edf "xim" "xim" { pass = "xim"; } #Include XIM input support. - // edf "fontset" "fontset" { } #Include X fontset output support. + name = "vim_configurable-7.1"; - #--enable-gui=OPTS X11 GUI default=auto OPTS=auto/no/gtk/gtk2/gnome/gnome2/motif/athena/neXtaw/photon/carbon - /* - // edf "gtk_check" "gtk_check" { } #If auto-select GUI, check for GTK default=yes - // edf "gtk2_check" "gtk2_check" { } #If GTK GUI, check for GTK+ 2 default=yes - // edf "gnome_check" "gnome_check" { } #If GTK GUI, check for GNOME default=no - // edf "motif_check" "motif_check" { } #If auto-select GUI, check for Motif default=yes - // edf "athena_check" "athena_check" { } #If auto-select GUI, check for Athena default=yes - // edf "nextaw_check" "nextaw_check" { } #If auto-select GUI, check for neXtaw default=yes - // edf "carbon_check" "carbon_check" { } #If auto-select GUI, check for Carbon default=yes - // edf "gtktest" "gtktest" { } #Do not try to compile and run a test GTK program - */ - // edf "acl" "acl" { } #Don't check for ACL support. - // edf "gpm" "gpm" { } #Don't use gpm (Linux mouse daemon). - // edf "nls" "nls" { } #Don't support NLS (gettext()). - ; + src = args.fetchurl { + url = ftp://ftp.vim.org/pub/vim/unix/vim-7.2.tar.bz2; + sha256 = "11hxkb6r2550c4n13nwr0d8afvh30qjyr5c2hw16zgay43rb0kci"; + }; - optionals = ["python"]; + cfgOption = "--enable-gui=auto --with-features=${args.features}"; - extraAttrs = co : { - name = "vim_configurable-7.1"; + buildInputs = [ncurses pkgconfig] + ++ [ libX11 libXext libSM libXpm libXt libXaw libXau libXmu ]; - src = args.fetchurl { - url = ftp://ftp.nluug.nl/pub/editors/vim/unix/vim-7.1.tar.bz2; - sha256 = "0w6gy49gdbw7hby5rjkjpa7cdvc0z5iajsm4j1h8108rvfam22kz"; - }; + # most interpreters aren't tested yet.. (see python for example how to do it) + flags = {} + // edf { name = "darwin"; } #Disable Darwin (Mac OS X) support. + // edf { name = "xsmp"; } #Disable XSMP session management + // edf { name = "xsmp_interact"; } #Disable XSMP interaction + // edf { name = "mzscheme"; } #Include MzScheme interpreter. + // edf { name = "perl"; } #Include Perl interpreter. + // edf { name = "python"; feat = "pythoninterp"; enable = { buildInputs = [python]; }; } #Include Python interpreter. + // edf { name = "tcl"; } #Include Tcl interpreter. + // edf { name = "ruby"; } #Include Ruby interpreter. + // edf { name = "cscope"; } #Include cscope interface. + // edf { name = "workshop"; } #Include Sun Visual Workshop support. + // edf { name = "netbeans"; } #Disable NetBeans integration support. + // edf { name = "sniff"; } #Include Sniff interface. + // edf { name = "multibyte"; } #Include multibyte editing support. + // edf { name = "hangulinput"; } #Include Hangul input support. + # // edf { name = "xim"; enable = { buildInputs = [xim]; }; } #Include XIM input support. + // edf { name = "fontset"; } #Include X fontset output support. + // edf { name = "acl"; } #Don't check for ACL support. + // edf { name = "gpm"; } #Don't use gpm (Linux mouse daemon). + // edf { name = "nls"; } #Don't support NLS (gettext()). + ; + + cfg = { + pythonSupport = true; + }; + + #--enable-gui=OPTS X11 GUI default=auto OPTS=auto/no/gtk/gtk2/gnome/gnome2/motif/athena/neXtaw/photon/carbon + /* + // edf "gtk_check" "gtk_check" { } #If auto-select GUI, check for GTK default=yes + // edf "gtk2_check" "gtk2_check" { } #If GTK GUI, check for GTK+ 2 default=yes + // edf "gnome_check" "gnome_check" { } #If GTK GUI, check for GNOME default=no + // edf "motif_check" "motif_check" { } #If auto-select GUI, check for Motif default=yes + // edf "athena_check" "athena_check" { } #If auto-select GUI, check for Athena default=yes + // edf "nextaw_check" "nextaw_check" { } #If auto-select GUI, check for neXtaw default=yes + // edf "carbon_check" "carbon_check" { } #If auto-select GUI, check for Carbon default=yes + // edf "gtktest" "gtktest" { } #Do not try to compile and run a test GTK program + */ - postInstall = " - rpath=`patchelf --print-rpath \$out/bin/vim`; - for i in $\buildInputs; do - echo adding \$i/lib - rpath=\$rpath:\$i/lib - done - echo \$buildInputs - echo \$rpath - patchelf --set-rpath \$rpath \$out/bin/{vim,gvim} - "; + postInstall = " + rpath=`patchelf --print-rpath \$out/bin/vim`; + for i in $\buildInputs; do + echo adding \$i/lib + rpath=\$rpath:\$i/lib + done + echo \$buildInputs + echo \$rpath + patchelf --set-rpath \$rpath \$out/bin/{vim,gvim} + "; + dontStrip =1; + + meta = { + description = "The most popular clone of the VI editor"; + homepage = "www.vim.org"; + }; - meta = { - description = "The most popular clone of the VI editor"; - homepage = "www.vim.org"; }; -}; -} ) args + +} diff --git a/pkgs/applications/misc/audio/sox/default.nix b/pkgs/applications/misc/audio/sox/default.nix index c0cf9d91b730..1655457b4049 100644 --- a/pkgs/applications/misc/audio/sox/default.nix +++ b/pkgs/applications/misc/audio/sox/default.nix @@ -1,43 +1,9 @@ -args: -( args.mkDerivationByConfiguration { - flagConfig = { - mandatory = { implies = [ "no_oss" "no_sun_audio" ]; }; - # are these options of interest? We'll see - #--disable-fftw disable usage of FFTW - #--enable-debug enable debugging - #--disable-cpu-clip disable tricky cpu specific clipper - alsa = { cfgOption = "--enable-alsa"; buildInputs = "alsa"; }; - no_alsa = { cfgOption = "--disable-alsa"; }; - libao = { cfgOption = "--enable-libao"; buildInputs = "libao"; }; - no_libao = { cfgOption = "--disable-libao"; }; - #oss = { cfgOption = "--enable-oss"; buildInputs = "oss"; }; - no_oss = { cfgOption = "--disable-oss"; }; - #sun_audio = { cfgOption = "--enable-sun-audio"; buildInputs = "sun_audio"; }; - no_sun_audio = { cfgOption = "--disable-sun_audio"; }; - - # These options should be autodetected by the configure script - /* - --without-sndfile Don't try to use libsndfile - --without-ogg Don't try to use Ogg Vorbis - --without-flac Don't try to use FLAC - --without-ffmpeg Don't try to use ffmpeg - --without-mad Don't try to use MAD (MP3 Audio Decoder) - --without-lame Don't try to use LAME (LAME Ain't an MP3 Encoder) - --without-amr-wb Don't try to use amr-wb - --without-amr-nb Don't try to use amr-nb - --without-samplerate Don't try to use libsamplerate (aka Secret Rabbit - Code) - --without-ladspa Don't try to use LADSPA - --with-ladspa-path Default search path for LADSPA plugins - */ - }; - - optionals = [ "libsndfile" "libogg" "flac" "ffmpeg" "libmad" "lame" - /* "amr-wb" "amr-nb" */ - "libsamplerate" /* "ladspa" */ ]; +args: with args; +let inherit (args.composableDerivation) composableDerivation edf; in +composableDerivation { + initial = { - extraAttrs = co : { name = "sox-14.0.0"; src = args.fetchurl { @@ -45,6 +11,43 @@ args: sha256 = "1l7v04nlvb96y0w9crvm6nq8g50yxp3bkv6nb1c205s982inlalc"; }; + flags = + # are these options of interest? We'll see + #--disable-fftw disable usage of FFTW + #--enable-debug enable debugging + #--disable-cpu-clip disable tricky cpu specific clipper + edf { name = "alsa"; enable = { buildInputs = [alsaLib]; }; } + // edf { name = "libao"; enable = { buildInputs = [libao]; }; } + // edf { name = "oss"; } + // edf { name = "sun_audio"; }; + # These options should be autodetected by the configure script + /* + --without-sndfile Don't try to use libsndfile + --without-ogg Don't try to use Ogg Vorbis + --without-flac Don't try to use FLAC + --without-ffmpeg Don't try to use ffmpeg + --without-mad Don't try to use MAD (MP3 Audio Decoder) + --without-lame Don't try to use LAME (LAME Ain't an MP3 Encoder) + --without-amr-wb Don't try to use amr-wb + --without-amr-nb Don't try to use amr-nb + --without-samplerate Don't try to use libsamplerate (aka Secret Rabbit + Code) + --without-ladspa Don't try to use LADSPA + --with-ladspa-path Default search path for LADSPA plugins + */ + + + cfg = { + ossSupport = false; + sun_audioSupport = false; + }; + + + optionals = [ "libsndfile" "libogg" "flac" "ffmpeg" "libmad" "lame" + /* "amr-wb" "amr-nb" */ + "libsamplerate" /* "ladspa" */ ]; + + meta = { description = "Sample Rate Converter for audio"; homepage = http://www.mega-nerd.com/SRC/index.html; @@ -55,4 +58,4 @@ args: } ]; }; }; -} ) args +} diff --git a/pkgs/applications/misc/mrxvt/default.nix b/pkgs/applications/misc/mrxvt/default.nix index f58fff56bc08..346ae2b50cd4 100644 --- a/pkgs/applications/misc/mrxvt/default.nix +++ b/pkgs/applications/misc/mrxvt/default.nix @@ -1,26 +1,17 @@ -args: with args.lib; with args; +args: with args; +stdenv.mkDerivation { -let - co = chooseOptionsByFlags { - inherit args; - flagDescr = { - mandatory = { buildInputs = [ "libX11" ]; cfgOption = "--with-x"; }; - # many options to add here ... :) - # many of them can be set by configuration file I think.. - }; -}; + name = "mrxvt-0.5.3"; -in stdenv.mkDerivation { + buildInputs = [libX11]; - inherit (co) buildInputs configureFlags; + configureFlags="--with-x"; src = fetchurl { url = mirror://sourceforge/materm/mrxvt-0.5.3.tar.gz; sha256 = "04flnn58hp4qvvk6jzyipsj13v1qyrjabgbw5laz5cqxvxzpncp2"; }; - name = "mrxvt-0.5.3"; - meta = { description = "multitabbed lightweight terminal emulator basd on rxvt supporting transparency, backgroundimages, freetype fonts,.."; homepage = http://sourceforge.net/projects/materm; diff --git a/pkgs/applications/misc/qgis/0.11.0.nix b/pkgs/applications/misc/qgis/0.11.0.nix new file mode 100644 index 000000000000..127675b358d5 --- /dev/null +++ b/pkgs/applications/misc/qgis/0.11.0.nix @@ -0,0 +1,45 @@ +args: with args; +let edf = composableDerivation.edf; + optionIncLib = name : attr : " -D${name}_INCLUDE_DIR=${__getAttr attr args}/incclude" + + " -D${name}_LIBRARY=${__getAttr attr args}/lib "; # lib 64? +in +composableDerivation.composableDerivation { + initial = { + + buildInputs = [ gdal cmake qt flex bison proj geos x11 sqlite gsl]; + cfgOption = [ + # without this option it can't find sqlite libs yet (missing symbols..) (TODO) + "-DWITH_INTERNAL_SQLITE3=TRUE" + ]; + + name = "qgis-${version}"; + + # src = args.fetchsvn { url=https://svn.qgis.org/repos/qgis/trunk/qgis; + # md5="ac0560e0a2d4e6258c8639f1e9b56df3"; rev="7704"; }; + src = fetchurl { + url = "http://download.osgeo.org/qgis/src/qgis_${version}.tar.gz"; + sha256 = "17vqbld4wr9jyn1s5n0bkpaminsgc2dzcgdfk8ic168xydnwa7b3"; + }; + + meta = { + description = "user friendly Open Source Geographic Information System"; + homepage = http://www.qgis.org; + # you can choose one of the following licenses: + license = [ "GPL" ]; + }; + + phases = "unpackPhase buildPhase installPhase"; + buildPhase = ''pwd;echo XXXXXXXXX; VERBOSE=1 cmake -DCMAKE_INSTALL_PREFIX=$out ''${cfgOption} ..''; + + postUnpack = '' + export CMAKE_SYSTEM_LIBRARY_PATH= + for i in $buildInputs $propagatedBuildInputs; do + CMAKE_SYSTEM_LIBRARY_PATH=$i/lib:$CMAKE_SYSTEM_LIBRARY_PATH + done + ''; + + #configurePhase="./autogen.sh --prefix=\$out --with-gdal=\$gdal/bin/gdal-config --with-qtdir=\$qt"; + # buildPhases="unpackPhase buildPhase"; + + }; +} diff --git a/pkgs/applications/misc/qgis_svn/default.nix b/pkgs/applications/misc/qgis_svn/default.nix deleted file mode 100644 index 547e941ecac8..000000000000 --- a/pkgs/applications/misc/qgis_svn/default.nix +++ /dev/null @@ -1,74 +0,0 @@ -args: -let optionIncLib = name : attr : " -D${name}_INCLUDE_DIR=${__getAttr attr args}/inc" - + " -D${name}_LIBRARY=${__getAttr attr args}/lib "; # lib 64? -in -( args.mkDerivationByConfiguration { - - flagConfig = { - mandatory = { - buildInputs = [ "gdal" "cmake" "qt" "flex" "bison" "proj" "geos" "x11" "sqlite" "gsl"]; - cfgOption = [ (optionIncLib "GEOS" "geos") - (optionIncLib "PROJ" "proj") - (optionIncLib "QT_X11_X11" "qt") - (optionIncLib "QT_X11_Xext" "qt") - (optionIncLib "QT_X11_m" "glibc") - (optionIncLib "SQLITE3" "sqlite") - -"-DQT_FONTCONFIG_LIBRARY=${args.fontconfig}/lib" -"-DQT_FREETYPE_LIBRARY=${args.freetype}/lib" -"-DQT_PNG_LIBRARY=${args.libpng}/lib" -"-DQT_X11_ICE_LIBRARY=${args.libICE}/lib" -"-DQT_X11_SM_LIBRARY=${args.libSM}/lib" -"-DQT_XCURSOR_LIBRARY=${args.libXcursor}/lib" -"-DQT_XINERAMA_LIBRARY=${args.libXinerama}/lib" -"-DQT_XRANDR_LIBRARY=${args.libXrandr}/lib" -"-DQT_XRENDER_LIBRARY=${args.libXrender}/lib" -"-DQT_ZLIB_LIBRARY=${args.zlib}/lib" - ]; - -/* advanced options - feel free to add them if you have time to -"-DPROJ_INCLUDE_DIR" -"-DPROJ_LIBRARY" -"-DQT_X11_X11_LIBRARY" -"-DQT_X11_Xext_LIBRARY" -"-DQT_X11_m_LIBRARY" -"-DSQLITE3_INCLUDE_DIR" -"-DSQLITE3_LIBRARY" --DQT_FONTCONFIG_LIBRARY (ADVANCED) --DQT_FREETYPE_LIBRARY (ADVANCED) --DQT_PNG_LIBRARY (ADVANCED) --DQT_X11_ICE_LIBRARY (ADVANCED) --DQT_X11_SM_LIBRARY (ADVANCED) --DQT_XCURSOR_LIBRARY (ADVANCED) --DQT_XINERAMA_LIBRARY (ADVANCED) --DQT_XRANDR_LIBRARY (ADVANCED) --DQT_XRENDER_LIBRARY (ADVANCED) --DQT_ZLIB_LIBRARY (ADVANCED) -*/ - }; - }; - - #inherit geos proj x11 libXext; - - extraAttrs = co : { - - name = "qgis-svn"; - - src = args.fetchsvn { url=https://svn.qgis.org/repos/qgis/trunk/qgis; - md5="ac0560e0a2d4e6258c8639f1e9b56df3"; rev="7704"; }; - - meta = { - description = "user friendly Open Source Geographic Information System"; - homepage = http://www.qgis.org; - # you can choose one of the following licenses: - license = [ "GPL" ]; - }; - - phases = "unpackPhase buildPhase installPhase"; - buildPhase = "cmake -DCMAKE_INSTALL_PREFIX=\$out ${co.configureFlags} ."; - - #configurePhase="./autogen.sh --prefix=\$out --with-gdal=\$gdal/bin/gdal-config --with-qtdir=\$qt"; - # buildPhases="unpackPhase buildPhase"; - }; - -} ) args diff --git a/pkgs/applications/video/MPlayer/newconfig.nix b/pkgs/applications/video/MPlayer/newconfig.nix deleted file mode 100644 index 323619e00329..000000000000 --- a/pkgs/applications/video/MPlayer/newconfig.nix +++ /dev/null @@ -1,255 +0,0 @@ -# this nix expression is not well tested (experimental!) -args: with args.lib; with args; -let - win32codecs = (import ./win32codecs) { - inherit stdenv fetchurl; - }; - co = chooseOptionsByFlags { - inherit args; - flagConfig = { - # FIXME: we only have to pass X11 if we want to use a X11 driver - mandatory = { buildInputs = [ "x11" "libX11" "freetype" "zlib" ]; }; - - # FIXME this options are still a mess.. :) feel free to test and implement the missing ones - - # Optional features - #--disable-mencoder disable mencoder (a/v encoder) compilation [enable] - #--enable-gui enable gmplayer compilation (GTK+ GUI) [disable] - #--enable-gtk1 force using GTK 1.2 for GUI [disable] - #--enable-largefiles enable support for files > 2 GBytes [disable] - #--enable-linux-devfs set default devices to devfs ones [disable] - #--enable-termcap use termcap database for key codes [autodetect] - #--enable-termios use termios database for key codes [autodetect] - #--disable-iconv do not use iconv(3) function [autodetect] - #--disable-langinfo do not use langinfo [autodetect] - #--enable-lirc enable LIRC (remote control) support [autodetect] - #--enable-lircc enable LIRCCD (LIRC client daemon) input [autodetect] - #--enable-joystick enable joystick support [disable] - #--disable-vm disable support X video mode extensions [autodetect] - #--disable-xf86keysym disable support for 'multimedia' keys [autodetect] - #--enable-radio enable Radio Interface [disable] - #--enable-radio-capture enable Capture for Radio Interface (through pci/line-in) [disable] - #--disable-radio-v4l2 disable Video4Linux2 Radio Interface support [autodetect] - #--disable-tv disable TV Interface (tv/dvb grabbers) [enable] - #--disable-tv-v4l1 disable Video4Linux TV Interface support [autodetect] - #--disable-tv-v4l2 disable Video4Linux2 TV Interface support [autodetect] - #--disable-tv-bsdbt848 disable BSD BT848 Interface support [autodetect] - #--disable-pvr disable Video4Linux2 MPEG PVR support [autodetect] - #--disable-rtc disable RTC (/dev/rtc) on Linux [autodetect] - #--disable-network disable network support (for: http/mms/rtp) [enable] - #--enable-winsock2 enable winsock2 usage [autodetect] - #--enable-smb enable Samba (SMB) input support [autodetect] - #--enable-live enable LIVE555 Streaming Media support [autodetect] - #--disable-dvdnav disable libdvdnav support [autodetect] - #--disable-dvdread Disable libdvdread support [autodetect] - #--disable-mpdvdkit Disable mpdvdkit2 support [autodetect] - #--disable-cdparanoia Disable cdparanoia support [autodetect] - #--disable-bitmap-font Disable bitmap font support [enable] - #--disable-freetype Disable freetype2 font rendering support [autodetect] - #--disable-fontconfig Disable fontconfig font lookup support [autodetect] - #--disable-unrarlib Disable Unique RAR File Library [enabled] - #--enable-menu Enable OSD menu support (NOT DVD MENU) [disabled] - #--disable-sortsub Disable subtitles sorting [enabled] - #--enable-fribidi Enable using the FriBiDi libs [autodetect] - #--disable-enca Disable using ENCA charset oracle library [autodetect] - #--disable-macosx Disable Mac OS X specific features [autodetect] - #--disable-maemo Disable maemo specific features [autodetect] - #--enable-macosx-finder-support Enable Mac OS X Finder invocation parameter parsing [disabled] - #--enable-macosx-bundle Enable Mac OS X bundle file locations [autodetect] - #--disable-inet6 Disable IPv6 support [autodetect] - #--disable-gethostbyname2 gethostbyname() function is not provided by the C - #library [autodetect] - #--disable-ftp Disable ftp support [enabled] - #--disable-vstream Disable tivo vstream client support [autodetect] - #--disable-pthreads Disable Posix threads support [autodetect] - #--disable-ass Disable internal SSA/ASS subtitles support [autodetect] - #--enable-rpath Enable runtime linker path for extra libs [disabled] - - # Codecs - #--enable-png enable png input/output support [autodetect] - #--enable-jpeg enable jpeg input/output support [autodetect] - #--enable-libcdio enable external libcdio support [autodetect] - #--enable-liblzo enable external liblzo support [autodetect] - #--disable-win32 disable Win32 DLL support [autodetect] - #--disable-qtx disable Quicktime codecs [autodetect] - #--disable-xanim disable XAnim DLL support [autodetect] - #--disable-real disable RealPlayer DLL support [autodetect] - #--disable-xvid disable XviD codec [autodetect] - #--disable-x264 disable H.264 encoder [autodetect] - #--disable-nut disable libnut demuxer [autodetect] - #--disable-libavutil disable libavutil [autodetect] - #--disable-libavcodec disable libavcodec [autodetect] - #--disable-libavformat disable libavformat [autodetect] - #--disable-libpostproc disable libpostproc [autodetect] - #--disable-libavutil_so disable shared libavutil [autodetect] - #--disable-libavcodec_so disable shared libavcodec [autodetect] - #--disable-libavformat_so disable shared libavformat [autodetect] - #--disable-libpostproc_so disable shared libpostproc [autodetect] - #--disable-libavcodec_mpegaudio_hp disable high precision audio decoding - # in libavcodec [enabled] - #--enable-libfame enable libfame realtime encoder [autodetect] - #--disable-tremor-internal do not build internal Tremor support [enabled] - #--enable-tremor-low build with lower accuracy internal Tremor [disabled] - #--enable-tremor-external build with external Tremor [autodetect] - #--disable-libvorbis disable libvorbis support [autodetect] - #--disable-speex disable Speex support [autodetect] - theora = { cfgOption = "--enable-theora"; buildInputs = "libtheora"; }; - #--enable-theora build with OggTheora support [autodetect] - #--enable-faad-external build with external FAAD2 (AAC) support [autodetect] - #--disable-faad-internal disable internal FAAD2 (AAC) support [autodetect] - #--enable-faad-fixed enable fixed-point mode in internal FAAD2 [disabled] - #--disable-faac disable support for FAAC (AAC encoder) [autodetect] - #--disable-ladspa disable LADSPA plugin support [autodetect] - #--disable-libdv disable libdv 0.9.5 en/decoding support [autodetect] - #--disable-mad disable libmad (MPEG audio) support [autodetect] - #--disable-toolame disable Toolame (MPEG layer 2 audio) support in mencoder [autodetect] - #--disable-twolame disable Twolame (MPEG layer 2 audio) support in mencoder [autodetect] - #--enable-xmms build with XMMS inputplugin support [disabled] - #--disable-mp3lib disable builtin mp3lib [enabled] - #--disable-liba52 disable builtin liba52 [enabled] - #--enable-libdts enable libdts support [autodetect] - #--disable-libmpeg2 disable builtin libmpeg2 [enabled] - #--disable-musepack disable musepack support [autodetect] - #--disable-amr_nb disable amr narrowband, floating point [autodetect] - #--disable-amr_nb-fixed disable amr narrowband, fixed point [autodetect] - #--disable-amr_wb disable amr wideband, floating point [autodetect] - #--disable-decoder=DECODER disable specified FFmpeg decoder - #--enable-decoder=DECODER enable specified FFmpeg decoder - #--disable-encoder=ENCODER disable specified FFmpeg encoder - #--enable-encoder=ENCODER enable specified FFmpeg encoder - #--disable-parser=PARSER disable specified FFmpeg parser - #--enable-parser=PARSER enable specified FFmpeg parser - #--disable-demuxer=DEMUXER disable specified FFmpeg demuxer - #--enable-demuxer=DEMUXER enable specified FFmpeg demuxer - #--disable-muxer=MUXER disable specified FFmpeg muxer - #--enable-muxer=MUXER enable specified FFmpeg muxer--enable-muxer=MUXER enable specified FFmpeg muxer - - # Video output - #--disable-vidix-internal disable internal VIDIX [for x86 *nix] - #--disable-vidix-external disable external VIDIX [for x86 *nix] - #--enable-gl build with OpenGL render support [autodetect] - #--enable-dga[=n] build with DGA [n in {1, 2} ] support [autodetect] - #--enable-vesa build with VESA support [autodetect] - #--enable-svga build with SVGAlib support [autodetect] - #--enable-sdl build with SDL render support [autodetect] - #--enable-aa build with AAlib render support [autodetect] - caca = { cfgOption = "--enable-caca"; buildInputs = "libcaca"; }; # CACA render support - #--enable-ggi build with GGI render support [autodetect] - #--enable-ggiwmh build with GGI libggiwmh extension [autodetect] - #--enable-directx build with DirectX support [autodetect] - #--enable-dxr2 build with DXR2 render support [autodetect] - #--enable-dxr3 build with DXR3/H+ render support [autodetect] - #--enable-ivtv build with IVTV TV-Out render support [autodetect] - #--enable-dvb build with support for output via DVB-Card [autodetect] - #--enable-dvbhead build with DVB support (HEAD version) [autodetect] - #--enable-mga build with mga_vid (for Matrox G200/G4x0/G550) support - # (check for /dev/mga_vid) [autodetect] - #--enable-xmga build with mga_vid X Window support - # (check for X & /dev/mga_vid) [autodetect] - xv = { cfgOption = "--enable-xv"; buildInputs = "libXv"; }; # Xv render support for X 4.x - #--enable-xvmc build with XvMC acceleration for X 4.x [disable] - #--enable-vm build with XF86VidMode support for X11 [autodetect] - xinerama = { cfgOption = "--enable-xinerama"; buildInputs = "libXinerama"; }; # Xinerama support for X11 - #--enable-x11 build with X11 render support [autodetect] - #--enable-xshape build with XShape support [autodetect] - #--enable-fbdev build with FBDev render support [autodetect] - #--enable-mlib build with mediaLib support (Solaris only) [disable] - #--enable-3dfx build with obsolete /dev/3dfx support [disable] - #--enable-tdfxfb build with tdfxfb (Voodoo 3/banshee) support [disable] - #--enable-s3fb build with s3fb (S3 ViRGE) support [disable] - #--enable-directfb build with DirectFB support [autodetect] - #--enable-zr build with ZR360[56]7/ZR36060 support [autodetect] - #--enable-bl build with Blinkenlights support [disable] - #--enable-tdfxvid build with tdfx_vid support [disable] - #--disable-tga disable targa output support [enable] - #--disable-pnm disable pnm output support [enable] - #--disable-md5sum disable md5sum output support [enable] - - - # Audio Output (they are all autodetect but adding the enable flag will show \ - # wrong cofigured libraries I hope) - # the ones beeing commented out I don't know exactly which libraries they need? - alsa = { cfgOption = "--enable-alsa"; buildInputs = "alsaLib"; }; - #oss = { cfgOption = "--enable-oss"; buildInputs = "oss"; }; - #arts = { cfgOption = "--enable-arts"; buildInputs = "arts"; }; - esd = { cfgOption = "--enable-esd"; buildInputs = "esound"; }; - #polyp = { cfgOption = "--enable-polyp"; buildInputs = "polyp"; }; - #jack = { cfgOption = "--enable-jack"; buildInputs = "jack"; }; - #openal = { cfgOption = "--enable-openal"; buildInputs = "openal"; }; - #nas = { cfgOption = "--enable-nas"; buildInputs = "nas"; }; - #sgiaudio = { cfgOption = "--enable-sgiaudio"; buildInputs = "sgiaudio"; }; - #sunaudio = { cfgOption = "--enable-sunaudio"; buildInputs = "sunaudio"; }; - #win32waveout = { cfgOption = "--enable-win32waveout"; buildInputs = "win32waveout"; }; - - disableSelect = { cfgOption = "--disable-select"; }; # disable using select() on audio device [enable] - - #Miscellaneous options: - #--enable-runtime-cpudetection Enable runtime CPU detection [disable] - #--enable-cross-compile Enable cross-compilation [autodetect] - #--cc=COMPILER use this C compiler to build MPlayer [gcc] - #--host-cc=COMPILER use this C compiler to build apps needed for the build process [gcc] - #--as=ASSEMBLER use this assembler to build MPlayer [as] - #--target=PLATFORM target platform (i386-linux, arm-linux, etc) - #--enable-static build a statically linked binary. Set further linking - #options with --enable-static="-lslang -lncurses" - #--charset convert the help messages to this charset - #--language=list a white space or comma separated list of languages - #for translated man pages, the first language is the - #primary and therefore used for translated messages - #and GUI (also the environment variable $LINGUAS is - #honored) [en] - #(Available: bg cs de dk el en es fr hu it ja ko mk nb nl pl ro ru sk sv tr uk pt_BR zh - #_CN zh_TW all) - - }; - optionals = [ "esound" "alsa" "xv" "theora" "caca" "xinerama" "libXrandr" "esd" ]; - }; - -in args.stdenv.mkDerivation { - - inherit (co) buildInputs; - - name = "MPlayer-1.0rc1try2NewConfig"; - #name = "MPlayer-snapshot"; - - #src = fetchurl { - # url = http://www7.mplayerhq.hu/MPlayer/releases/mplayer-checkout-snapshot.tar.bz2; - # sha1 = "529682cdea4f412d35f2c456897ab8808810975c"; - #}; - - src = fetchurl { - url = http://www1.mplayerhq.hu/MPlayer/releases/MPlayer-1.0rc1.tar.bz2; - sha1 = "a450c0b0749c343a8496ba7810363c9d46dfa73c"; - }; - - configurePhase = "./configure --prefix=\$out " + co.configureFlags - # FIXME to which options do these settings belong? - + " --with-win32libdir=${win32codecs}" - + " --with-reallibdir=${win32codecs}" - + " --enable-runtime-cpudetection" - + " --enable-x11" - + " --with-x11libdir=/no-such-dir" - + " --with-extraincdir=${libX11}/include" - + " --disable-xanim"; - - # Provide a reasonable standard font. Maybe we should symlink here. - postInstall = "cp ${freefont_ttf}/share/fonts/truetype/FreeSans.ttf $out/share/mplayer/subfont.ttf"; - - patches = [ - # These fix MPlayer's aspect ratio when run in a screen rotated with - # Xrandr. - # See: http://itdp.de/~itdp/html/mplayer-dev-eng/2005-08/msg00427.html - ./mplayer-aspect.patch - ./mplayer-pivot.patch - - # Security fix. - ./asmrules-fix.patch - ]; - - meta = { - homepage = http://www.mplayerhq.hu/; - description = "A movie player that supports many video formats"; - license = "GPL-2"; - }; - -} |