[e3/f19] Initial import #785312
mmckinst
mmckinst at fedoraproject.org
Fri May 10 15:06:23 UTC 2013
commit 37877606b76d730dbb84dbc6992d4f608a3526ed
Author: Mark McKinstry <mmckinst at nexcess.net>
Date: Fri May 10 11:04:04 2013 -0400
Initial import #785312
.gitignore | 1 +
e3-gnu-stack.patch | 38 ++++++++++++++++++++++++
e3.spec | 80 ++++++++++++++++++++++++++++++++++++++++++++++++++++
sources | 1 +
4 files changed, 120 insertions(+), 0 deletions(-)
---
diff --git a/.gitignore b/.gitignore
index e69de29..7b1250c 100644
--- a/.gitignore
+++ b/.gitignore
@@ -0,0 +1 @@
+/e3-2.8.tgz
diff --git a/e3-gnu-stack.patch b/e3-gnu-stack.patch
new file mode 100644
index 0000000..a5840f1
--- /dev/null
+++ b/e3-gnu-stack.patch
@@ -0,0 +1,38 @@
+Common subdirectories: e3-2.8.orig/bin and e3-2.8/bin
+diff -u e3-2.8.orig/e3.asm e3-2.8/e3.asm
+--- e3-2.8.orig/e3.asm 2010-05-09 12:16:47.000000000 -0400
++++ e3-2.8/e3.asm 2013-02-22 14:24:46.884384131 -0500
+@@ -6543,3 +6543,13 @@
+ %ifdef CRIPLED_ELF
+ bsssize equ $-bssstart
+ %endif
++
++%ifidn __OUTPUT_FORMAT__,elf
++section .note.GNU-stack noalloc noexec nowrite progbits
++%endif
++%ifidn __OUTPUT_FORMAT__,elf32
++section .note.GNU-stack noalloc noexec nowrite progbits
++%endif
++%ifidn __OUTPUT_FORMAT__,elf64
++section .note.GNU-stack noalloc noexec nowrite progbits
++%endif
+Only in e3-2.8: e3.asm~
+diff -u e3-2.8.orig/Makefile e3-2.8/Makefile
+--- e3-2.8.orig/Makefile 2010-05-27 14:58:59.000000000 -0400
++++ e3-2.8/Makefile 2013-02-22 15:38:57.729605772 -0500
+@@ -38,15 +38,10 @@
+ #---------------- 32 bit LINUX (and perhaps BSD) --
+
+ 32: $(ASOURCES) Makefile
+-ifeq ($(OS),LINUX)
+- nasm -O2 -f bin -l e3.lst -o e3 e3.asm -DCRIPLED_ELF=1 -D$(OS) -D$(EXMODE)
+- chmod +x e3
+-else
+ echo $(ASVER)
+ nasm -O2 $(AFLAGS) -o e3.o e3.asm -l e3.lst -D$(OS) -D$(EXMODE)
+ ld -s -o e3 e3.o
+ strip --remove-section .comment e3
+-endif
+ ln -sf e3 e3ws
+ ln -sf e3 e3em
+ ln -sf e3 e3pi
diff --git a/e3.spec b/e3.spec
new file mode 100644
index 0000000..3116229
--- /dev/null
+++ b/e3.spec
@@ -0,0 +1,80 @@
+# disable the debug package since it produces nothing useful due to e3
+# being written in assembly
+%global debug_package %{nil}
+
+Name: e3
+Version: 2.8
+Release: 3%{?dist}
+Summary: Text editor with key bindings similar to WordStar, Emacs, pico, nedit, or vi
+
+Group: Applications/Editors
+License: GPLv2
+URL: https://sites.google.com/site/e3editor/
+Source0: https://sites.google.com/site/e3editor/Home/%{name}-%{version}.tgz
+BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
+
+# mark the stack as non-executable and disable tiny/crippled elf on 32
+# bit linux so that stack can be marked as non-executable on it too
+# http://www.gentoo.org/proj/en/hardened/gnu-stack.xml
+Patch0: e3-gnu-stack.patch
+BuildRequires: nasm
+ExclusiveArch: %{ix86} x86_64
+
+%description
+e3 is a full-screen, user-friendly text editor with an key bindings similar to
+that of either WordStar, Emacs, pico, nedit, or vi.
+
+%prep
+%setup -q
+
+# delete the included binaries
+rm -rf bin
+
+%patch0 -p1
+
+%build
+%ifarch x86_64
+make PREFIX=%{_prefix} MANDIR=%{_mandir}/man1 EXMODE=SED 64
+%else
+make PREFIX=%{_prefix} MANDIR=%{_mandir}/man1 EXMODE=SED 32
+%endif
+
+
+%install
+rm -rf %{buildroot}
+# The Makefile does not have the feature to speciy a DESTDIR so we do this by
+# hand
+mkdir -p %{buildroot}%{_bindir}
+install -m 755 e3 %{buildroot}%{_bindir}
+ln -sf %{_bindir}/e3 %{buildroot}%{_bindir}/e3ws
+ln -sf %{_bindir}/e3 %{buildroot}%{_bindir}/e3em
+ln -sf %{_bindir}/e3 %{buildroot}%{_bindir}/e3pi
+ln -sf %{_bindir}/e3 %{buildroot}%{_bindir}/e3vi
+ln -sf %{_bindir}/e3 %{buildroot}%{_bindir}/e3ne
+
+mkdir -p %{buildroot}%{_mandir}/man1/
+install -m 644 e3.man %{buildroot}%{_mandir}/man1/e3.1
+ln -sf %{_mandir}/man1/e3.1 %{buildroot}%{_mandir}/man1/e3ws.1
+ln -sf %{_mandir}/man1/e3.1 %{buildroot}%{_mandir}/man1/e3em.1
+ln -sf %{_mandir}/man1/e3.1 %{buildroot}%{_mandir}/man1/e3pi.1
+ln -sf %{_mandir}/man1/e3.1 %{buildroot}%{_mandir}/man1/e3vi.1
+ln -sf %{_mandir}/man1/e3.1 %{buildroot}%{_mandir}/man1/e3ne.1
+
+%clean
+rm -rf %{buildroot}
+
+%files
+%defattr(-,root,root,-)
+%doc COPYRIGHT COPYING.GPL README README_OLD ChangeLog e3.html
+%{_bindir}/e3*
+%{_mandir}/man1/e3*
+
+%changelog
+* Fri Feb 22 2013 Mark McKinstry <mmckinst at nexcess.net> - 2.8-3
+- patch to mark the stack as non-executable
+
+* Wed Dec 5 2012 Mark McKinstry <mmckinst at nexcess.net> - 2.8-2
+- disable deubg package
+
+* Tue Jan 3 2012 Mark McKinstry <mmckinst at nexcess.net> 2.8-1
+- initial build
diff --git a/sources b/sources
index e69de29..47edc42 100644
--- a/sources
+++ b/sources
@@ -0,0 +1 @@
+0120bb073133ad26a054b35f88333183 e3-2.8.tgz
More information about the scm-commits
mailing list