lol
at 23.11-beta 74 lines 1.9 kB view raw
1{ lib, stdenv, fetchurl 2, libX11, bison, ksh, perl 3, libXinerama, libXt, libXext, libtirpc, motif, libXft, xbitmaps 4, libjpeg, libXmu, libXdmcp, libXScrnSaver, bdftopcf 5, ncompress, mkfontdir, tcl, libXaw, libxcrypt, glibcLocales 6, autoPatchelfHook, makeWrapper, xset, xrdb 7, autoreconfHook, opensp, flex, libXpm 8, rpcsvc-proto }: 9 10stdenv.mkDerivation rec { 11 pname = "cde"; 12 version = "2.5.1"; 13 14 src = fetchurl { 15 url = "mirror://sourceforge/cdesktopenv/cde-${version}.tar.gz"; 16 hash = "sha256-caslezz2kbljwApv5igDPH345PK2YqQUTi1YZgvM1Dw="; 17 }; 18 19 postPatch = '' 20 for f in $(find . -type f ! -path doc/common); do 21 sed -i \ 22 -e "s|/usr/dt|$out|g" \ 23 -e "s|/etc/dt|$out/etc|g" \ 24 -e "s|\$(DESTDIR)/var|$out/var|g" \ 25 "$f" 26 done 27 28 for f in $(find . -type f -name "Makefile.am"); do 29 sed -i \ 30 -e "/chown /d" \ 31 -e "/chgrp /d" \ 32 -e "s/chmod 4755/chmod 755/g" \ 33 "$f" 34 done 35 36 substituteInPlace configure.ac \ 37 --replace "-I/usr/include/tirpc" "-I${libtirpc.dev}/include/tirpc" 38 39 patchShebangs autogen.sh config.rpath contrib programs 40 ''; 41 42 buildInputs = [ 43 libX11 libXinerama libXt libXext libtirpc motif libXft xbitmaps 44 libjpeg libXmu libXdmcp libXScrnSaver tcl libXaw ksh libxcrypt 45 libXpm 46 ]; 47 nativeBuildInputs = [ 48 bison ncompress autoPatchelfHook makeWrapper 49 autoreconfHook bdftopcf mkfontdir xset xrdb opensp perl flex 50 rpcsvc-proto 51 ]; 52 53 enableParallelBuilding = true; 54 55 preConfigure = '' 56 export LOCALE_ARCHIVE="${glibcLocales}/lib/locale/locale-archive" 57 ''; 58 59 configureFlags = [ 60 "--with-tcl=${tcl}/lib" 61 ]; 62 63 preInstall = '' 64 mkdir -p $out/opt/dt/bin 65 ''; 66 67 meta = with lib; { 68 description = "Common Desktop Environment"; 69 homepage = "https://sourceforge.net/projects/cdesktopenv/"; 70 license = licenses.lgpl2; 71 maintainers = [ ]; 72 platforms = platforms.linux; 73 }; 74}