diff options
author | Martin Bravenboer <martin.bravenboer@logicblox.com> | 2004-10-06 11:32:20 +0000 |
---|---|---|
committer | Martin Bravenboer <martin.bravenboer@logicblox.com> | 2004-10-06 11:32:20 +0000 |
commit | 864839730491adaa6039ece8dca99ef27a8422d9 (patch) | |
tree | 701e42f8189f0c076969317e5c628f3f7f723b6c | |
parent | 5ef6c2a34e1480e11e04dde7a67d36fce9f6a242 (diff) | |
download | nixpkgs-864839730491adaa6039ece8dca99ef27a8422d9.tar nixpkgs-864839730491adaa6039ece8dca99ef27a8422d9.tar.gz nixpkgs-864839730491adaa6039ece8dca99ef27a8422d9.tar.bz2 nixpkgs-864839730491adaa6039ece8dca99ef27a8422d9.tar.lz nixpkgs-864839730491adaa6039ece8dca99ef27a8422d9.tar.xz nixpkgs-864839730491adaa6039ece8dca99ef27a8422d9.tar.zst nixpkgs-864839730491adaa6039ece8dca99ef27a8422d9.zip |
Finally, a real text editor in Nix. Todo: allow configuration with modes.
svn path=/nixpkgs/trunk/; revision=1543
-rw-r--r-- | pkgs/applications/editors/emacs/builder.sh | 13 | ||||
-rw-r--r-- | pkgs/applications/editors/emacs/default.nix | 14 | ||||
-rw-r--r-- | pkgs/applications/editors/emacs/patchfile | 41 | ||||
-rw-r--r-- | pkgs/system/all-packages-generic.nix | 4 |
4 files changed, 72 insertions, 0 deletions
diff --git a/pkgs/applications/editors/emacs/builder.sh b/pkgs/applications/editors/emacs/builder.sh new file mode 100644 index 00000000000..fa3516556a6 --- /dev/null +++ b/pkgs/applications/editors/emacs/builder.sh @@ -0,0 +1,13 @@ +. $stdenv/setup + +myglibc=`cat ${NIX_GCC}/nix-support/orig-glibc` +echo "glibc: $myglibc" + +postConfigure() { + cp $myglibc/lib/crt1.o src + cp $myglibc/lib/crti.o src + cp $myglibc/lib/crtn.o src +} +postConfigure=postConfigure + +genericBuild diff --git a/pkgs/applications/editors/emacs/default.nix b/pkgs/applications/editors/emacs/default.nix new file mode 100644 index 00000000000..0c4fefcba0d --- /dev/null +++ b/pkgs/applications/editors/emacs/default.nix @@ -0,0 +1,14 @@ +{stdenv, fetchurl, xlibs}: + +stdenv.mkDerivation { + name = "emacs-21.3"; + builder = ./builder.sh; + src = fetchurl { + url = http://ftp.gnu.org/pub/gnu/emacs/emacs-21.3.tar.gz; + md5 = "a0bab457cbf5b4f8eb99d1d0a3ada420"; + }; + patches = [./patchfile]; + inherit (xlibs) libXaw libX11; + + buildInputs = [xlibs.libXaw xlibs.libX11]; +} diff --git a/pkgs/applications/editors/emacs/patchfile b/pkgs/applications/editors/emacs/patchfile new file mode 100644 index 00000000000..93f17643a1a --- /dev/null +++ b/pkgs/applications/editors/emacs/patchfile @@ -0,0 +1,41 @@ +Only in emacs-21.3: configure.in~ +Only in emacs-21.3: patchfile +Only in emacs-21.3/src: Makefile.in~ +diff -rc emacs-orig/src/s/gnu-linux.h emacs-21.3/src/s/gnu-linux.h +*** emacs-orig/src/s/gnu-linux.h 2001-09-28 17:50:04.000000000 +0200 +--- emacs-21.3/src/s/gnu-linux.h 2004-10-06 13:13:19.000000000 +0200 +*************** +*** 173,179 **** + /* GNU/Linux usually has crt0.o in a non-standard place */ + #define START_FILES pre-crt0.o /usr/lib/crt0.o + #else +! #define START_FILES pre-crt0.o /usr/lib/crt1.o /usr/lib/crti.o + #endif + + #ifdef __ELF__ +--- 173,179 ---- + /* GNU/Linux usually has crt0.o in a non-standard place */ + #define START_FILES pre-crt0.o /usr/lib/crt0.o + #else +! #define START_FILES pre-crt0.o crt1.o crti.o + #endif + + #ifdef __ELF__ +*************** +*** 225,231 **** + #else + #undef LIB_GCC + #define LIB_GCC +! #define LIB_STANDARD -lgcc -lc -lgcc /usr/lib/crtn.o + #endif + + /* Don't use -g in test compiles in configure. +--- 225,231 ---- + #else + #undef LIB_GCC + #define LIB_GCC +! #define LIB_STANDARD -lgcc -lc -lgcc crtn.o + #endif + + /* Don't use -g in test compiles in configure. +Only in emacs-21.3/src/s: gnu-linux.h~ diff --git a/pkgs/system/all-packages-generic.nix b/pkgs/system/all-packages-generic.nix index 5ce66b94b97..0db0252c36d 100644 --- a/pkgs/system/all-packages-generic.nix +++ b/pkgs/system/all-packages-generic.nix @@ -860,6 +860,10 @@ rec { inherit (xlibs) libXt libXp libXext libX11; }; + emacs = (import ../applications/editors/emacs) { + inherit fetchurl stdenv xlibs; + }; + nxml = (import ../applications/editors/emacs/modes/nxml) { inherit fetchurl stdenv; }; |