diff --git a/editors/mp/Makefile b/editors/mp/Makefile index 1c56c10e9313..7e0153cee574 100644 --- a/editors/mp/Makefile +++ b/editors/mp/Makefile @@ -2,9 +2,8 @@ # $FreeBSD$ PORTNAME= mp -PORTVERSION= 5.41 +DISTVERSION= 5.44 CATEGORIES= editors -MASTER_SITES= http://triptico.com/download/mp/ MAINTAINER= jhale@FreeBSD.org COMMENT= Programming text editor @@ -14,6 +13,12 @@ LICENSE_FILE= ${WRKSRC}/LICENSE USES= gmake iconv +USE_GITHUB= yes +GH_ACCOUNT= ttcdt +GH_PROJECT= mp-5.x mpdm:mpdm mpsl:mpsl +GH_TAGNAME= 2.70:mpdm 2.61:mpsl +GH_SUBDIR= mpdm:mpdm mpsl:mpsl + HAS_CONFIGURE= yes CONFIGURE_SCRIPT= config.sh CONFIGURE_ARGS= --prefix=${PREFIX} --docdir=${DOCSDIR} \ @@ -27,15 +32,22 @@ LDFLAGS+= -Wl,--as-needed LLD_UNSAFE= yes MAKE_JOBS_UNSAFE= yes -OPTIONS_DEFINE= DOCS NLS PCRE +OPTIONS_DEFINE= DOCS MANPAGES NLS PCRE OPTIONS_RADIO= GUI OPTIONS_RADIO_GUI= GTK2 GTK3 QT5 CONSOLE_DESC= ${NCURSES_DESC} OPTIONS_SINGLE= CONSOLE OPTIONS_SINGLE_CONSOLE= ANSI NCURSES -OPTIONS_DEFAULT= NCURSES PCRE +OPTIONS_DEFAULT= MANPAGES NCURSES PCRE OPTIONS_SUB= yes +DOCS_BUILD_DEPENDS= p5-Grutatxt>=0:textproc/p5-Grutatxt \ + mp_doccer:textproc/mp_doccer +DOCS_CONFIGURE_WITH= docs + +MANPAGES_BUILD_DEPENDS= p5-Grutatxt>=0:textproc/p5-Grutatxt +MANPAGES_CONFIGURE_WITH=manpages + NLS_USES= gettext NLS_CONFIGURE_WITH= gettext @@ -90,7 +102,6 @@ do-configure: do-install: ${INSTALL_PROGRAM} ${WRKSRC}/mp-5 ${STAGEDIR}${PREFIX}/bin - ${INSTALL_MAN} ${WRKSRC}/mp-5.1 ${STAGEDIR}${MANPREFIX}/man/man1 .if ${PORT_OPTIONS:MGTK*} || ${PORT_OPTIONS:MQT5} ${MKDIR} ${STAGEDIR}${PREFIX}/share/applications ${INSTALL_DATA} ${WRKSRC}/minimum-profit.desktop ${STAGEDIR}${PREFIX}/share/applications @@ -106,8 +117,11 @@ do-install-NLS-on: do-install-DOCS-on: @${MKDIR} ${STAGEDIR}${DOCSDIR} -.for doc in AUTHORS README RELEASE_NOTES mp_templates.sample doc/* mpdm/doc/* mpsl/doc/* +.for doc in README RELEASE_NOTES mp_templates.sample doc/* mpdm/doc/* mpsl/doc/* ${INSTALL_DATA} ${WRKSRC}/${doc} ${STAGEDIR}${DOCSDIR} .endfor +do-install-MANPAGES-on: + ${INSTALL_MAN} ${WRKSRC}/mp-5.1 ${STAGEDIR}${MANPREFIX}/man/man1 + .include diff --git a/editors/mp/distinfo b/editors/mp/distinfo index fa3e13933dca..fcd42cab213e 100644 --- a/editors/mp/distinfo +++ b/editors/mp/distinfo @@ -1,3 +1,7 @@ -TIMESTAMP = 1593452440 -SHA256 (mp-5.41.tar.gz) = 51dc71d414d35fb0437b66d3b86e3a03de3811e5c60d86105d4662e30040513c -SIZE (mp-5.41.tar.gz) = 550542 +TIMESTAMP = 1609456446 +SHA256 (ttcdt-mp-5.x-5.44_GH0.tar.gz) = a799d7b188d221badfdf3e6ddd233d75c38fb82719b700f0e5475f7c61e7c512 +SIZE (ttcdt-mp-5.x-5.44_GH0.tar.gz) = 222903 +SHA256 (ttcdt-mpdm-2.70_GH0.tar.gz) = d3c6269ef2151071d60a736b328ac33040a8afe2a808ccbe56cfa5686198c48a +SIZE (ttcdt-mpdm-2.70_GH0.tar.gz) = 142016 +SHA256 (ttcdt-mpsl-2.61_GH0.tar.gz) = 1d360ca31bdc04dee7338442fc3a0996eab87ceb22d5f76f6843f9469d4be45b +SIZE (ttcdt-mpsl-2.61_GH0.tar.gz) = 70207 diff --git a/editors/mp/files/patch-config.sh b/editors/mp/files/patch-config.sh index 8e28d32b01d7..c0b973f9b083 100644 --- a/editors/mp/files/patch-config.sh +++ b/editors/mp/files/patch-config.sh @@ -1,4 +1,4 @@ ---- config.sh.orig 2020-05-16 07:31:22 UTC +--- config.sh.orig 2020-10-11 16:57:43 UTC +++ config.sh @@ -37,6 +37,7 @@ while [ $# -gt 0 ] ; do case $1 in @@ -8,7 +8,17 @@ --without-win32) WITHOUT_WIN32=1 ;; --with-kde4) WITHOUT_KDE4=0 ;; --without-qt) WITHOUT_QT5=1 && WITHOUT_QT4=1 ;; -@@ -71,6 +72,7 @@ if [ "$CONFIG_HELP" = "1" ] ; then +@@ -46,6 +47,9 @@ while [ $# -gt 0 ] ; do + --without-ansi) WITHOUT_ANSI=1 ;; + --with-external-arch) WITH_EXTERNAL_ARCH=1 ;; + --with-external-tar) WITH_EXTERNAL_ARCH=1 ;; ++ --with-docs) MORE_TARGETS="docs $MORE_TARGETS" ;; ++ --with-gettext) WITHOUT_MSGFMT=0 ;; ++ --with-manpages) MORE_TARGETS="mp-5.1 $MORE_TARGETS" ;; + --without-zip) WITHOUT_ZIP=1 ;; + --help) CONFIG_HELP=1 ;; + +@@ -73,6 +77,7 @@ if [ "$CONFIG_HELP" = "1" ] ; then echo "--prefix=PREFIX Installation prefix ($PREFIX)." echo "--without-curses Disable curses (text) interface detection." echo "--without-gtk Disable GTK interface detection." @@ -16,7 +26,7 @@ echo "--without-win32 Disable win32 interface detection." echo "--with-kde4 Enable KDE4 interface detection." echo "--without-qt Disable Qt interface detection." -@@ -203,9 +205,6 @@ echo +@@ -207,9 +212,6 @@ echo (cd $MPSL && ./config.sh --prefix=$PREFIX --docdir=$PREFIX/share/doc/$APPNAME $CONF_ARGS) echo @@ -26,7 +36,7 @@ cat $MPDM/config.ldflags >> config.ldflags cat $MPSL/config.ldflags >> config.ldflags -@@ -244,11 +243,11 @@ echo -n "Testing for ncursesw... " +@@ -248,11 +250,11 @@ echo -n "Testing for ncursesw... " if [ "$WITHOUT_CURSES" = "1" ] ; then echo "Disabled" else @@ -41,7 +51,7 @@ $CC $CFLAGS $TMP_CFLAGS .tmp.c $TMP_LDFLAGS -o .tmp.o 2>> .config.log if [ $? = 0 ] ; then -@@ -382,14 +381,14 @@ if [ "$WITHOUT_QT5" = "1" ] ; then +@@ -386,14 +388,14 @@ if [ "$WITHOUT_QT5" = "1" ] ; then else if which pkg-config > /dev/null 2>&1 then @@ -60,7 +70,7 @@ if [ $? = 0 ] ; then echo $TMP_CFLAGS >> config.cflags -@@ -475,15 +474,15 @@ else +@@ -479,15 +481,15 @@ else echo "int main(void) { gtk_main(); return 0; } " >> .tmp.c # Try first GTK 3.0 @@ -80,3 +90,12 @@ DRIVERS="gtk $DRIVERS" DRV_OBJS="mpv_gtk.o $DRV_OBJS" CFLAGS="$CFLAGS $TMP_CFLAGS" +@@ -625,7 +627,7 @@ if [ "$WITH_EXTERNAL_ARCH" = "1" ] ; then + echo "#define CONFOPT_EXTERNAL_ARCH 1" >> config.h + echo "#define ARCH_START NULL" >> config.h + echo "#define ARCH_END NULL" >> config.h +- MORE_TARGETS="mp.tar" ++ MORE_TARGETS="mp.tar $MORE_TARGETS" + MORE_INSTALL_TARGETS="install-tar $MORE_INSTALL_TARGETS" + fi + diff --git a/editors/mp/files/patch-makefile.in b/editors/mp/files/patch-makefile.in index e7de233355b4..be2c6b91518e 100644 --- a/editors/mp/files/patch-makefile.in +++ b/editors/mp/files/patch-makefile.in @@ -1,7 +1,7 @@ ---- makefile.in.orig 2018-02-19 12:22:50 UTC +--- makefile.in.orig 2020-10-11 16:57:43 UTC +++ makefile.in -@@ -36,13 +36,13 @@ dep: - gcc -MM *.c `cat config.cflags` > makefile.depend +@@ -52,13 +52,13 @@ mp.zip.o: mp.zip + $(LD) -r -b binary mp.zip -o $@ $(APPNAME): $(OBJS) $(MPDM)/libmpdm.a $(MPSL)/libmpsl.a - $(CCLINK) $(CFLAGS) $(OBJS) `cat config.ldflags` -o $@ diff --git a/editors/mp/files/patch-mpdm_config.sh b/editors/mp/files/patch-mpdm_config.sh index 964c0f504771..595a0941a5e2 100644 --- a/editors/mp/files/patch-mpdm_config.sh +++ b/editors/mp/files/patch-mpdm_config.sh @@ -1,6 +1,6 @@ ---- mpdm/config.sh.orig 2020-05-10 08:05:32 UTC +--- mpdm/config.sh.orig 2020-10-11 16:50:34 UTC +++ mpdm/config.sh -@@ -190,8 +190,8 @@ echo -n "Testing for regular expressions... " +@@ -192,8 +192,8 @@ echo -n "Testing for regular expressions... " if [ "$WITH_PCRE" = 1 ] ; then # try first the pcre library @@ -11,7 +11,7 @@ echo "#include " > .tmp.c echo "int main(void) { regex_t r; regmatch_t m; regcomp(&r,\".*\",REG_EXTENDED|REG_ICASE); return 0; }" >> .tmp.c -@@ -371,13 +371,15 @@ else +@@ -397,13 +397,15 @@ else echo "#define CONFOPT_GETTEXT 1" >> config.h else # try now with -lintl @@ -29,7 +29,7 @@ echo "$TMP_LDFLAGS" >> config.ldflags LDFLAGS="$LDFLAGS $TMP_LDFLAGS" else -@@ -405,13 +407,15 @@ else +@@ -431,13 +433,15 @@ else echo "#define CONFOPT_ICONV 1" >> config.h else # try now with -liconv @@ -47,3 +47,12 @@ echo "$TMP_LDFLAGS" >> config.ldflags LDFLAGS="$LDFLAGS $TMP_LDFLAGS" else +@@ -628,7 +632,7 @@ fi + + # test for mp_doccer + echo -n "Testing if mp_doccer is installed... " +-MP_DOCCER=$(which mp_doccer > /dev/null 2>&1||which mp-doccer > /dev/null 2>&1) ++MP_DOCCER=$(which mp_doccer) + + if [ $? = 0 ] ; then + diff --git a/editors/mp/files/patch-mpdm_mpdm__f.c b/editors/mp/files/patch-mpdm_mpdm__f.c index fca15c7f1e8a..dd8880cb00de 100644 --- a/editors/mp/files/patch-mpdm_mpdm__f.c +++ b/editors/mp/files/patch-mpdm_mpdm__f.c @@ -1,9 +1,18 @@ mpdm_f.c:1947:9: error: use of undeclared identifier 'environ' environ = (char **) calloc(sizeof(char *), mpdm_size(v) + 1); ---- mpdm/mpdm_f.c.orig 2019-11-27 07:37:22 UTC +--- mpdm/mpdm_f.c.orig 2020-11-22 08:58:48 UTC +++ mpdm/mpdm_f.c -@@ -1944,6 +1944,7 @@ static int sysdep_popen(mpdm_t v, char *prg, int rw) +@@ -78,6 +78,8 @@ + #include + #endif + ++#include ++ + #include "mpdm.h" + + #ifdef CONFOPT_ICONV +@@ -1974,6 +1976,7 @@ static int sysdep_popen(mpdm_t v, char *prg, int rw) /* build the environment for the subprocess */ v = mpdm_join(mpdm_get_wcs(mpdm_root(), L"ENV"), MPDM_S(L"=")); diff --git a/editors/mp/files/patch-mpdm_mpdm__s.c b/editors/mp/files/patch-mpdm_mpdm__s.c index cd9d4631c82a..4e32cb813591 100644 --- a/editors/mp/files/patch-mpdm_mpdm__s.c +++ b/editors/mp/files/patch-mpdm_mpdm__s.c @@ -13,9 +13,9 @@ __wcwidth(__ct_rune_t _c) 1 error generated. *** [mpdm_s.o] Error code 1 ---- mpdm/mpdm_s.c.orig 2018-03-04 00:49:18 UTC +--- mpdm/mpdm_s.c.orig 2020-10-11 16:50:34 UTC +++ mpdm/mpdm_s.c -@@ -1067,8 +1067,6 @@ int mpdm_gettext_domain(const mpdm_t dom, const mpdm_t +@@ -758,8 +758,6 @@ int mpdm_gettext_domain(const mpdm_t dom, const mpdm_t #ifdef CONFOPT_WCWIDTH diff --git a/editors/mp/files/patch-mpsl_makefile.in b/editors/mp/files/patch-mpsl_makefile.in new file mode 100644 index 000000000000..6553c2efe276 --- /dev/null +++ b/editors/mp/files/patch-mpsl_makefile.in @@ -0,0 +1,11 @@ +--- mpsl/makefile.in.orig 2020-10-11 16:50:41 UTC ++++ mpsl/makefile.in +@@ -78,7 +78,7 @@ realdistclean: realclean + .txt.html: + grutatxt < $< > $@ + +-doc/mpsl_quickref.ps: doc/mpsl_quickref.txt ++doc/mpsl_quickref.ps: $(TARGET) doc/mpsl_quickref.txt + -./mpsl scripts/mkquickref.mpsl < doc/mpsl_quickref.txt > $@ + + doc/mpsl_api.txt: mpsl_c.c mpsl.y diff --git a/editors/mp/files/patch-mpv__gtk.c b/editors/mp/files/patch-mpv__gtk.c deleted file mode 100644 index 01ba7a67240f..000000000000 --- a/editors/mp/files/patch-mpv__gtk.c +++ /dev/null @@ -1,52 +0,0 @@ -Fix build with GTK 2.x -mpv_gtk.c:2386:5: error: use of undeclared identifier 'GdkMonitor' - GdkMonitor *monitor; - ---- mpv_gtk.c.orig 2019-10-24 17:18:37 UTC -+++ mpv_gtk.c -@@ -2378,13 +2378,14 @@ static mpdm_t gtk_drv_startup(mpdm_t a, mpdm_t ctxt) - #if CONFOPT_GTK == 2 - GdkPixmap *pixmap; - GdkPixmap *mask; -+ GdkScreen *screen; - #endif - #if CONFOPT_GTK == 3 - GdkPixbuf *pixmap; --#endif - GdkDisplay *display; - GdkMonitor *monitor; - GdkRectangle monitor_one_size; -+#endif - mpdm_t v; - int w, h; - GtkTargetEntry targets[] = { -@@ -2399,6 +2400,21 @@ static mpdm_t gtk_drv_startup(mpdm_t a, mpdm_t ctxt) - gtk_window_set_title(GTK_WINDOW(window), "mp " VERSION); - - /* get real screen and pick a usable size for the main area */ -+#if CONFOPT_GTK == 2 -+ screen = gtk_window_get_screen(GTK_WINDOW(window)); -+ if (gdk_screen_get_n_monitors(screen) > 1) { -+ GdkRectangle monitor_one_size; -+ gdk_screen_get_monitor_geometry(screen, 0, &monitor_one_size); -+ -+ w = (monitor_one_size.width * 3) / 4; -+ h = (monitor_one_size.height * 2) / 3; -+ } -+ else { -+ w = (gdk_screen_get_width(screen) * 3) / 4; -+ h = (gdk_screen_get_height(screen) * 2) / 3; -+ } -+#endif -+#if CONFOPT_GTK == 3 - display = gdk_display_get_default(); - - monitor = gdk_display_get_monitor(display, 0); -@@ -2407,6 +2423,7 @@ static mpdm_t gtk_drv_startup(mpdm_t a, mpdm_t ctxt) - - w = (monitor_one_size.width * 3) / 4; - h = (monitor_one_size.height * 2) / 3; -+#endif - - v = mpdm_get_wcs(MP, L"state"); - if ((v = mpdm_get_wcs(v, L"window")) == NULL) { diff --git a/editors/mp/pkg-plist b/editors/mp/pkg-plist index 683851bc9608..13d99d3e4727 100644 --- a/editors/mp/pkg-plist +++ b/editors/mp/pkg-plist @@ -1,11 +1,12 @@ bin/mp-5 -man/man1/mp-5.1.gz +%%MANPAGES%%man/man1/mp-5.1.gz %%GUI%%share/applications/minimum-profit.desktop -%%PORTDOCS%%%%DOCSDIR%%/AUTHORS %%PORTDOCS%%%%DOCSDIR%%/README %%PORTDOCS%%%%DOCSDIR%%/RELEASE_NOTES %%PORTDOCS%%%%DOCSDIR%%/mp_actions.html %%PORTDOCS%%%%DOCSDIR%%/mp_actions.txt +%%PORTDOCS%%%%DOCSDIR%%/mp_api.html +%%PORTDOCS%%%%DOCSDIR%%/mp_api.txt %%PORTDOCS%%%%DOCSDIR%%/mp_configuration.html %%PORTDOCS%%%%DOCSDIR%%/mp_configuration.txt %%PORTDOCS%%%%DOCSDIR%%/mp_cookbook.html @@ -14,7 +15,6 @@ man/man1/mp-5.1.gz %%PORTDOCS%%%%DOCSDIR%%/mp_data_model.txt %%PORTDOCS%%%%DOCSDIR%%/mp_encoding.html %%PORTDOCS%%%%DOCSDIR%%/mp_encoding.txt -%%PORTDOCS%%%%DOCSDIR%%/mp_function_reference.html %%PORTDOCS%%%%DOCSDIR%%/mp_index.html %%PORTDOCS%%%%DOCSDIR%%/mp_index.txt %%PORTDOCS%%%%DOCSDIR%%/mp_interactive_dialog_boxes.html @@ -26,8 +26,12 @@ man/man1/mp-5.1.gz %%PORTDOCS%%%%DOCSDIR%%/mp_man.html %%PORTDOCS%%%%DOCSDIR%%/mp_man.txt %%PORTDOCS%%%%DOCSDIR%%/mp_templates.sample +%%PORTDOCS%%%%DOCSDIR%%/mpdm_api.html +%%PORTDOCS%%%%DOCSDIR%%/mpdm_api.txt %%PORTDOCS%%%%DOCSDIR%%/mpdm_overview.html %%PORTDOCS%%%%DOCSDIR%%/mpdm_overview.txt +%%PORTDOCS%%%%DOCSDIR%%/mpsl_api.html +%%PORTDOCS%%%%DOCSDIR%%/mpsl_api.txt %%PORTDOCS%%%%DOCSDIR%%/mpsl_index.html %%PORTDOCS%%%%DOCSDIR%%/mpsl_index.txt %%PORTDOCS%%%%DOCSDIR%%/mpsl_internals.html @@ -36,6 +40,8 @@ man/man1/mp-5.1.gz %%PORTDOCS%%%%DOCSDIR%%/mpsl_overview.txt %%PORTDOCS%%%%DOCSDIR%%/mpsl_quickref.ps %%PORTDOCS%%%%DOCSDIR%%/mpsl_quickref.txt +%%PORTDOCS%%%%DOCSDIR%%/mpsl_reference.html +%%PORTDOCS%%%%DOCSDIR%%/mpsl_reference.txt %%PORTDOCS%%%%DOCSDIR%%/mptxt_format.txt %%GUI%%share/icons/hicolor/48x48/apps/minimum-profit.png %%NLS%%share/locale/de/LC_MESSAGES/minimum-profit.mo