[gnome-software] trivial: Split out snap to a new directory
- From: Richard Hughes <rhughes src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-software] trivial: Split out snap to a new directory
- Date: Tue, 7 Mar 2017 17:05:00 +0000 (UTC)
commit 332f0b0f5056f2b22f131843b77e7d62ca46c582
Author: Richard Hughes <richard hughsie com>
Date: Tue Mar 7 12:07:38 2017 +0000
trivial: Split out snap to a new directory
configure.ac | 1 +
plugins/Makefile.am | 26 +++---------------
plugins/snap/Makefile.am | 28 ++++++++++++++++++++
plugins/{ => snap}/gs-plugin-snap.c | 0
plugins/{ => snap}/gs-snapd.c | 0
plugins/{ => snap}/gs-snapd.h | 0
.../org.gnome.Software.Plugin.Snap.metainfo.xml.in | 0
po/POTFILES.in | 2 +-
8 files changed, 34 insertions(+), 23 deletions(-)
---
diff --git a/configure.ac b/configure.ac
index fb6aa04..3c560fb 100644
--- a/configure.ac
+++ b/configure.ac
@@ -510,6 +510,7 @@ plugins/external-appstream/Makefile
plugins/limba/Makefile
plugins/odrs/Makefile
plugins/ostree/Makefile
+plugins/snap/Makefile
plugins/steam/Makefile
plugins/ubuntu-reviews/Makefile
src/Makefile
diff --git a/plugins/Makefile.am b/plugins/Makefile.am
index 6d3e864..bb1f8e2 100644
--- a/plugins/Makefile.am
+++ b/plugins/Makefile.am
@@ -27,6 +27,10 @@ if HAVE_EXTERNAL_APPSTREAM
SUBDIRS += external-appstream
endif
+if HAVE_SNAP
+SUBDIRS += snap
+endif
+
AM_CPPFLAGS = \
-DI_KNOW_THE_PACKAGEKIT_GLIB2_API_IS_SUBJECT_TO_CHANGE \
-DDATADIR=\"$(datadir)\" \
@@ -60,10 +64,6 @@ plugin_LTLIBRARIES = \
appdata_in_files =
-if HAVE_SNAP
-plugin_LTLIBRARIES += libgs_plugin_snap.la
-endif
-
if HAVE_PACKAGEKIT
plugin_LTLIBRARIES += \
libgs_plugin_systemd-updates.la \
@@ -314,24 +314,6 @@ libgs_plugin_packagekit_proxy_la_LIBADD = $(GS_PLUGIN_LIBS) $(PACKAGEKIT_LIBS)
libgs_plugin_packagekit_proxy_la_LDFLAGS = -module -avoid-version
libgs_plugin_packagekit_proxy_la_CFLAGS = $(GS_PLUGIN_CFLAGS) $(PACKAGEKIT_CFLAGS)
-if HAVE_SNAP
-appdata_in_files += org.gnome.Software.Plugin.Snap.metainfo.xml.in
-libgs_plugin_snap_la_SOURCES = \
- gs-plugin-snap.c \
- gs-snapd.h \
- gs-snapd.c
-libgs_plugin_snap_la_LIBADD = \
- $(GS_PLUGIN_LIBS) \
- $(SNAP_LIBS) \
- $(SOUP_LIBS) \
- $(JSON_GLIB_LIBS)
-libgs_plugin_snap_la_LDFLAGS = -module -avoid-version
-libgs_plugin_snap_la_CFLAGS = \
- $(GS_PLUGIN_CFLAGS) \
- $(JSON_GLIB_CFLAGS) \
- $(SNAP_CFLAGS)
-endif
-
libgs_plugin_ubuntuone_la_SOURCES = \
gs-plugin-ubuntuone.c
libgs_plugin_ubuntuone_la_LIBADD = \
diff --git a/plugins/snap/Makefile.am b/plugins/snap/Makefile.am
new file mode 100644
index 0000000..88fb121
--- /dev/null
+++ b/plugins/snap/Makefile.am
@@ -0,0 +1,28 @@
+plugindir = $(GS_PLUGIN_DIR)
+plugin_LTLIBRARIES = libgs_plugin_snap.la
+
+libgs_plugin_snap_la_SOURCES = \
+ gs-plugin-snap.c \
+ gs-snapd.h \
+ gs-snapd.c
+libgs_plugin_snap_la_LIBADD = \
+ $(GS_PLUGIN_LIBS) \
+ $(SNAP_LIBS) \
+ $(SOUP_LIBS) \
+ $(JSON_GLIB_LIBS)
+libgs_plugin_snap_la_LDFLAGS = -module -avoid-version
+libgs_plugin_snap_la_CFLAGS = \
+ $(GS_PLUGIN_CFLAGS) \
+ $(JSON_GLIB_CFLAGS) \
+ $(SNAP_CFLAGS)
+
+%.metainfo.xml: %.metainfo.xml.in
+ $(AM_V_GEN) msgfmt --xml -d $(top_srcdir)/po --template $< -o $@
+
+appdata_in_files = org.gnome.Software.Plugin.Snap.metainfo.xml.in
+appdatadir = $(datadir)/appdata
+appdata_DATA = $(appdata_in_files:.xml.in=.xml)
+EXTRA_DIST = $(appdata_in_files)
+CLEANFILES = $(appdata_DATA)
+
+-include $(top_srcdir)/git.mk
diff --git a/plugins/gs-plugin-snap.c b/plugins/snap/gs-plugin-snap.c
similarity index 100%
rename from plugins/gs-plugin-snap.c
rename to plugins/snap/gs-plugin-snap.c
diff --git a/plugins/gs-snapd.c b/plugins/snap/gs-snapd.c
similarity index 100%
rename from plugins/gs-snapd.c
rename to plugins/snap/gs-snapd.c
diff --git a/plugins/gs-snapd.h b/plugins/snap/gs-snapd.h
similarity index 100%
rename from plugins/gs-snapd.h
rename to plugins/snap/gs-snapd.h
diff --git a/plugins/org.gnome.Software.Plugin.Snap.metainfo.xml.in
b/plugins/snap/org.gnome.Software.Plugin.Snap.metainfo.xml.in
similarity index 100%
rename from plugins/org.gnome.Software.Plugin.Snap.metainfo.xml.in
rename to plugins/snap/org.gnome.Software.Plugin.Snap.metainfo.xml.in
diff --git a/po/POTFILES.in b/po/POTFILES.in
index 2c64a5a..b7b5711 100644
--- a/po/POTFILES.in
+++ b/po/POTFILES.in
@@ -74,5 +74,5 @@ plugins/org.gnome.Software.Plugin.Flatpak.metainfo.xml.in
plugins/org.gnome.Software.Plugin.Fwupd.metainfo.xml.in
plugins/limba/org.gnome.Software.Plugin.Limba.metainfo.xml.in
plugins/odrs/org.gnome.Software.Plugin.Odrs.metainfo.xml.in
-plugins/org.gnome.Software.Plugin.Snap.metainfo.xml.in
+plugins/snap/org.gnome.Software.Plugin.Snap.metainfo.xml.in
plugins/steam/org.gnome.Software.Plugin.Steam.metainfo.xml.in
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]