pkgsrc-WIP-changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

luakit-git: update for latest git version



Module Name:	pkgsrc-wip
Committed By:	Yorick Hardy <yorickhardy%gmail.com@localhost>
Pushed By:	yhardy
Date:		Mon Jul 10 09:31:53 2017 +0200
Changeset:	2894532f9a46d8d62a88805106ac2bcda2758142

Modified Files:
	luakit-git/Makefile
	luakit-git/PLIST
	luakit-git/distinfo
Removed Files:
	luakit-git/patches/patch-Makefile
	luakit-git/patches/patch-luakit.c

Log Message:
luakit-git: update for latest git version

There seems to be no  escaping the need for X11 while building
documentation, so ask for Xvfb while building.

Assume that the installed lua configuration scripts will not be
edited: the user can provide  customized configuration in ~/.config/luakit.

To see a diff of this commit:
https://wip.pkgsrc.org/cgi-bin/gitweb.cgi?p=pkgsrc-wip.git;a=commitdiff;h=2894532f9a46d8d62a88805106ac2bcda2758142

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

diffstat:
 luakit-git/Makefile               | 39 +++++++++++++++++++++----------
 luakit-git/PLIST                  | 21 ++++++++++-------
 luakit-git/distinfo               |  2 --
 luakit-git/patches/patch-Makefile | 36 ----------------------------
 luakit-git/patches/patch-luakit.c | 49 ---------------------------------------
 5 files changed, 39 insertions(+), 108 deletions(-)

diffs:
diff --git a/luakit-git/Makefile b/luakit-git/Makefile
index 54ecd75c3f..fa43ae84c1 100644
--- a/luakit-git/Makefile
+++ b/luakit-git/Makefile
@@ -16,21 +16,12 @@ GIT_BRANCH.luakit=	develop
 GIT_REPO.luakit=	git://github.com/aidanholm/luakit
 WRKSRC=			${WRKDIR}/luakit
 
-CONF_FILES+=	${PREFIX}/share/examples/luakit/binds.lua	${PREFIX}/etc/xdg/luakit/binds.lua
-CONF_FILES+=	${PREFIX}/share/examples/luakit/globals.lua	${PREFIX}/etc/xdg/luakit/globals.lua
-CONF_FILES+=	${PREFIX}/share/examples/luakit/modes.lua	${PREFIX}/etc/xdg/luakit/modes.lua
-CONF_FILES+=	${PREFIX}/share/examples/luakit/rc.lua		${PREFIX}/etc/xdg/luakit/rc.lua
-CONF_FILES+=	${PREFIX}/share/examples/luakit/theme.lua	${PREFIX}/etc/xdg/luakit/theme.lua
-CONF_FILES+=	${PREFIX}/share/examples/luakit/webview.lua	${PREFIX}/etc/xdg/luakit/webview.lua
-CONF_FILES+=	${PREFIX}/share/examples/luakit/webview_wm.lua	${PREFIX}/etc/xdg/luakit/webview_wm.lua
-CONF_FILES+=	${PREFIX}/share/examples/luakit/window.lua	${PREFIX}/etc/xdg/luakit/window.lua
-
-# luakit tries to open the X11 display while generating API documentation
-# ... but does not actually use X11 for this step
-MAKE_ENV+=		DISPLAY=
 LUAKIT_MAKE_FLAGS+=	DEVELOPMENT_PATHS=0
+LUAKIT_MAKE_FLAGS+=	APPDIR=${DESTDIR}${PREFIX}/share/applications
 LUAKIT_MAKE_FLAGS+=	DOCDIR=${DESTDIR}${PREFIX}/share/doc/luakit
 LUAKIT_MAKE_FLAGS+=	MANPREFIX=${DESTDIR}${PREFIX}/${PKGMANDIR}
+LUAKIT_MAKE_FLAGS+=	PIXMAPDIR=${DESTDIR}${PREFIX}/share/pixmaps
+LUAKIT_MAKE_FLAGS+=	XDGPREFIX=${DESTDIR}${PREFIX}/etc/xdg
 LUAKIT_MAKE_FLAGS+=	USE_LUAJIT=0
 BUILD_MAKE_FLAGS+=	${LUAKIT_MAKE_FLAGS}
 INSTALL_MAKE_FLAGS+=	${LUAKIT_MAKE_FLAGS}
@@ -41,6 +32,30 @@ LUA_VERSIONS_ACCEPTED=	51
 
 DEPENDS+=	${LUA_PKGPREFIX}-filesystem-[0-9]*:../../devel/lua-filesystem
 
+# Based on lang/swi-prolog-packages:
+setupx:
+.if exists(${X11BASE}/bin/Xvfb)
+	-${X11BASE}/bin/Xvfb :2 & \
+	${ECHO} $$! >${WRKDIR}/.Xvfb.pid
+	${ECHO} checkforx: Xvfb-PID: `${CAT} ${WRKDIR}/.Xvfb.pid`
+	sleep 5
+DISPLAY= :2
+.else
+	@${ECHO} "Error: Please install Xvfb so that the documentation can be built."
+	@${FALSE}
+.endif  #Xvfb
+
+MAKE_ENV+=	DISPLAY=${DISPLAY:Q}
+
+teardownx:
+	${ECHO} teardownx: Xvfb-PID: `${CAT} ${WRKDIR}/.Xvfb.pid`
+	sleep 5
+	-kill `${CAT} ${WRKDIR}/.Xvfb.pid`
+	${RM} -f ${WRKDIR}/.Xvfb.pid
+
+pre-build:	setupx
+post-build:	teardownx
+
 .include "../../databases/sqlite3/buildlink3.mk"
 .include "../../lang/lua/buildlink3.mk"
 .include "../../wip/webkit-gtk/buildlink3.mk"
diff --git a/luakit-git/PLIST b/luakit-git/PLIST
index 36aab81e42..16f042a562 100644
--- a/luakit-git/PLIST
+++ b/luakit-git/PLIST
@@ -1,9 +1,16 @@
 @comment $NetBSD$
 bin/luakit
+etc/xdg/luakit/binds.lua
+etc/xdg/luakit/globals.lua
+etc/xdg/luakit/modes.lua
+etc/xdg/luakit/rc.lua
+etc/xdg/luakit/theme.lua
+etc/xdg/luakit/webview.lua
+etc/xdg/luakit/webview_wm.lua
+etc/xdg/luakit/window.lua
 man/man1/luakit.1
 share/applications/luakit.desktop
 share/doc/luakit/AUTHORS
-share/doc/luakit/COPYING
 share/doc/luakit/COPYING.GPLv3
 share/doc/luakit/README.md
 share/doc/luakit/classes/page.html
@@ -79,19 +86,13 @@ share/doc/luakit/modules/taborder.html
 share/doc/luakit/modules/tests.lib.html
 share/doc/luakit/modules/undoclose.html
 share/doc/luakit/modules/userscripts.html
+share/doc/luakit/modules/vertical_tabs.html
+share/doc/luakit/modules/view_source.html
 share/doc/luakit/modules/viewpdf.html
 share/doc/luakit/modules/webinspector.html
 share/doc/luakit/modules/xdg.html
 share/doc/luakit/pages/Authors.html
 share/doc/luakit/pages/Tests.html
-share/examples/luakit/binds.lua
-share/examples/luakit/globals.lua
-share/examples/luakit/modes.lua
-share/examples/luakit/rc.lua
-share/examples/luakit/theme.lua
-share/examples/luakit/webview.lua
-share/examples/luakit/webview_wm.lua
-share/examples/luakit/window.lua
 share/luakit/lib/adblock.lua
 share/luakit/lib/adblock_chrome.lua
 share/luakit/lib/adblock_wm.lua
@@ -164,6 +165,8 @@ share/luakit/lib/tabhistory.lua
 share/luakit/lib/taborder.lua
 share/luakit/lib/undoclose.lua
 share/luakit/lib/userscripts.lua
+share/luakit/lib/vertical_tabs.lua
+share/luakit/lib/view_source.lua
 share/luakit/lib/viewpdf.lua
 share/luakit/lib/webinspector.lua
 share/luakit/luakit.so
diff --git a/luakit-git/distinfo b/luakit-git/distinfo
index e4bcc4834c..3d8c013af3 100644
--- a/luakit-git/distinfo
+++ b/luakit-git/distinfo
@@ -4,5 +4,3 @@ SHA1 (luakit/2aecefe95c99808121edbf3903c3947779f8c4d4-2aecefe95c99808121edbf3903
 RMD160 (luakit/2aecefe95c99808121edbf3903c3947779f8c4d4-2aecefe95c99808121edbf3903c3947779f8c4d4.zip) = c829f11889a2e50e8a91b5c9553e84c0ded5fdd9
 SHA512 (luakit/2aecefe95c99808121edbf3903c3947779f8c4d4-2aecefe95c99808121edbf3903c3947779f8c4d4.zip) = f493fde91e87b8bd40f3a90b558c4d297ed31bc00e6924660a5c1fa55aa35bfd2eb7c8a6a7ea1d6b9ef7d095d358659d350ca92fbc6f654a9df9a1544ce30fdf
 Size (luakit/2aecefe95c99808121edbf3903c3947779f8c4d4-2aecefe95c99808121edbf3903c3947779f8c4d4.zip) = 518360 bytes
-SHA1 (patch-Makefile) = aff51a8672e75d356435766b4c71314948375b3b
-SHA1 (patch-luakit.c) = 6cf1426a1a6b75ad70dbca82cc2496275d13ca86
diff --git a/luakit-git/patches/patch-Makefile b/luakit-git/patches/patch-Makefile
deleted file mode 100644
index ebf426d837..0000000000
--- a/luakit-git/patches/patch-Makefile
+++ /dev/null
@@ -1,36 +0,0 @@
-$NetBSD$
-
-Install files under PREFIX.
-
---- Makefile.orig	2017-06-05 19:43:00.000000000 +0000
-+++ Makefile
-@@ -97,12 +97,12 @@ install: all
- 	install luakit.so $(INSTALLDIR)/share/luakit/luakit.so
- 	install -d $(INSTALLDIR)/bin
- 	install luakit $(INSTALLDIR)/bin/luakit
--	install -d $(DESTDIR)/etc/xdg/luakit/
--	install -m644 config/*.lua $(DESTDIR)/etc/xdg/luakit/
--	install -d $(DESTDIR)/usr/share/pixmaps
--	install -m644 extras/luakit.png $(DESTDIR)/usr/share/pixmaps/
--	install -d $(DESTDIR)/usr/share/applications
--	install -m644 extras/luakit.desktop $(DESTDIR)/usr/share/applications/
-+	install -d $(INSTALLDIR)/share/examples/luakit
-+	install -m644 config/*.lua $(INSTALLDIR)/share/examples/luakit/
-+	install -d $(INSTALLDIR)/share/pixmaps
-+	install -m644 extras/luakit.png $(INSTALLDIR)/share/pixmaps/
-+	install -d $(INSTALLDIR)/share/applications
-+	install -m644 extras/luakit.desktop $(INSTALLDIR)/share/applications/
- 	install -d $(MANPREFIX)/man1/
- 	install -m644 luakit.1.gz $(MANPREFIX)/man1/
- 	mkdir -p resources
-@@ -111,8 +111,8 @@ install: all
- 
- uninstall:
- 	rm -rf $(INSTALLDIR)/bin/luakit $(INSTALLDIR)/share/luakit
--	rm -rf $(MANPREFIX)/man1/luakit.1.gz $(DESTDIR)/etc/xdg/luakit
--	rm -rf $(DESTDIR)/usr/share/applications/luakit.desktop $(DESTDIR)/usr/share/pixmaps/luakit.png
-+	rm -rf $(MANPREFIX)/man1/luakit.1.gz $(INSTALLDIR)/etc/xdg/luakit
-+	rm -rf $(INSTALLDIR)/usr/share/applications/luakit.desktop $(INSTALLDIR)/usr/share/pixmaps/luakit.png
- 
- tests/util.so: tests/util.c Makefile
- 	$(CC) -fpic $(CFLAGS) $(CPPFLAGS) -shared $(LDFLAGS) $< -o $@
diff --git a/luakit-git/patches/patch-luakit.c b/luakit-git/patches/patch-luakit.c
deleted file mode 100644
index cdbf1ba1da..0000000000
--- a/luakit-git/patches/patch-luakit.c
+++ /dev/null
@@ -1,49 +0,0 @@
-$NetBSD$
-
-luakit is used to generate the API documentation, so allow
-it to run without GTK when DISPLAY is not set.
-
---- luakit.c.orig	2017-06-05 03:20:23.000000000 +0000
-+++ luakit.c
-@@ -171,13 +171,20 @@ glib_log_writer(GLogLevelFlags log_level
- gint
- main(gint argc, gchar *argv[])
- {
-+    char *display = NULL;
-     gboolean *nonblock = NULL;
-+    gboolean havedisplay = TRUE;
- 
-     globalconf.starttime = l_time();
- 
-+    display = getenv("DISPLAY");
-+    if (display == NULL || strcmp(display, "") == 0)
-+        havedisplay = FALSE;
-+
-     /* set numeric locale to C (required for compatibility with
-        LuaJIT and luakit scripts) */
--    gtk_disable_setlocale();
-+    if (havedisplay)
-+        gtk_disable_setlocale();
-     setlocale(LC_ALL, "");
-     setlocale(LC_NUMERIC, "C");
- 
-@@ -205,7 +212,8 @@ main(gint argc, gchar *argv[])
-         }
-     }
- 
--    gtk_init(&argc, &argv);
-+    if (havedisplay)
-+        gtk_init(&argc, &argv);
- 
- #if __GLIBC__ == 2 && __GLIBC_MINOR__ >= 50
-     g_log_set_writer_func(glib_log_writer, NULL, NULL);
-@@ -222,7 +230,8 @@ main(gint argc, gchar *argv[])
-     if (!globalconf.windows->len)
-         fatal("no windows spawned by rc file, exiting");
- 
--    gtk_main();
-+    if (havedisplay)
-+        gtk_main();
-     return EXIT_SUCCESS;
- }
- 


Home | Main Index | Thread Index | Old Index