Port to meson (#258)

* Port to meson

* plugin generation script: swtich to meson, update to python3, switch to libpeas, add some extra options, and cleanup

* clean up some build warnings

* kill xed-bugreport.sh with fire: it isn't used anymore, and probably doesn't even work

* update gzip command to avoid warnings on some systems and move appdata.xml to /usr/share/metainfo/ as that's where it's supposed to go now

* POTFILES.in: fix path that changed in the meson port, which was causing makepot to fail
This commit is contained in:
Stephen Collins
2018-11-19 04:09:52 -07:00
committed by Clement Lefebvre
parent 39cadaa36e
commit 6e36dc4a5f
117 changed files with 1284 additions and 1910 deletions

View File

@@ -1,28 +0,0 @@
DIST_SUBDIRS = \
docinfo \
filebrowser \
modelines \
sort \
spell \
taglist \
textsize \
time \
trailsave \
wordcompletion
SUBDIRS = \
docinfo \
filebrowser \
modelines \
sort \
taglist \
textsize \
time \
trailsave \
wordcompletion
if ENABLE_SPELL
SUBDIRS += spell
endif
-include $(top_srcdir)/git.mk

View File

@@ -1,34 +0,0 @@
# docinfo plugin
plugindir = $(XED_PLUGINS_LIBS_DIR)
AM_CPPFLAGS = \
-I$(top_srcdir) \
$(XED_CFLAGS) \
$(WARN_CFLAGS) \
$(DISABLE_DEPRECATED_CFLAGS)
plugin_LTLIBRARIES = libdocinfo.la
libdocinfo_la_SOURCES = \
xed-docinfo-plugin.h \
xed-docinfo-plugin.c
libdocinfo_la_LDFLAGS = $(PLUGIN_LIBTOOL_FLAGS)
libdocinfo_la_LIBADD = $(XED_LIBS)
uidir = $(XED_PLUGINS_DATA_DIR)/docinfo
ui_DATA = docinfo.ui
plugin_in_files = docinfo.plugin.desktop.in
%.plugin: %.plugin.desktop.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*po) ; $(INTLTOOL_MERGE) $(top_srcdir)/po $< $@ -d -u -c $(top_builddir)/po/.intltool-merge-cache
plugin_DATA = $(plugin_in_files:.plugin.desktop.in=.plugin)
EXTRA_DIST = $(ui_DATA) $(plugin_in_files)
CLEANFILES = $(plugin_DATA)
DISTCLEANFILES = $(plugin_DATA)
-include $(top_srcdir)/git.mk

View File

@@ -0,0 +1,37 @@
docinfo_sources = [
'xed-docinfo-plugin.h',
'xed-docinfo-plugin.c'
]
docinfo_deps = [
config_h,
glib,
gmodule,
gtksourceview,
libpeas,
pango
]
library('docinfo',
docinfo_sources,
dependencies: docinfo_deps,
include_directories: include_dirs,
link_with: libxed,
install_rpath: join_paths(prefix, libdir, 'xed'),
install: true,
install_dir: join_paths(libdir, 'xed', 'plugins')
)
install_data(
'docinfo.ui',
install_dir: join_paths(pluginsdatadir, 'docinfo')
)
docinfo_desktop = custom_target(
'docinfo_desktop',
input: 'docinfo.plugin.desktop.in',
output: 'docinfo.plugin',
command: [intltool_merge, '-d', '-u', po_dir, '@INPUT@', '@OUTPUT@'],
install: true,
install_dir: pluginslibdir,
)

View File

@@ -19,14 +19,8 @@
*
*/
#ifdef HAVE_CONFIG_H
#include <config.h>
#endif
#include "xed-docinfo-plugin.h"
#include <string.h> /* For strlen (...) */
#include <glib/gi18n.h>
#include <pango/pango-break.h>
#include <gmodule.h>
@@ -36,6 +30,8 @@
#include <xed/xed-debug.h>
#include <xed/xed-utils.h>
#include "xed-docinfo-plugin.h"
#define MENU_PATH "/MenuBar/ToolsMenu/ToolsOps_2"
struct _XedDocInfoPluginPrivate

View File

@@ -1,94 +0,0 @@
# filebrowser
plugindir = $(XED_PLUGINS_LIBS_DIR)
AM_CPPFLAGS = \
-I$(top_srcdir) \
$(XED_CFLAGS) \
$(WARN_CFLAGS) \
$(DISABLE_DEPRECATED_CFLAGS)
BUILT_SOURCES = \
xed-file-browser-enum-types.h \
xed-file-browser-enum-types.c \
xed-file-browser-marshal.h \
xed-file-browser-marshal.c
plugin_LTLIBRARIES = libfilebrowser.la
NOINST_H_FILES = \
xed-file-bookmarks-store.h \
xed-file-browser-store.h \
xed-file-browser-view.h \
xed-file-browser-widget.h \
xed-file-browser-error.h \
xed-file-browser-utils.h \
xed-file-browser-plugin.h \
xed-file-browser-messages.h
libfilebrowser_la_SOURCES = \
$(BUILT_SOURCES) \
xed-file-bookmarks-store.c \
xed-file-browser-store.c \
xed-file-browser-view.c \
xed-file-browser-widget.c \
xed-file-browser-utils.c \
xed-file-browser-plugin.c \
xed-file-browser-messages.c \
$(NOINST_H_FILES)
libfilebrowser_la_LDFLAGS = $(PLUGIN_LIBTOOL_FLAGS)
libfilebrowser_la_LIBADD = $(XED_LIBS)
# UI files (if you use ui for your plugin, list those files here)
uidir = $(XED_PLUGINS_DATA_DIR)/filebrowser
ui_DATA = xed-file-browser-widget-ui.xml
plugin_in_files = filebrowser.plugin.desktop.in
%.plugin: %.plugin.desktop.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*po) ; $(INTLTOOL_MERGE) $(top_srcdir)/po $< $@ -d -u -c $(top_builddir)/po/.intltool-merge-cache
xed-file-browser-enum-types.h: xed-file-browser-enum-types.h.template $(NOINST_H_FILES) $(GLIB_MKENUMS)
(cd $(srcdir) && $(GLIB_MKENUMS) --template xed-file-browser-enum-types.h.template $(NOINST_H_FILES)) > $@
xed-file-browser-enum-types.c: xed-file-browser-enum-types.c.template xed-file-browser-enum-register.c.template $(NOINST_H_FILES) $(GLIB_MKENUMS)
$(AM_V_GEN) (cd $(srcdir) && \
$(GLIB_MKENUMS) --template xed-file-browser-enum-types.c.template $(NOINST_H_FILES) && \
$(GLIB_MKENUMS) --template xed-file-browser-enum-register.c.template $(NOINST_H_FILES)) > $@
xed-file-browser-marshal.h: xed-file-browser-marshal.list $(GLIB_GENMARSHAL)
$(AM_V_GEN) $(GLIB_GENMARSHAL) $< --header --prefix=xed_file_browser_marshal > $@
xed-file-browser-marshal.c: xed-file-browser-marshal.list $(GLIB_GENMARSHAL)
$(AM_V_GEN) echo "#include \"xed-file-browser-marshal.h\"" > $@ && \
$(GLIB_GENMARSHAL) $< --body --prefix=xed_file_browser_marshal >> $@
plugin_DATA = $(plugin_in_files:.plugin.desktop.in=.plugin)
@INTLTOOL_XML_NOMERGE_RULE@
filebrowser_gschema_in = org.x.editor.plugins.filebrowser.gschema.xml.in
gsettings_SCHEMAS = $(filebrowser_gschema_in:.xml.in=.xml)
@GSETTINGS_RULES@
EXTRA_DIST = \
$(ui_DATA) \
$(plugin_in_files) \
$(filebrowser_gschema_in) \
xed-file-browser-enum-types.h.template \
xed-file-browser-enum-types.c.template \
xed-file-browser-enum-register.c.template \
xed-file-browser-marshal.list
CLEANFILES = \
$(plugin_DATA) \
$(gsettings_SCHEMAS_in) \
$(gsettings_SCHEMAS) \
$(BUILT_SOURCES)
DISTCLEANFILES = \
$(plugin_DATA) \
$(gsettings_SCHEMAS_in) \
$(gsettings_SCHEMAS) \
$(BUILT_SOURCES)
-include $(top_srcdir)/git.mk

View File

@@ -0,0 +1,73 @@
filebrowser_headers = [
'xed-file-bookmarks-store.h',
'xed-file-browser-store.h',
'xed-file-browser-view.h',
'xed-file-browser-widget.h',
'xed-file-browser-error.h',
'xed-file-browser-utils.h',
'xed-file-browser-plugin.h',
'xed-file-browser-messages.h'
]
filebrowser_lib_sources = [
'xed-file-bookmarks-store.c',
'xed-file-browser-store.c',
'xed-file-browser-view.c',
'xed-file-browser-widget.c',
'xed-file-browser-utils.c',
'xed-file-browser-plugin.c',
'xed-file-browser-messages.c'
]
filebrowser_enums = gnome.mkenums_simple(
'xed-file-browser-enum-types',
sources : filebrowser_headers,
identifier_prefix : 'XedFileBrowser',
symbol_prefix : 'xed_file_browser'
)
filebrowser_marshal = gnome.genmarshal(
'xed-file-browser-marshal',
sources: 'xed-file-browser-marshal.list',
prefix: 'xed_file_browser_marshal'
)
filebrowser_deps = [
config_h,
gio,
glib,
gmodule,
gtk,
gtksourceview,
libpeas
]
library(
'filebrowser',
filebrowser_headers + filebrowser_lib_sources + filebrowser_enums + filebrowser_marshal,
link_with: libxed,
dependencies: filebrowser_deps,
include_directories: include_dirs,
install_rpath: join_paths(prefix, libdir, 'xed'),
install: true,
install_dir: join_paths(libdir, 'xed', 'plugins')
)
install_data(
'xed-file-browser-widget-ui.xml',
install_dir: join_paths(pluginsdatadir, 'filebrowser')
)
filebrowser_desktop = custom_target(
'filebrowser_desktop',
input: 'filebrowser.plugin.desktop.in',
output: 'filebrowser.plugin',
command: [intltool_merge, '-d', '-u', po_dir, '@INPUT@', '@OUTPUT@'],
install: true,
install_dir: pluginslibdir,
)
install_data(
'org.x.editor.plugins.filebrowser.gschema.xml',
install_dir: schema_dir
)

View File

@@ -911,7 +911,7 @@ xed_file_bookmarks_store_get_location (XedFileBookmarksStore *model,
}
else if (!isfs)
{
file = g_object_ref (obj);
file = G_FILE (g_object_ref (obj));
}
g_object_unref (obj);

View File

@@ -1,20 +0,0 @@
/*** BEGIN file-header ***/
void
xed_file_browser_enum_and_flag_register_type (GTypeModule * module)
{
/*** END file-header ***/
/*** BEGIN file-production ***/
/* Enumerations from "@filename@" */
/*** END file-production ***/
/*** BEGIN enumeration-production ***/
register_@enum_name@ (module);
/*** END enumeration-production ***/
/*** BEGIN file-tail ***/
}
/*** END file-tail ***/

View File

@@ -1,45 +0,0 @@
/*** BEGIN file-header ***/
#include "xed-file-browser-enum-types.h"
/*** END file-header ***/
/*** BEGIN file-production ***/
/* enumerations from "@filename@" */
#include "@filename@"
/*** END file-production ***/
/*** BEGIN value-header ***/
static GType @enum_name@_type = 0;
static GType
register_@enum_name@ (GTypeModule *module)
{
static const G@Type@Value values[] = {
/*** END value-header ***/
/*** BEGIN value-production ***/
{ @VALUENAME@,
"@VALUENAME@",
"@valuenick@" },
/*** END value-production ***/
/*** BEGIN value-tail ***/
{ 0, NULL, NULL }
};
@enum_name@_type =
g_type_module_register_@type@ (module,
"@EnumName@",
values);
return @enum_name@_type;
}
GType
@enum_name@_get_type (void)
{
return @enum_name@_type;
}
/*** END value-tail ***/

View File

@@ -1,29 +0,0 @@
/*** BEGIN file-header ***/
#ifndef __XED_FILE_BROWSER_ENUM_TYPES_H__
#define __XED_FILE_BROWSER_ENUM_TYPES_H__
#include <glib-object.h>
G_BEGIN_DECLS
/*** END file-header ***/
/*** BEGIN file-production ***/
/* Enumerations from "@filename@" */
/*** END file-production ***/
/*** BEGIN enumeration-production ***/
#define XED_TYPE_@ENUMSHORT@ (@enum_name@_get_type())
GType @enum_name@_get_type (void) G_GNUC_CONST;
/*** END enumeration-production ***/
/*** BEGIN file-tail ***/
void xed_file_browser_enum_and_flag_register_type (GTypeModule * module);
G_END_DECLS
#endif /* __XED_FILE_BROWSER_ENUM_TYPES_H__ */
/*** END file-tail ***/

View File

@@ -1,5 +1,5 @@
VOID:UINT,STRING
VOID:OBJECT,OBJECT
BOOL:OBJECT,POINTER
BOOL:POINTER
BOOL:VOID
BOOLEAN:OBJECT,POINTER
BOOLEAN:POINTER
BOOLEAN:VOID

View File

@@ -20,10 +20,7 @@
*/
#ifdef HAVE_CONFIG_H
#include <config.h>
#endif
#include <string.h>
#include <glib/gi18n-lib.h>
#include <gmodule.h>
@@ -111,7 +108,6 @@ G_DEFINE_DYNAMIC_TYPE_EXTENDED (XedFileBrowserPlugin,
G_IMPLEMENT_INTERFACE_DYNAMIC (XED_TYPE_WINDOW_ACTIVATABLE,
xed_window_activatable_iface_init) \
\
xed_file_browser_enum_and_flag_register_type (type_module); \
_xed_file_browser_store_register_type (type_module); \
_xed_file_bookmarks_store_register_type (type_module); \
_xed_file_browser_view_register_type (type_module); \

View File

@@ -19,10 +19,7 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA.
*/
#ifdef HAVE_CONFIG_H
#include <config.h>
#endif
#include <string.h>
#include <glib/gi18n-lib.h>
#include <gio/gio.h>
@@ -350,7 +347,7 @@ xed_file_browser_store_class_init (XedFileBrowserStoreClass * klass)
g_param_spec_flags ("filter-mode",
"Filter Mode",
"The filter mode",
XED_TYPE_FILE_BROWSER_STORE_FILTER_MODE,
XED_FILE_BROWSER_TYPE_STORE_FILTER_MODE,
xed_file_browser_store_filter_mode_get_default (),
G_PARAM_READWRITE));
@@ -384,7 +381,7 @@ xed_file_browser_store_class_init (XedFileBrowserStoreClass * klass)
G_SIGNAL_RUN_LAST,
G_STRUCT_OFFSET (XedFileBrowserStoreClass,
no_trash), g_signal_accumulator_true_handled, NULL,
xed_file_browser_marshal_BOOL__POINTER,
xed_file_browser_marshal_BOOLEAN__POINTER,
G_TYPE_BOOLEAN, 1, G_TYPE_POINTER);
model_signals[RENAME] =
g_signal_new ("rename",

View File

@@ -19,10 +19,7 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA.
*/
#ifdef HAVE_CONFIG_H
#include <config.h>
#endif
#include <glib/gi18n-lib.h>
#include <xed/xed-utils.h>

View File

@@ -947,7 +947,7 @@ xed_file_browser_view_class_init (XedFileBrowserViewClass *klass)
g_param_spec_enum ("click-policy",
"Click Policy",
"The click policy",
XED_TYPE_FILE_BROWSER_VIEW_CLICK_POLICY,
XED_FILE_BROWSER_TYPE_VIEW_CLICK_POLICY,
XED_FILE_BROWSER_VIEW_CLICK_POLICY_DOUBLE,
G_PARAM_READWRITE | G_PARAM_CONSTRUCT));

View File

@@ -19,10 +19,7 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA.
*/
#ifdef HAVE_CONFIG_H
#include <config.h>
#endif
#include <sys/types.h>
#include <sys/stat.h>
#include <string.h>
@@ -30,7 +27,6 @@
#include <glib/gi18n-lib.h>
#include <gtk/gtk.h>
#include <gdk/gdkkeysyms.h>
#include <xed/xed-utils.h>
#include "xed-file-browser-utils.h"
@@ -470,7 +466,7 @@ xed_file_browser_widget_class_init (XedFileBrowserWidgetClass *klass)
confirm_delete),
g_signal_accumulator_true_handled,
NULL,
xed_file_browser_marshal_BOOL__OBJECT_POINTER,
xed_file_browser_marshal_BOOLEAN__OBJECT_POINTER,
G_TYPE_BOOLEAN,
2,
G_TYPE_OBJECT,
@@ -483,7 +479,7 @@ xed_file_browser_widget_class_init (XedFileBrowserWidgetClass *klass)
confirm_no_trash),
g_signal_accumulator_true_handled,
NULL,
xed_file_browser_marshal_BOOL__POINTER,
xed_file_browser_marshal_BOOLEAN__POINTER,
G_TYPE_BOOLEAN,
1,
G_TYPE_POINTER);

16
plugins/meson.build Normal file
View File

@@ -0,0 +1,16 @@
pluginsdatadir = join_paths(datadir, 'xed', 'plugins')
pluginslibdir = join_paths(libdir, 'xed', 'plugins')
subdir('docinfo')
subdir('filebrowser')
subdir('modelines')
subdir('sort')
subdir('taglist')
subdir('textsize')
subdir('time')
subdir('trailsave')
subdir('wordcompletion')
if enable_spell
subdir('spell')
endif

View File

@@ -1,38 +0,0 @@
# Modelines Plugin
plugindir = $(XED_PLUGINS_LIBS_DIR)
AM_CPPFLAGS = \
-I$(top_srcdir) \
$(XED_CFLAGS) \
$(WARN_CFLAGS) \
$(DISABLE_DEPRECATED_CFLAGS)
modelinesdir = $(XED_PLUGINS_DATA_DIR)/modelines
modelines_DATA = \
language-mappings
plugin_LTLIBRARIES = libmodelines.la
libmodelines_la_SOURCES = \
xed-modeline-plugin.h \
xed-modeline-plugin.c \
modeline-parser.h \
modeline-parser.c
libmodelines_la_LDFLAGS = $(PLUGIN_LIBTOOL_FLAGS)
libmodelines_la_LIBADD = $(XED_LIBS)
plugin_in_files = modelines.plugin.desktop.in
%.plugin: %.plugin.desktop.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*po) ; $(INTLTOOL_MERGE) $(top_srcdir)/po $< $@ -d -u -c $(top_builddir)/po/.intltool-merge-cache
plugin_DATA = $(plugin_in_files:.plugin.desktop.in=.plugin)
EXTRA_DIST = \
$(plugin_in_files) \
$(modelines_DATA)
CLEANFILES = $(plugin_DATA)
DISTCLEANFILES = $(plugin_DATA)
-include $(top_srcdir)/git.mk

View File

@@ -0,0 +1,40 @@
modelines_sources = [
'xed-modeline-plugin.h',
'xed-modeline-plugin.c',
'modeline-parser.h',
'modeline-parser.c'
]
modelines_deps = [
config_h,
glib,
gmodule,
gtk,
gtksourceview,
libpeas
]
library(
'modelines',
modelines_sources,
link_with: libxed,
dependencies: modelines_deps,
include_directories: include_dirs,
install_rpath: join_paths(prefix, libdir, 'xed'),
install: true,
install_dir: join_paths(libdir, 'xed', 'plugins')
)
install_data(
'language-mappings',
install_dir: join_paths(pluginsdatadir, 'modelines')
)
modelines_desktop = custom_target(
'modelines_desktop',
input: 'modelines.plugin.desktop.in',
output: 'modelines.plugin',
command: [intltool_merge, '-d', '-u', po_dir, '@INPUT@', '@OUTPUT@'],
install: true,
install_dir: pluginslibdir,
)

View File

@@ -19,19 +19,16 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA.
*/
#ifdef HAVE_CONFIG_H
# include <config.h>
#endif
#include <config.h>
#include <glib/gi18n-lib.h>
#include <gmodule.h>
#include "xed-modeline-plugin.h"
#include "modeline-parser.h"
#include <xed/xed-debug.h>
#include <xed/xed-view-activatable.h>
#include <xed/xed-view.h>
#include "xed-modeline-plugin.h"
#include "modeline-parser.h"
struct _XedModelinePluginPrivate
{
XedView *view;

View File

@@ -1,31 +0,0 @@
# sort plugin
plugindir = $(XED_PLUGINS_LIBS_DIR)
AM_CPPFLAGS = \
-I$(top_srcdir) \
$(XED_CFLAGS) \
$(WARN_CFLAGS) \
$(DISABLE_DEPRECATED_CFLAGS)
plugin_LTLIBRARIES = libsort.la
libsort_la_SOURCES = \
xed-sort-plugin.h \
xed-sort-plugin.c
libsort_la_LDFLAGS = $(PLUGIN_LIBTOOL_FLAGS)
libsort_la_LIBADD = $(XED_LIBS)
plugin_in_files = sort.plugin.desktop.in
%.plugin: %.plugin.desktop.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*po) ; $(INTLTOOL_MERGE) $(top_srcdir)/po $< $@ -d -u -c $(top_builddir)/po/.intltool-merge-cache
plugin_DATA = $(plugin_in_files:.plugin.desktop.in=.plugin)
EXTRA_DIST = $(plugin_in_files)
CLEANFILES = $(plugin_DATA)
DISTCLEANFILES = $(plugin_DATA)
-include $(top_srcdir)/git.mk

31
plugins/sort/meson.build Normal file
View File

@@ -0,0 +1,31 @@
sort_sources = [
'xed-sort-plugin.h',
'xed-sort-plugin.c'
]
sort_deps = [
config_h,
glib,
gtksourceview,
libpeas
]
library(
'sort',
sort_sources,
link_with: libxed,
dependencies: sort_deps,
include_directories: include_dirs,
install_rpath: join_paths(prefix, libdir, 'xed'),
install: true,
install_dir: join_paths(libdir, 'xed', 'plugins'),
)
sort_desktop = custom_target(
'sort_desktop',
input: 'sort.plugin.desktop.in',
output: 'sort.plugin',
command: [intltool_merge, '-d', '-u', po_dir, '@INPUT@', '@OUTPUT@'],
install: true,
install_dir: pluginslibdir,
)

View File

@@ -21,22 +21,18 @@
* $Id$
*/
#ifdef HAVE_CONFIG_H
#include <config.h>
#endif
#include "xed-sort-plugin.h"
#include <string.h>
#include <stdlib.h>
#include <glib/gi18n.h>
#include <xed/xed-window.h>
#include <xed/xed-window-activatable.h>
#include <xed/xed-debug.h>
#include <xed/xed-utils.h>
#include <xed/xed-app.h>
#include "xed-sort-plugin.h"
#define XED_SORT_PLUGIN_GET_PRIVATE(object)(G_TYPE_INSTANCE_GET_PRIVATE ((object), XED_TYPE_SORT_PLUGIN, XedSortPluginPrivate))
#define MENU_PATH "/MenuBar/EditMenu/EditOps_6"

View File

@@ -1,58 +0,0 @@
# Spell checker plugin
plugindir = $(XED_PLUGINS_LIBS_DIR)
AM_CPPFLAGS = \
-I$(top_srcdir) \
$(XED_CFLAGS) \
$(GSPELL_CFLAGS) \
$(WARN_CFLAGS) \
$(DISABLE_DEPRECATED_CFLAGS)
BUILT_SOURCES = \
xed-spell-marshal.c \
xed-spell-marshal.h
plugin_LTLIBRARIES = libspell.la
libspell_la_SOURCES = \
xed-spell-plugin.c \
xed-spell-plugin.h \
$(BUILT_SOURCES)
libspell_la_LDFLAGS = $(PLUGIN_LIBTOOL_FLAGS)
libspell_la_LIBADD = $(XED_LIBS) $(GSPELL_LIBS)
uidir = $(XED_PLUGINS_DATA_DIR)/spell
ui_DATA = xed-spell-setup-dialog.ui
xed-spell-marshal.h: xed-spell-marshal.list $(GLIB_GENMARSHAL)
$(AM_V_GEN) $(GLIB_GENMARSHAL) $< --header --prefix=xed_marshal > $@
xed-spell-marshal.c: xed-spell-marshal.list $(GLIB_GENMARSHAL)
$(AM_V_GEN) echo "#include \"xed-spell-marshal.h\"" > $@ && \
$(GLIB_GENMARSHAL) $< --body --prefix=xed_marshal >> $@
plugin_in_files = spell.plugin.desktop.in
%.plugin: %.plugin.desktop.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*po) ; $(INTLTOOL_MERGE) $(top_srcdir)/po $< $@ -d -u -c $(top_builddir)/po/.intltool-merge-cache
plugin_DATA = $(plugin_in_files:.plugin.desktop.in=.plugin)
@INTLTOOL_XML_NOMERGE_RULE@
spell_gschema_in = org.x.editor.plugins.spell.gschema.xml.in
gsettings_SCHEMAS = $(spell_gschema_in:.xml.in=.xml)
@GSETTINGS_RULES@
EXTRA_DIST = \
$(ui_DATA) \
$(plugin_in_files) \
xed-spell-marshal.list \
$(spell_gschema_in)
CLEANFILES = $(BUILT_SOURCES) $(plugin_DATA) $(gsettings_SCHEMAS)
dist-hook:
cd $(distdir); rm -f $(BUILT_SOURCES)
-include $(top_srcdir)/git.mk

57
plugins/spell/meson.build Normal file
View File

@@ -0,0 +1,57 @@
spell_sources = [
'xed-spell-plugin.c',
'xed-spell-plugin.h'
]
spell_marshal = gnome.genmarshal(
'xed-spell-marshal',
sources: 'xed-spell-marshal.list',
prefix: 'xed_spell_marshal'
)
spell_deps = [
config_h,
glib,
gspell,
gtksourceview,
libpeas,
libpeas_gtk
]
library(
'spell',
spell_sources + spell_marshal,
link_with: libxed,
dependencies: spell_deps,
include_directories: include_dirs,
install_rpath: join_paths(prefix, libdir, 'xed'),
install: true,
install_dir: join_paths(libdir, 'xed', 'plugins')
)
install_data(
'xed-spell-setup-dialog.ui',
install_dir: join_paths(pluginsdatadir, 'spell')
)
spell_desktop = custom_target(
'spell_desktop',
input: 'spell.plugin.desktop.in',
output: 'spell.plugin',
command: [intltool_merge, '-d', '-u', po_dir, '@INPUT@', '@OUTPUT@'],
install: true,
install_dir: pluginslibdir,
)
spell_schema_file = configure_file(
input: 'org.x.editor.plugins.spell.gschema.xml.in',
output: 'org.x.editor.plugins.spell.gschema.xml',
configuration: schema_conf,
install_dir: join_paths(datadir, 'glib-2.0', 'schemas')
)
install_data(
spell_schema_file,
install_dir: schema_dir
)

View File

@@ -19,14 +19,9 @@
*/
#include <config.h>
#include "xed-spell-plugin.h"
#include <string.h> /* For strlen */
#include <glib/gi18n-lib.h>
#include <libpeas-gtk/peas-gtk-configurable.h>
#include <xed/xed-app.h>
#include <xed/xed-window.h>
#include <xed/xed-window-activatable.h>
@@ -34,6 +29,8 @@
#include <xed/xed-utils.h>
#include <gspell/gspell.h>
#include "xed-spell-plugin.h"
#define XED_METADATA_ATTRIBUTE_SPELL_LANGUAGE "metadata::xed-spell-language"
#define XED_METADATA_ATTRIBUTE_SPELL_ENABLED "metadata::xed-spell-enabled"

View File

@@ -1,60 +0,0 @@
# Tag list plugin
plugindir = $(XED_PLUGINS_LIBS_DIR)
taglistdir = $(XED_PLUGINS_DATA_DIR)/taglist
taglist_in_files = \
HTML.tags.xml.in \
Latex.tags.xml.in \
XSLT.tags.xml.in \
XUL.tags.xml.in
taglist_DATA = $(taglist_in_files:.tags.xml.in=.tags.gz)
AM_CPPFLAGS = \
-I$(top_srcdir) \
$(XED_CFLAGS) \
$(WARN_CFLAGS) \
$(DISABLE_DEPRECATED_CFLAGS)
plugin_LTLIBRARIES = libtaglist.la
libtaglist_la_SOURCES = \
xed-taglist-plugin-parser.c \
xed-taglist-plugin-parser.h \
xed-taglist-plugin-panel.c \
xed-taglist-plugin-panel.h \
xed-taglist-plugin.c \
xed-taglist-plugin.h
libtaglist_la_LDFLAGS = $(PLUGIN_LIBTOOL_FLAGS)
libtaglist_la_LIBADD = $(XED_LIBS)
plugin_in_files = taglist.plugin.desktop.in
%.plugin: %.plugin.desktop.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*po)
$(INTLTOOL_MERGE) $(top_srcdir)/po $< $@ -d -u -c $(top_builddir)/po/.intltool-merge-cache
GZIP_ENV = -9
%.tags.gz: %.tags.xml.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po)
LC_ALL=C $(INTLTOOL_MERGE) $(top_srcdir)/po $< $(@:.gz=) -x -u -c $(top_builddir)/po/.intltool-merge-cache
GZIP=$(GZIP_ENV) gzip -n -f $(@:.gz=)
plugin_DATA = $(plugin_in_files:.plugin.desktop.in=.plugin)
EXTRA_DIST = \
$(taglist_in_files) $(taglist_DATA) \
$(plugin_in_files) $(plugin_DATA)
CLEANFILES = \
$(taglist_DATA) \
$(plugin_DATA)
DISTCLEANFILES = \
$(taglist_DATA) \
$(plugin_DATA)
-include $(top_srcdir)/git.mk

View File

@@ -0,0 +1,63 @@
taglist_sources = [
'xed-taglist-plugin-parser.c',
'xed-taglist-plugin-parser.h',
'xed-taglist-plugin-panel.c',
'xed-taglist-plugin-panel.h',
'xed-taglist-plugin.c',
'xed-taglist-plugin.h'
]
taglist_in_files = [
'C.tags@0@',
'HTML.tags@0@',
'Latex.tags@0@',
'XSLT.tags@0@',
'XUL.tags@0@'
]
taglist_deps = [
config_h,
glib,
gtk,
gtksourceview,
libpeas,
libxml
]
library(
'taglist',
taglist_sources,
link_with: libxed,
dependencies: taglist_deps,
include_directories: include_dirs,
install_rpath: join_paths(prefix, libdir, 'xed'),
install: true,
install_dir: join_paths(libdir, 'xed', 'plugins')
)
taglist_desktop = custom_target(
'taglist_desktop',
input: 'taglist.plugin.desktop.in',
output: 'taglist.plugin',
command: [intltool_merge, '-d', '-u', po_dir, '@INPUT@', '@OUTPUT@'],
install: true,
install_dir: pluginslibdir,
)
foreach tagtype : taglist_in_files
taglist_xml = custom_target(
'@0@xmltags'.format(tagtype.format('')),
input: tagtype.format('.xml.in'),
output: tagtype.format(''),
command: [intltool_merge, '-x', '-u', po_dir, '@INPUT@', '@OUTPUT@'],
)
taglist_gz = custom_target(
'@0@gztags'.format(tagtype.format('')),
input: taglist_xml,
output: tagtype.format('.gz'),
command: ['gzip', '-9', '-n', '-f', '@INPUT@'],
install: true,
install_dir: join_paths(pluginsdatadir, 'taglist')
)
endforeach

View File

@@ -28,22 +28,17 @@
* $Id$
*/
#ifdef HAVE_CONFIG_H
#include <config.h>
#endif
#include <string.h>
#include "xed-taglist-plugin-panel.h"
#include "xed-taglist-plugin-parser.h"
#include <xed/xed-utils.h>
#include <xed/xed-debug.h>
#include <gtk/gtk.h>
#include <gdk/gdkkeysyms.h>
#include <glib/gi18n.h>
#include "xed-taglist-plugin-panel.h"
#include "xed-taglist-plugin-parser.h"
#define XED_TAGLIST_PLUGIN_PANEL_GET_PRIVATE(object)(G_TYPE_INSTANCE_GET_PRIVATE ((object), \
XED_TYPE_TAGLIST_PLUGIN_PANEL, \
XedTaglistPluginPanelPrivate))

View File

@@ -30,15 +30,11 @@
/* FIXME: we should rewrite the parser to avoid using DOM */
#ifdef HAVE_CONFIG_H
#include <config.h>
#endif
#include <string.h>
#include <libxml/parser.h>
#include <glib.h>
#include <glib/gi18n.h>
#include <xed/xed-debug.h>
#include "xed-taglist-plugin-parser.h"

View File

@@ -27,20 +27,16 @@
* $Id$
*/
#ifdef HAVE_CONFIG_H
#include <config.h>
#endif
#include <glib/gi18n-lib.h>
#include <xed/xed-window.h>
#include <xed/xed-window-activatable.h>
#include <xed/xed-debug.h>
#include "xed-taglist-plugin.h"
#include "xed-taglist-plugin-panel.h"
#include "xed-taglist-plugin-parser.h"
#include <glib/gi18n-lib.h>
#include <xed/xed-window.h>
#include <xed/xed-window-activatable.h>
#include <xed/xed-debug.h>
#define XED_TAGLIST_PLUGIN_GET_PRIVATE(object)(G_TYPE_INSTANCE_GET_PRIVATE ((object), XED_TYPE_TAGLIST_PLUGIN, XedTaglistPluginPrivate))
struct _XedTaglistPluginPrivate

View File

@@ -1,16 +0,0 @@
# Textsize Plugin
SUBDIRS = textsize
plugindir = $(XED_PLUGINS_LIBS_DIR)
plugin_in_files = textsize.plugin.desktop.in
%.plugin: %.plugin.desktop.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*po) ; $(INTLTOOL_MERGE) $(top_srcdir)/po $< $@ -d -u -c $(top_builddir)/po/.intltool-merge-cache
plugin_DATA = $(plugin_in_files:.plugin.desktop.in=.plugin)
EXTRA_DIST = \
$(plugin_in_files)
CLEANFILES = $(plugin_DATA)
DISTCLEANFILES = $(plugin_DATA)
-include $(top_srcdir)/git.mk

View File

@@ -0,0 +1,13 @@
install_subdir(
'textsize',
install_dir: pluginslibdir
)
textsize_desktop = custom_target(
'textsize_desktop',
input: 'textsize.plugin.desktop.in',
output: 'textsize.plugin',
command: [intltool_merge, '-d', '-u', po_dir, '@INPUT@', '@OUTPUT@'],
install: true,
install_dir: pluginslibdir,
)

View File

@@ -1,11 +0,0 @@
plugindir = $(XED_PLUGINS_LIBS_DIR)/textsize
plugin_PYTHON = \
__init__.py \
signals.py \
documenthelper.py
CLEANFILES =
DISTCLEANFILES =
-include $(top_srcdir)/git.mk

View File

@@ -1,41 +0,0 @@
# time plugin
plugindir = $(XED_PLUGINS_LIBS_DIR)
AM_CPPFLAGS = \
-I$(top_srcdir) \
$(XED_CFLAGS) \
$(WARN_CFLAGS) \
$(DISABLE_DEPRECATED_CFLAGS)
plugin_LTLIBRARIES = libtime.la
libtime_la_SOURCES = \
xed-time-plugin.h \
xed-time-plugin.c
libtime_la_LDFLAGS = $(PLUGIN_LIBTOOL_FLAGS)
libtime_la_LIBADD = $(XED_LIBS)
uidir = $(XED_PLUGINS_DATA_DIR)/time
ui_DATA = \
xed-time-dialog.ui \
xed-time-setup-dialog.ui
plugin_in_files = time.plugin.desktop.in
%.plugin: %.plugin.desktop.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*po) ; $(INTLTOOL_MERGE) $(top_srcdir)/po $< $@ -d -u -c $(top_builddir)/po/.intltool-merge-cache
plugin_DATA = $(plugin_in_files:.plugin.desktop.in=.plugin)
@INTLTOOL_XML_NOMERGE_RULE@
time_gschema_in = org.x.editor.plugins.time.gschema.xml.in
gsettings_SCHEMAS = $(time_gschema_in:.xml.in=.xml)
@GSETTINGS_RULES@
EXTRA_DIST = $(ui_DATA) $(plugin_in_files) $(time_gschema_in)
CLEANFILES = $(plugin_DATA) $(gsettings_SCHEMAS_in) $(gsettings_SCHEMASn)
DISTCLEANFILES = $(plugin_DATA) $(gsettings_SCHEMAS_in) $(gsettings_SCHEMAS)
-include $(top_srcdir)/git.mk

55
plugins/time/meson.build Normal file
View File

@@ -0,0 +1,55 @@
time_sources = [
'xed-time-plugin.h',
'xed-time-plugin.c'
]
time_deps = [
config_h,
gio,
glib,
gtksourceview,
libpeas,
libpeas_gtk
]
library(
'time',
time_sources,
link_with: libxed,
dependencies: time_deps,
include_directories: include_dirs,
install_rpath: join_paths(prefix, libdir, 'xed'),
install: true,
install_dir: join_paths(libdir, 'xed', 'plugins')
)
time_ui_sources = [
'xed-time-dialog.ui',
'xed-time-setup-dialog.ui'
]
install_data(
time_ui_sources,
install_dir: join_paths(pluginsdatadir, 'time')
)
time_desktop = custom_target(
'time_desktop',
input: 'time.plugin.desktop.in',
output: 'time.plugin',
command: [intltool_merge, '-d', '-u', po_dir, '@INPUT@', '@OUTPUT@'],
install: true,
install_dir: pluginslibdir,
)
time_schema_file = configure_file(
input: 'org.x.editor.plugins.time.gschema.xml.in',
output: 'org.x.editor.plugins.time.gschema.xml',
configuration: schema_conf,
install_dir: join_paths(datadir, 'glib-2.0', 'schemas')
)
install_data(
time_schema_file,
install_dir: schema_dir
)

View File

@@ -24,22 +24,18 @@
* See the ChangeLog files for a list of changes.
*/
#ifdef HAVE_CONFIG_H
#include <config.h>
#endif
#include <string.h>
#include <glib/gi18n-lib.h>
#include <glib.h>
#include <gio/gio.h>
#include <xed/xed-window.h>
#include <xed/xed-window-activatable.h>
#include <libpeas-gtk/peas-gtk-configurable.h>
#include <xed/xed-debug.h>
#include <xed/xed-utils.h>
#include <xed/xed-app.h>
#include "xed-time-plugin.h"
#define XED_TIME_PLUGIN_GET_PRIVATE(object)(G_TYPE_INSTANCE_GET_PRIVATE ((object), \

View File

@@ -1,31 +0,0 @@
# trailsave plugin
plugindir = $(XED_PLUGINS_LIBS_DIR)
AM_CPPFLAGS = \
-I$(top_srcdir) \
$(XED_CFLAGS) \
$(WARN_CFLAGS) \
$(DISABLE_DEPRECATED_CFLAGS)
plugin_LTLIBRARIES = libtrailsave.la
libtrailsave_la_SOURCES = \
xed-trail-save-plugin.h \
xed-trail-save-plugin.c
libtrailsave_la_LDFLAGS = $(PLUGIN_LIBTOOL_FLAGS)
libtrailsave_la_LIBADD = $(XED_LIBS)
plugin_in_files = trailsave.plugin.desktop.in
%.plugin: %.plugin.desktop.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*po) ; $(INTLTOOL_MERGE) $(top_srcdir)/po $< $@ -d -u -c $(top_builddir)/po/.intltool-merge-cache
plugin_DATA = $(plugin_in_files:.plugin.desktop.in=.plugin)
EXTRA_DIST = $(plugin_in_files)
CLEANFILES = $(plugin_DATA)
DISTCLEANFILES = $(plugin_DATA)
-include $(top_srcdir)/git.mk

View File

@@ -0,0 +1,31 @@
trailsave_sources = [
'xed-trail-save-plugin.h',
'xed-trail-save-plugin.c'
]
trailsave_deps = [
config_h,
glib,
gtksourceview,
libpeas
]
library(
'trailsave',
trailsave_sources,
link_with: libxed,
dependencies: trailsave_deps,
include_directories: include_dirs,
install_rpath: join_paths(prefix, libdir, 'xed'),
install: true,
install_dir: join_paths(libdir, 'xed', 'plugins')
)
trailsave_desktop = custom_target(
'trailsave_desktop',
input: 'trailsave.plugin.desktop.in',
output: 'trailsave.plugin',
command: [intltool_merge, '-d', '-u', po_dir, '@INPUT@', '@OUTPUT@'],
install: true,
install_dir: pluginslibdir,
)

View File

@@ -16,18 +16,14 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA.
*/
#ifdef HAVE_CONFIG_H
#include <config.h>
#endif
#include <string.h>
#include "xed-trail-save-plugin.h"
#include <xed/xed-window.h>
#include <xed/xed-window-activatable.h>
#include <xed/xed-debug.h>
#include "xed-trail-save-plugin.h"
#define XED_TRAIL_SAVE_PLUGIN_GET_PRIVATE(object)(G_TYPE_INSTANCE_GET_PRIVATE ((object), \
XED_TYPE_TRAIL_SAVE_PLUGIN, \
XedTrailSavePluginPrivate))

View File

@@ -1,49 +0,0 @@
# Word completion plugin
plugindir = $(XED_PLUGINS_LIBS_DIR)
AM_CPPFLAGS = \
-I$(top_srcdir) \
$(XED_CFLAGS) \
$(ENCHANT_CFLAGS) \
$(WARN_CFLAGS) \
$(DISABLE_DEPRECATED_CFLAGS)
plugin_LTLIBRARIES = libwordcompletion.la
libwordcompletion_la_SOURCES = \
xed-wordcompletion-plugin.h \
xed-wordcompletion-plugin.c
libwordcompletion_la_LDFLAGS = $(PLUGIN_LIBTOOL_FLAGS)
libwordcompletion_la_LIBADD = $(XED_LIBS) $(ENCHANT_LIBS)
plugin_in_files = wordcompletion.plugin.desktop.in
%.plugin: %.plugin.desktop.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*po) ; $(INTLTOOL_MERGE) $(top_srcdir)/po $< $@ -d -u -c $(top_builddir)/po/.intltool-merge-cache
plugin_DATA = $(plugin_in_files:.plugin.desktop.in=.plugin)
uidir = $(XED_PLUGINS_DATA_DIR)/wordcompletion
ui_DATA = xed-wordcompletion-configure.ui
@INTLTOOL_XML_NOMERGE_RULE@
wordcompletion_gschema_in = org.x.editor.plugins.wordcompletion.gschema.xml.in
gsettings_SCHEMAS = $(wordcompletion_gschema_in:.xml.in=.xml)
@GSETTINGS_RULES@
EXTRA_DIST = \
$(plugin_in_files) \
$(wordcompletion_gschema_in)
CLEANFILES = \
$(plugin_DATA) \
$(gsettings_SCHEMAS)
DISTCLEANFILES = \
$(plugin_DATA)
dist-hook:
cd $(distdir); rm -f $(BUILT_SOURCES)
-include $(top_srcdir)/git.mk

View File

@@ -0,0 +1,43 @@
wordcompletion_sources = [
'xed-wordcompletion-plugin.h',
'xed-wordcompletion-plugin.c'
]
wordcompletion_deps = [
config_h,
gio,
glib,
gtksourceview,
libpeas,
libpeas_gtk
]
library(
'wordcompletion',
wordcompletion_sources,
link_with: libxed,
dependencies: wordcompletion_deps,
include_directories: include_dirs,
install_rpath: join_paths(prefix, libdir, 'xed'),
install: true,
install_dir: join_paths(libdir, 'xed', 'plugins')
)
wordcompletion_desktop = custom_target(
'wordcompletion_desktop',
input: 'wordcompletion.plugin.desktop.in',
output: 'wordcompletion.plugin',
command: [intltool_merge, '-d', '-u', po_dir, '@INPUT@', '@OUTPUT@'],
install: true,
install_dir: pluginslibdir,
)
install_data(
'xed-wordcompletion-configure.ui',
install_dir: join_paths(pluginsdatadir, 'wordcompletion')
)
install_data(
'org.x.editor.plugins.wordcompletion.gschema.xml',
install_dir: schema_dir
)

View File

@@ -19,16 +19,10 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
*/
#ifdef HAVE_CONFIG_H
#include <config.h>
#endif
#include "xed-wordcompletion-plugin.h"
#include <glib/gi18n-lib.h>
#include <glib.h>
#include <gio/gio.h>
#include <xed/xed-debug.h>
#include <xed/xed-window.h>
#include <xed/xed-window-activatable.h>
@@ -39,6 +33,8 @@
#include <gtksourceview/gtksource.h>
#include <gtksourceview/completion-providers/words/gtksourcecompletionwords.h>
#include "xed-wordcompletion-plugin.h"
#define WINDOW_PROVIDER "XedWordCompletionPluginProvider"
#define WORDCOMPLETION_SETTINGS_BASE "org.x.editor.plugins.wordcompletion"