Browse Source

ne: Update from 3.0.1 to 3.1.0

android-5
Fredrik Fornwall 8 years ago
parent
commit
35b4ba65bf
  1. 5
      packages/ne/build.sh
  2. 48
      packages/ne/makefile.patch
  3. 37
      packages/ne/src-makefile.patch

5
packages/ne/build.sh

@ -1,14 +1,15 @@
TERMUX_PKG_HOMEPAGE=http://ne.di.unimi.it/ TERMUX_PKG_HOMEPAGE=http://ne.di.unimi.it/
TERMUX_PKG_DESCRIPTION="Easy-to-use and powerful text editor" TERMUX_PKG_DESCRIPTION="Easy-to-use and powerful text editor"
TERMUX_PKG_MAINTAINER="David Martínez @vaites" TERMUX_PKG_MAINTAINER="David Martínez @vaites"
TERMUX_PKG_VERSION=3.0.1 TERMUX_PKG_VERSION=3.1.0
TERMUX_PKG_SRCURL=https://fossies.org/linux/misc/ne-${TERMUX_PKG_VERSION}.tar.xz TERMUX_PKG_SRCURL=https://fossies.org/linux/misc/ne-${TERMUX_PKG_VERSION}.tar.xz
TERMUX_PKG_SHA256=1fa3ede11964e314db783c0e240a3826cbec2d02e5bcd700aa7e41a0c6f02fd9 TERMUX_PKG_SHA256=1b7e63b6f6db1671e19af05fb4230b86b4d0c25679e240d52a5c094a191dd683
TERMUX_PKG_DEPENDS="libandroid-support, ncurses" TERMUX_PKG_DEPENDS="libandroid-support, ncurses"
TERMUX_PKG_RM_AFTER_INSTALL="info/" TERMUX_PKG_RM_AFTER_INSTALL="info/"
TERMUX_PKG_BUILD_IN_SRC=yes TERMUX_PKG_BUILD_IN_SRC=yes
termux_step_make() { termux_step_make() {
CPPFLAGS+=" -Dindex=strchr"
CFLAGS+=" -I${TERMUX_PREFIX}" CFLAGS+=" -I${TERMUX_PREFIX}"
sed -i -e "s%usr/local%$TERMUX_PREFIX%" makefile sed -i -e "s%usr/local%$TERMUX_PREFIX%" makefile

48
packages/ne/makefile.patch

@ -1,26 +1,30 @@
--- ../../build/ne/cache/ne-3.0.1/src/makefile 2015-06-21 22:02:45.000000000 +0200 diff -u -r ../ne-3.1.0/makefile ./makefile
+++ ./src/makefile 2016-10-27 16:56:23.602142314 +0200 --- ../ne-3.1.0/makefile 2017-04-29 12:22:39.000000000 +0200
@@ -81,13 +81,7 @@ +++ ./makefile 2017-05-04 23:14:54.916199058 +0200
NE_DEBUG= @@ -8,7 +8,7 @@
NE_TEST= # and installed under the $(PREFIX) hierarchy. You can even use "make install PREFIX=$HOME/<dir>"
# to install ne locally into the directory <dir>.
-CC=c99 -PREFIX=/usr/local
- +PREFIX?=/usr/local
-ifeq ($(CC),gcc)
-GCCFLAGS=-std=c99 -Wall -Wno-parentheses
-endif
-
-CFLAGS=$(OPTS) $(GCCFLAGS) \
+CFLAGS=$(OPTS) $(CPPFLAGS) -std=c99 -Wall -Wno-parentheses \
-D_REGEX_LARGE_OFFSETS -D_GNU_SOURCE -DSTDC_HEADERS -Dinline=__inline__ \
$(if $(NE_NOWCHAR), -DNOWCHAR,) \
$(if $(NE_TEST), -DNE_TEST -coverage,) \
@@ -96,7 +90,7 @@
$(if $(NE_ANSI), -DTERMCAP -DANSI,)
PROGRAM = ne
-LIBS=$(if $(NE_TERMCAP)$(NE_ANSI),,-lcurses) @@ -20,7 +20,7 @@
+LIBS=$(if $(NE_TERMCAP)$(NE_ANSI),,-lncurses)
ne: $(OBJS) $(if $(NE_TERMCAP)$(NE_ANSI),$(TERMCAPOBJS),)
$(CC) $(OPTS) $(LDFLAGS) $(if $(NE_TEST), -coverage -lefence,) $^ -lm $(LIBS) -o $(PROGRAM) build: docs
- ( cd src; make clean; make NE_GLOBAL_DIR=$(PREFIX)/share/ne; strip ne )
+ ( cd src; make clean; make NE_GLOBAL_DIR=$(PREFIX)/share/ne; $(STRIP) ne )
docs:
( cd doc; make )
@@ -82,7 +82,7 @@
ifneq ($(OS), Darwin)
$(error This target can only be run under Mac OS X)
endif
- ( cd src; make clean; make NE_GLOBAL_DIR=/usr/share/ne; strip ne )
+ ( cd src; make clean; make NE_GLOBAL_DIR=/usr/share/ne; $(STRIP) ne )
-rm -fr /tmp/package-ne-$(VERSION)
make install DESTDIR=/tmp/package-ne-$(VERSION)
pkgbuild --root /tmp/package-ne-$(VERSION) --install-location "/" --version $(VERSION) --identifier ne-$(VERSION) ne-$(VERSION).pkg

37
packages/ne/src-makefile.patch

@ -0,0 +1,37 @@
diff -u -r ../ne-3.1.0/src/makefile ./src/makefile
--- ../ne-3.1.0/src/makefile 2017-04-04 12:35:59.000000000 +0200
+++ ./src/makefile 2017-05-04 23:26:27.136260906 +0200
@@ -28,7 +28,7 @@
# where ne tries to read system-wide information (configuration
# files, etc.).
-NE_GLOBAL_DIR = /usr/local/share/ne
+NE_GLOBAL_DIR = $(PREFIX)/share/ne
PROGRAM = ne
@@ -81,13 +81,14 @@
NE_DEBUG=
NE_TEST=
-CC=c99
+CC?=c99
ifeq ($(CC),gcc)
GCCFLAGS=-std=c99 -Wall -Wno-parentheses
endif
CFLAGS=$(OPTS) $(GCCFLAGS) \
+ $(CPPFLAGS) \
-D_REGEX_LARGE_OFFSETS -D_GNU_SOURCE -DSTDC_HEADERS -Dinline=__inline__ \
$(if $(NE_NOWCHAR), -DNOWCHAR,) \
$(if $(NE_TEST), -DNE_TEST -coverage,) \
@@ -96,7 +97,7 @@
$(if $(NE_ANSI), -DTERMCAP -DANSI,)
-LIBS=$(if $(NE_TERMCAP)$(NE_ANSI),,-lcurses)
+LIBS=$(if $(NE_TERMCAP)$(NE_ANSI),,-lncurses)
ne: $(OBJS) $(if $(NE_TERMCAP)$(NE_ANSI),$(TERMCAPOBJS),)
$(CC) $(OPTS) $(LDFLAGS) $(if $(NE_TEST), -coverage -lefence,) $^ -lm $(LIBS) -o $(PROGRAM)
Loading…
Cancel
Save