galeb-mkfiles

Извори пакета за Галеб
Дневник | Датотеке | Референце | ПРОЧИТАЈМЕ | ЛИЦЕНЦА

чување 7bb88f7d53c6644b4553f33d9a528cb8e6c4799c
родитељ 739d25d58691efc7840c8e21ea0a6e660cc402b5
Аутор: Страхиња Радић <contact@strahinja.org>
Датум:   Tue, 30 Aug 2022 20:58:19 +0200

Add netbsd-curses; fix Neomutt segfault

Signed-off-by: Страхиња Радић <contact@strahinja.org>

Diffstat:
MTODO | 30++++++++++++++++++------------
Aneomutt/config.mk | 6++++++
Aneomutt/mkfile | 60++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Aneomutt/pat/dynamic-lib-function-return-pointer-segfault.patch | 11+++++++++++
Anetbsd-curses/config.mk | 5+++++
Anetbsd-curses/mkfile | 34++++++++++++++++++++++++++++++++++
измењених датотека: 6, додавања: 134(+), брисања: 12(-)

diff --git a/TODO b/TODO @@ -1,7 +1,17 @@ TODO ==== -[?] Add neomutt +[ ] Add isync + +[ ] Add msmtp + +[ ] Add X (quite a task!) + + +Done +---- + +[x] Add neomutt [x] Determine minimal set of dependencies to run Luke Smith's mutt-wizard and add those first [x] xapian-core @@ -37,22 +47,18 @@ TODO - Mockup still works, Neomutt doesn't 3. [x] Ask neomutt devs - No answer yet - 4.a. [ ] Introduce ncurses (worst option, avoid if possible) + 4.a. [/] Introduce ncurses (worst option, avoid if possible) - Still contemplating + - Ultimately decided against it, as the solution was + found 4.b. [x] Orthogonal, more in line with basic philosophy: try with S-nail (mailx) for now; all the dependencies above are then not needed - Added; leaving dependencies though - -[ ] Add isync - -[ ] Add msmtp - -[ ] Add X (quite a task!) - - -Done ----- + - **Solved** by adding `#include <term.h>` in gui/mutt_curses.h, which + adds the exact prototype of tigetstr, so the cast by __UNCONST works. + Inspiration from + https://stackoverflow.com/a/8553162/ [x] Add gdb! [x] Add patches diff --git a/neomutt/config.mk b/neomutt/config.mk @@ -0,0 +1,6 @@ +PKGBASE= neomutt +PKGVER= 20220429 +LEGALFILES= LICENSE.md +PREFIX= /sucks +SRCTARBALLS= https://github.com/neomutt/neomutt/archive/refs/tags/$PKGVER.tar.gz +SRCTOTARBALLS= $PKGBASE-$PKGVER.tar.gz diff --git a/neomutt/mkfile b/neomutt/mkfile @@ -0,0 +1,60 @@ +mkpklib=/lib/mkpk +<$mkpklib/defaults.mk +<config.mk +<$mkpklib/derivatives.mk + +PKG= $PKGBASE-$PKGVER +BINDIR= $PREFIX/bin +MANDIR= $PREFIX/share/man +SYSCONFDIR= /etc +LOCALSTATEDIR= /var +MAILPATH= $LOCALSTATEDIR/spool/mail +CFLAGS= -O0 -g -pipe -fPIC -DNCURSES_VERSION='"0.3"' \ + -DNCURSES_VERSION_PATCH='"20220811"' +LDFLAGS= -lterminfo + +$PKGBASE:QV: + for patch in $(find pat -type f | sort); do + if [ -e $patch.applied ]; then + continue + fi + printf " PATCH\t%s\n" "$patch" + patch -Np1 -i $patch || exit 1 + :>$patch.applied + done + printf " CONF\t%s\n" --prefix=$PREFIX + CFLAGS=$CFLAGS LDFLAGS=$LDFLAGS \ + ./configure --prefix=$PREFIX \ + --bindir=$BINDIR \ + --mandir=$MANDIR \ + --gpgme \ + --ssl \ + --notmuch \ + --disable-idn \ + --pcre2 \ + --with-ncurses=/lib \ + --with-mailpath=$MAILPATH + printf " CP\t%s %s\n" Makefile Makefile~ + cp Makefile Makefile~ + printf " SED\t%s\n" Makefile + sed '/^LIBS/s/-lncursesw/-l:libcurses.a -l:libterminfo.a/' Makefile~ > Makefile + printf " MAKE\n" + make LDFLAGS='' + +install:QV: $PKGBASE install-legal + printf " MAKE\t%s\n" "DESTDIR=$(realpath $DESTDIR) install" + make DESTDIR=$(realpath $DESTDIR) install + +install-legal:QV: $PKGBASE + for legalfile in $LEGALFILES; do + printf " INST\t%s\n" "$legalfile" + $INSTALL -Dm0644 "$legalfile" $LEGALDIR/$legalfile + done + +clean:QV: + if [ -e Makefile ]; then + printf " MAKE\tclean\n" + make clean + fi + +<$mkpklib/package.mk diff --git a/neomutt/pat/dynamic-lib-function-return-pointer-segfault.patch b/neomutt/pat/dynamic-lib-function-return-pointer-segfault.patch @@ -0,0 +1,11 @@ +--- a/gui/mutt_curses.h 2022-08-30 20:44:35.726520519 +0200 ++++ b/gui/mutt_curses.h 2022-08-30 20:44:51.543520937 +0200 +@@ -37,6 +37,8 @@ + #include <curses.h> + #endif + ++#include <term.h> ++ + #define ctrl(ch) ((ch) - '@') + + #ifdef KEY_ENTER diff --git a/netbsd-curses/config.mk b/netbsd-curses/config.mk @@ -0,0 +1,5 @@ +PKGBASE= netbsd-curses +PKGVER= 0.3.2 +LEGALFILES= COPYING +PREFIX= / +SRCTARBALLS= https://ftp.barfooze.de/pub/sabotage/tarballs/$PKGBASE-$PKGVER.tar.xz diff --git a/netbsd-curses/mkfile b/netbsd-curses/mkfile @@ -0,0 +1,34 @@ +mkpklib=/lib/mkpk +<$mkpklib/defaults.mk +<config.mk +<$mkpklib/derivatives.mk + +PKG= $PKGBASE-$PKGVER +BINDIR= $PREFIX/bin +DATADIR= $PREFIX/share +LIBDIR= $PREFIX/lib +LOCALEDIR= $DATADIR/locale +MANDIR= $DATADIR/man +CFLAGS= -Os -pipe -fPIC -static --static -fcommon +LDFLAGS= -static --static -fcommon + +$PKGBASE:QV: + printf " MAKE\t%s %s\n" PREFIX=$PREFIX install + make PREFIX=$PREFIX DESTDIR=$DESTDIR CFLAGS="$CFLAGS" \ + LDFLAGS="$LDFLAGS" all install + +install:QV: $PKGBASE install-legal + +install-legal:QV: $PKGBASE + for legalfile in $LEGALFILES; do + printf " INST\t%s\n" "$legalfile" + $INSTALL -Dm0644 "$legalfile" $LEGALDIR/$legalfile + done + +clean:QV: + if [ -e GNUmakefile ]; then + printf " MAKE\tclean\n" + make clean + fi + +<$mkpklib/package.mk