gplugin/gplugin

05f78ba31dbd
flow: Promoted 'trunk' (0fb63f37f37d) to 'feature/convey'.
--- a/.hgignore Tue Jun 06 21:15:23 2017 -0500
+++ b/.hgignore Sat Jun 10 01:10:08 2017 -0500
@@ -9,6 +9,7 @@
^build.*\/
^packaging\/debian\/tmp\/
^packaging\/debian\/(.+\.)?(substvars|debhelper\.log)$
+^packaging\/debian\/build.*\/
^packaging\/debian\/libgplugin0?(-.+)?\/
^packaging\/debian\/gir1.2-gplugin-0.0\/
^packaging\/debian\/files$
--- a/ChangeLog Tue Jun 06 21:15:23 2017 -0500
+++ b/ChangeLog Sat Jun 10 01:10:08 2017 -0500
@@ -3,6 +3,7 @@
* Added an RPM spec file
* Changed the build system to meson. See INSTALL for instructions.
* Added gplugin_plugin_get_dependent_plugins. (fixes #8)
+ * Remove ability to disable unit testing.
0.27.0: 2016/04/18
* Bumped the glib requirement to 2.34.0
--- a/INSTALL Tue Jun 06 21:15:23 2017 -0500
+++ b/INSTALL Sat Jun 10 01:10:08 2017 -0500
@@ -3,7 +3,7 @@
GPlugin depends on the following at a bare minimum:
glib-2.0 >= 2.34.0
gobject-introspection, libgirepository1.0-dev
- meson >= 0.36.0
+ meson >= 0.37.0
gettext
help2man
a C compiler
--- a/gplugin-gtk/gplugin-gtk-viewer.c Tue Jun 06 21:15:23 2017 -0500
+++ b/gplugin-gtk/gplugin-gtk-viewer.c Sat Jun 10 01:10:08 2017 -0500
@@ -166,10 +166,6 @@
GOptionContext *ctx = NULL;
GtkWidget *window = NULL;
- gtk_init(&argc, &argv);
-
- gplugin_init();
-
ctx = g_option_context_new("");
g_option_context_add_main_entries(ctx, entries, NULL);
g_option_context_add_group(ctx, gtk_get_option_group(TRUE));
@@ -190,6 +186,10 @@
return 0;
}
+ gtk_init(&argc, &argv);
+
+ gplugin_init();
+
if(add_default_paths)
gplugin_manager_add_default_paths();
--- a/gplugin-gtk/meson.build Tue Jun 06 21:15:23 2017 -0500
+++ b/gplugin-gtk/meson.build Sat Jun 10 01:10:08 2017 -0500
@@ -5,13 +5,7 @@
###############################################################################
GTK3 = dependency('gtk+-3.0', version : '>=3.0.0')
-GPLUGIN_GTK_LD_CURRENT = 0
-GPLUGIN_GTK_LD_REVISION = 1
-GPLUGIN_GTK_LD_AGE = 0
-GPLUGIN_GTK_LD_VERSION = '@0@.@1@.@2@'.format(
- GPLUGIN_GTK_LD_CURRENT,
- GPLUGIN_GTK_LD_REVISION,
- GPLUGIN_GTK_LD_AGE)
+GPLUGIN_GTK_LIBRARY_VERSION = '0.1.0'
GPLUGIN_GTK_SOURCES = [
'gplugin-gtk-plugin-info.c',
@@ -70,8 +64,7 @@
c_args : ['-DGPLUGIN_GTK_COMPILATION', '-DG_LOG_DOMAIN="GPluginGtk"'],
include_directories : toplevel_inc,
dependencies : [gplugin_dep, GTK3],
- soversion : GPLUGIN_GTK_LD_CURRENT,
- version : GPLUGIN_GTK_LD_VERSION,
+ version : GPLUGIN_GTK_LIBRARY_VERSION,
install : true
)
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/gplugin.sublime-project Sat Jun 10 01:10:08 2017 -0500
@@ -0,0 +1,8 @@
+{
+ "folders":
+ [
+ {
+ "path": "."
+ }
+ ]
+}
--- a/gplugin/gplugin-manager.c Tue Jun 06 21:15:23 2017 -0500
+++ b/gplugin/gplugin-manager.c Sat Jun 10 01:10:08 2017 -0500
@@ -752,7 +752,7 @@
if(error) {
*error = g_error_new(GPLUGIN_DOMAIN, 0,
_("The loader for %s is not a loader. This "
- "should not happend!"),
+ "should not happened!"),
gplugin_plugin_get_filename(plugin));
}
--- a/gplugin/meson.build Tue Jun 06 21:15:23 2017 -0500
+++ b/gplugin/meson.build Sat Jun 10 01:10:08 2017 -0500
@@ -2,13 +2,7 @@
# Library
###############################################################################
-GPLUGIN_LD_CURRENT = 0
-GPLUGIN_LD_REVISION = 1
-GPLUGIN_LD_AGE = 0
-GPLUGIN_LD_VERSION = '@0@.@1@.@2@'.format(
- GPLUGIN_LD_CURRENT,
- GPLUGIN_LD_REVISION,
- GPLUGIN_LD_AGE)
+GPLUGIN_LIBRARY_VERSION = '0.1.0'
GPLUGIN_HEADERS = [
'gplugin-core.h',
@@ -183,8 +177,7 @@
c_args : ['-DGPLUGIN_COMPILATION', '-DG_LOG_DOMAIN="GPlugin"'],
include_directories : toplevel_inc,
dependencies : [GLIB, GOBJECT, GMODULE],
- soversion : GPLUGIN_LD_CURRENT,
- version : GPLUGIN_LD_VERSION,
+ version : GPLUGIN_LIBRARY_VERSION,
install : true
)
gplugin_dep = declare_dependency(
@@ -276,6 +269,4 @@
###############################################################################
# subdirectories
###############################################################################
-if get_option('testing')
- subdir('tests')
-endif
+subdir('tests')
--- a/gplugin/tests/meson.build Tue Jun 06 21:15:23 2017 -0500
+++ b/gplugin/tests/meson.build Sat Jun 10 01:10:08 2017 -0500
@@ -137,4 +137,4 @@
meson.current_build_dir()),
],
dependencies : [gplugin_dep, GLIB, GOBJECT])
-test('Unresolved Symbol', e)
+# test('Unresolved Symbol', e)
--- a/lua/meson.build Tue Jun 06 21:15:23 2017 -0500
+++ b/lua/meson.build Sat Jun 10 01:10:08 2017 -0500
@@ -49,6 +49,4 @@
)
endif # lua
-if get_option('testing')
- subdir('tests')
-endif
+subdir('tests')
--- a/meson.build Tue Jun 06 21:15:23 2017 -0500
+++ b/meson.build Sat Jun 10 01:10:08 2017 -0500
@@ -2,7 +2,7 @@
# Project Info
###############################################################################
project('gplugin', 'c', version : '0.28.0-dev',
- meson_version : '>0.36.0',
+ meson_version : '>=0.37.0',
default_options : ['c_std=c99'])
parts = meson.project_version().split('-')
@@ -23,7 +23,7 @@
version_conf.set('GPLUGIN_VERSION', meson.project_version())
LOCALE_DIR = join_paths(get_option('prefix'), get_option('localedir'))
-add_global_arguments('-DLOCALEDIR="@0@"'.format(LOCALE_DIR), language : 'c')
+add_project_arguments('-DLOCALEDIR="@0@"'.format(LOCALE_DIR), language : 'c')
###############################################################################
# Dependencies
@@ -41,17 +41,12 @@
# we separate gmodule out so our test aren't linked to it
GMODULE = dependency('gmodule-2.0')
-if get_option('testing')
- GTESTER = find_program('gtester')
- XSLTPROC = find_program('xsltproc')
-endif
-
###############################################################################
# NLS
###############################################################################
GETTEXT_PACKAGE = 'gplugin'
-add_global_arguments('-DGETTEXT_PACKAGE="@0@"'.format(GETTEXT_PACKAGE),
+add_project_arguments('-DGETTEXT_PACKAGE="@0@"'.format(GETTEXT_PACKAGE),
language : 'c')
if get_option('nls')
@@ -63,17 +58,17 @@
###############################################################################
compiler = meson.get_compiler('c')
-add_global_arguments(
+add_project_arguments(
'-DPREFIX="@0@"'.format(get_option('prefix')),
'-DLIBDIR="@0@"'.format(get_option('libdir')),
- '-DGPLUGIN_WEBSITE="http://bitbucket.org/gplugin/main"',
+ '-DGPLUGIN_WEBSITE="https://bitbucket.org/gplugin/main"',
language : 'c'
)
if compiler.has_argument('-Wformat')
- add_global_arguments('-Wformat', language : 'c')
+ add_project_arguments('-Wformat', language : 'c')
if compiler.has_multi_arguments(['-Wformat', '-Werror=format-security'])
- add_global_arguments('-Werror=format-security', language : 'c')
+ add_project_arguments('-Werror=format-security', language : 'c')
endif
endif
@@ -84,13 +79,13 @@
# check if we're using gcc
if compiler.get_id() == 'gcc' or host_machine.platform() == 'darwin'
- add_global_arguments(
+ add_project_arguments(
'-DGPLUGIN_UNUSED=__attribute__((unused))',
'-ggdb',
language : 'c'
)
else
- add_global_arguments(
+ add_project_arguments(
'-DGPLUGIN_UNUSED=',
language : 'c'
)
--- a/meson_options.txt Tue Jun 06 21:15:23 2017 -0500
+++ b/meson_options.txt Sat Jun 10 01:10:08 2017 -0500
@@ -14,12 +14,6 @@
)
option(
- 'testing',
- type : 'boolean', value : true,
- description : 'Whether or not to run unit tests while compiling'
-)
-
-option(
'help2man',
type : 'boolean', value : true,
description : 'Whether or not to build man pages from --help output'
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/packaging/debian/clean Sat Jun 10 01:10:08 2017 -0500
@@ -0,0 +1,1 @@
+build
--- a/packaging/debian/control Tue Jun 06 21:15:23 2017 -0500
+++ b/packaging/debian/control Sat Jun 10 01:10:08 2017 -0500
@@ -2,8 +2,8 @@
Section: libs
Priority: optional
Maintainer: Gary Kramlich <grim@reaperworld.com>
-Build-Depends: debhelper (>=9), dh-exec,
- cmake, libglib2.0-dev, libgtk-3-dev,
+Build-Depends: debhelper (>=9),
+ meson, libglib2.0-dev, libgtk-3-dev,
xsltproc, gettext, help2man,
gobject-introspection, libgirepository1.0-dev,
liblua5.1-0-dev, lua-lgi,
@@ -11,7 +11,7 @@
Homepage: https://bitbucket.org/gplugin/main
Vcs-Browser: https://bitbucket.org/gplugin/main/src
Vcs-Hg: https://bitbucket.org/gplugin/main
-Standards-Version: 3.9.6
+Standards-Version: 3.9.8
Package: libgplugin0
Architecture: any
@@ -24,6 +24,17 @@
.
This package contains the main library.
+Package: libgplugin0-bin
+Architecture: any
+Section: utils
+Depends: ${misc:Depends}, ${shlibs:Depends}, libgplugin0 (= ${binary:Version}), libglib2.0-0 (>=2.20.0)
+Description: GObject based plugin library utilities
+ GPlugin is a GObject based library that implements a reusable plugin system
+ which supports loading plugins in other languages via loaders. It relies
+ heavily on GObjectIntrospection to expose its API to the other languages.
+ .
+ This package contains utilities for the library.
+
Package: libgplugin-dev
Architecture: any
Section: libdevel
@@ -81,7 +92,7 @@
Package: gir1.2-gplugin-0.0
Architecture: any
-Depends: ${misc:Depends}, libgplugin0
+Depends: ${gir:Depends}, ${misc:Depends}, libgplugin0
Section: introspection
Description: typelibe for libgplugin
GPlugin is a GObject based library that implements a reusable plugin system
--- a/packaging/debian/copyright Tue Jun 06 21:15:23 2017 -0500
+++ b/packaging/debian/copyright Sat Jun 10 01:10:08 2017 -0500
@@ -1,4 +1,4 @@
-Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/
+Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/
Upstream-Name: gplugin
Upstream-Contact: grim@reaperworld.com
Source: https://bitbucket.org/gplugin/main
--- a/packaging/debian/gir1.2-gplugin-0.0.install Tue Jun 06 21:15:23 2017 -0500
+++ b/packaging/debian/gir1.2-gplugin-0.0.install Sat Jun 10 01:10:08 2017 -0500
@@ -1,3 +1,2 @@
-#!/usr/bin/dh-exec
-usr/lib/${DEB_HOST_MULTIARCH}/girepository-1.0/
-usr/share/gir-1.0/
+debian/tmp/usr/lib/*/girepository-1.0/
+debian/tmp/usr/share/gir-1.0/
--- a/packaging/debian/libgplugin-dev.install Tue Jun 06 21:15:23 2017 -0500
+++ b/packaging/debian/libgplugin-dev.install Sat Jun 10 01:10:08 2017 -0500
@@ -1,6 +1,5 @@
-#!/usr/bin/dh-exec
-usr/include/gplugin-1.0/gplugin
-usr/include/gplugin-1.0/gplugin.h
-usr/include/gplugin-1.0/gplugin-native.h
-usr/lib/${DEB_HOST_MULTIARCH}/libgplugin.so
-usr/lib/${DEB_HOST_MULTIARCH}/pkgconfig/gplugin.pc
+debian/tmp/usr/include/gplugin-1.0/gplugin
+debian/tmp/usr/include/gplugin-1.0/gplugin.h
+debian/tmp/usr/include/gplugin-1.0/gplugin-native.h
+debian/tmp/usr/lib/*/libgplugin.so
+debian/tmp/usr/lib/*/pkgconfig/gplugin.pc
--- a/packaging/debian/libgplugin-gtk-bin.install Tue Jun 06 21:15:23 2017 -0500
+++ b/packaging/debian/libgplugin-gtk-bin.install Sat Jun 10 01:10:08 2017 -0500
@@ -1,2 +1,2 @@
-usr/bin/gplugin-gtk-viewer
-usr/share/man/man1/gplugin-gtk-viewer.1
+debian/tmp/usr/bin/gplugin-gtk-viewer
+debian/tmp/usr/share/man/man1/gplugin-gtk-viewer.1
--- a/packaging/debian/libgplugin-gtk-dev.install Tue Jun 06 21:15:23 2017 -0500
+++ b/packaging/debian/libgplugin-gtk-dev.install Sat Jun 10 01:10:08 2017 -0500
@@ -1,5 +1,4 @@
-#!/usr/bin/dh-exec
usr/include/gplugin-1.0/gplugin-gtk
usr/include/gplugin-1.0/gplugin-gtk.h
-usr/lib/${DEB_HOST_MULTIARCH}/libgplugin-gtk.so
-usr/lib/${DEB_HOST_MULTIARCH}/pkgconfig/gplugin-gtk.pc
+debian/tmp/usr/lib/*/libgplugin-gtk.so
+debian/tmp/usr/lib/*/pkgconfig/gplugin-gtk.pc
--- a/packaging/debian/libgplugin-gtk0.install Tue Jun 06 21:15:23 2017 -0500
+++ b/packaging/debian/libgplugin-gtk0.install Sat Jun 10 01:10:08 2017 -0500
@@ -1,2 +1,1 @@
-#!/usr/bin/dh-exec
-usr/lib/${DEB_HOST_MULTIARCH}/libgplugin-gtk.so.*
+debian/tmp/usr/lib/*/libgplugin-gtk.so.*
--- a/packaging/debian/libgplugin-gtk0.postinst Tue Jun 06 21:15:23 2017 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,11 +0,0 @@
-#!/bin/sh
-
-set -e
-
-if [ "$1" = "configure" ]; then
- ldconfig
-fi
-
-#DEBHELPER#
-
-exit 0
--- a/packaging/debian/libgplugin-gtk0.postrm Tue Jun 06 21:15:23 2017 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,11 +0,0 @@
-#!/bin/sh
-
-set -e
-
-if [ "$1" = "remove" ] ; then
- ldconfig
-fi
-
-#DEBHELPER#
-
-exit 0
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/packaging/debian/libgplugin-gtk0.triggers Sat Jun 10 01:10:08 2017 -0500
@@ -0,0 +1,1 @@
+activate-noawait ldconfig
--- a/packaging/debian/libgplugin-lua.install Tue Jun 06 21:15:23 2017 -0500
+++ b/packaging/debian/libgplugin-lua.install Sat Jun 10 01:10:08 2017 -0500
@@ -1,2 +1,1 @@
-#!/usr/bin/dh-exec
-usr/lib/${DEB_HOST_MULTIARCH}/gplugin/gplugin-lua.so
+debian/tmp/usr/lib/*/gplugin/gplugin-lua.so
--- a/packaging/debian/libgplugin-python.install Tue Jun 06 21:15:23 2017 -0500
+++ b/packaging/debian/libgplugin-python.install Sat Jun 10 01:10:08 2017 -0500
@@ -1,2 +1,1 @@
-#!/usr/bin/dh-exec
-usr/lib/${DEB_HOST_MULTIARCH}/gplugin/gplugin-python.so
+debian/tmp/usr/lib/*/gplugin/gplugin-python.so
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/packaging/debian/libgplugin0-bin.install Sat Jun 10 01:10:08 2017 -0500
@@ -0,0 +1,2 @@
+debian/tmp/usr/bin/gplugin-query
+debian/tmp/usr/share/man/man1/gplugin-query.1
--- a/packaging/debian/libgplugin0.install Tue Jun 06 21:15:23 2017 -0500
+++ b/packaging/debian/libgplugin0.install Sat Jun 10 01:10:08 2017 -0500
@@ -1,4 +1,1 @@
-#!/usr/bin/dh-exec
-usr/lib/${DEB_HOST_MULTIARCH}/libgplugin.so.*
-usr/bin/gplugin-query
-usr/share/man/man1/gplugin-query.1
+debian/tmp/usr/lib/*/libgplugin.so.*
--- a/packaging/debian/libgplugin0.postinst Tue Jun 06 21:15:23 2017 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,7 +0,0 @@
-#/bin/sh
-
-set -e
-
-#DEBHELPER#
-
-exit 0
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/packaging/debian/libgplugin0.triggers Sat Jun 10 01:10:08 2017 -0500
@@ -0,0 +1,1 @@
+activate-noawait ldconfig
--- a/packaging/debian/rules Tue Jun 06 21:15:23 2017 -0500
+++ b/packaging/debian/rules Sat Jun 10 01:10:08 2017 -0500
@@ -1,5 +1,24 @@
#!/usr/bin/make -f
+export DH_VERBOSE = 1
+export DEB_BUILD_MAINT_OPTIONS = hardening=+all
+
+BUILD_DIR := debian/build
+
%:
- dh $@
+ dh $@ --with gir
+
+override_dh_auto_clean:
+ rm -rf $(BUILD_DIR)
+
+override_dh_auto_configure:
+ meson --prefix /usr --warnlevel 3 $(BUILD_DIR)
+override_dh_auto_build:
+ ninja -v -C $(BUILD_DIR)
+
+override_dh_auto_test:
+ ninja -v -C $(BUILD_DIR) test
+
+override_dh_auto_install:
+ DESTDIR=$(CURDIR)/debian/tmp ninja -v -C $(BUILD_DIR) install
--- a/python/gplugin-python-loader.c Tue Jun 06 21:15:23 2017 -0500
+++ b/python/gplugin-python-loader.c Sat Jun 10 01:10:08 2017 -0500
@@ -329,7 +329,7 @@
}
/* setup sys.path according to
- * http://docs.python.org/3/c-api/init.html#PySys_SetArgvEx
+ * https://docs.python.org/3/c-api/init.html#PySys_SetArgvEx
*/
#if PY_VERSION_HEX < 0x03010300
PySys_SetArgv(1, argv);
--- a/python/meson.build Tue Jun 06 21:15:23 2017 -0500
+++ b/python/meson.build Sat Jun 10 01:10:08 2017 -0500
@@ -54,6 +54,4 @@
)
endif # python
-if get_option('testing')
- subdir('tests')
-endif
+subdir('tests')
--- a/tcc/meson.build Tue Jun 06 21:15:23 2017 -0500
+++ b/tcc/meson.build Sat Jun 10 01:10:08 2017 -0500
@@ -25,6 +25,4 @@
)
endif # tcc
-if get_option('testing')
- subdir('tests')
-endif
+subdir('tests')