[gnome-apps-nightly] org.gnome.Builder: Add sysprof and polkit



commit 756e9e07022e6696c49937043aaaea3b984dc8b4
Author: Patrick Griffis <tingping tingping se>
Date:   Thu Sep 8 17:24:25 2016 -0400

    org.gnome.Builder: Add sysprof and polkit

 org.gnome.Builder.json                             |   40 +++++++-
 polkit-autogen                                     |    4 +
 ...build-Add-option-to-build-without-polkitd.patch |  101 ++++++++++++++++++++
 3 files changed, 142 insertions(+), 3 deletions(-)
---
diff --git a/org.gnome.Builder.json b/org.gnome.Builder.json
index 294026d..da256c9 100644
--- a/org.gnome.Builder.json
+++ b/org.gnome.Builder.json
@@ -19,11 +19,13 @@
         /* Needs to talk to the network: */
         "--share=network",
         "--talk-name=org.gtk.vfs.*",
+        "--system-talk-name=org.freedesktop.PolicyKit1",
+        "--system-talk-name=org.gnome.Sysprof2",
         /* Needed for dconf to work (+ host or homedir read access from above) */
         "--filesystem=xdg-run/dconf",
-       "--filesystem=~/.config/dconf:ro",
+        "--filesystem=~/.config/dconf:ro",
         "--talk-name=ca.desrt.dconf",
-       "--env=DCONF_USER_CONFIG_DIR=.config/dconf",
+        "--env=DCONF_USER_CONFIG_DIR=.config/dconf",
         /* We need access to auth agents */
         "--talk-name=org.freedesktop.secrets",
         /* Needed for various SSL certificates to work */
@@ -46,6 +48,38 @@
                 "*.la", "*.a"],
     "modules": [
         {
+            "name": "polkit",
+            "config-opts": [ "--disable-polkitd", "--disable-man-pages", "--disable-introspection" ],
+            "rm-configure": true,
+            "sources": [
+                {
+                    "type": "archive",
+                    "url": "http://www.freedesktop.org/software/polkit/releases/polkit-0.113.tar.gz";,
+                    "sha256": "e1c095093c654951f78f8618d427faf91cf62abdefed98de40ff65eca6413c81"
+                },
+                {
+                    "type": "patch",
+                    "path": "polkit-build-Add-option-to-build-without-polkitd.patch"
+                },
+                {
+                    "type": "file",
+                    "path": "polkit-autogen",
+                    "dest-filename": "autogen.sh"
+                }
+            ]
+        },
+        {
+            "name": "sysprof",
+            "config-opts": [ "--enable-gtk", "--disable-sysprofd" ],
+            "sources": [
+                {
+                    "type": "archive",
+                    "url": "https://download.gnome.org/sources/sysprof/3.21/sysprof-3.21.91.tar.xz";,
+                    "sha256": "848ac43f3097789bb07267659a6f0e953c8ab6274a142dad924b20b84e5706d4"
+                }
+            ]
+        },
+        {
             "name": "python3-jedi",
             "no-autogen": true,
             "sources": [
@@ -176,7 +210,6 @@
             ]
         },
         {
-        {
             "name": "devhelp",
             "cleanup": [ "/bin/*" ],
             "sources": [
@@ -186,6 +219,7 @@
                 }
             ]
         },
+        {
             "name": "gnome-builder",
             "config-opts": [ "--enable-tracing", "--enable-debug" ],
             "sources": [
diff --git a/polkit-autogen b/polkit-autogen
new file mode 100755
index 0000000..3ba457e
--- /dev/null
+++ b/polkit-autogen
@@ -0,0 +1,4 @@
+#!/bin/sh
+
+gtkdocize --flavour no-tmpl
+autoreconf -if
diff --git a/polkit-build-Add-option-to-build-without-polkitd.patch 
b/polkit-build-Add-option-to-build-without-polkitd.patch
new file mode 100644
index 0000000..f201c20
--- /dev/null
+++ b/polkit-build-Add-option-to-build-without-polkitd.patch
@@ -0,0 +1,101 @@
+From dab179770380918462d0d76e08b11e4abe55c933 Mon Sep 17 00:00:00 2001
+From: Patrick Griffis <tingping tingping se>
+Date: Thu, 8 Sep 2016 16:15:54 -0400
+Subject: [PATCH] build: Add option to build without polkitd
+
+This is for any consumer that needs libpolkit but does
+not need polkitd. For example an application running in
+flatpak.
+---
+ configure.ac     | 29 ++++++++++++++++++++---------
+ src/Makefile.am  |  6 +++++-
+ test/Makefile.am |  6 +++++-
+ 3 files changed, 30 insertions(+), 11 deletions(-)
+
+diff --git a/configure.ac b/configure.ac
+index 97d4222..a08785c 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -129,20 +129,30 @@ AC_DEFINE([GLIB_VERSION_MIN_REQUIRED], [GLIB_VERSION_2_30],
+ AC_DEFINE([GLIB_VERSION_MAX_ALLOWED], [G_ENCODE_VERSION(2,34)],
+         [Notify us when we'll need to transition away from g_type_init()])
+ 
++
++AC_ARG_ENABLE([polkitd],
++              [AS_HELP_STRING([--disable-polkitd], [Do not build polkitd])],
++              [enable_polkitd=$enableval], [enable_polkitd=yes])
++AM_CONDITIONAL(BUILD_POLKITD, [test x${enable_polkitd} = yes])
++
++
+ AC_ARG_WITH(mozjs, AS_HELP_STRING([--with-mozjs=@<:@mozjs185/mozjs-17.0|auto@:>@],
+                                 [Specify version of Spidermonkey to use]),,
+             with_mozjs=auto)
+-AS_IF([test x${with_mozjs} != xauto], [
+-  PKG_CHECK_MODULES(LIBJS, ${with_mozjs})
+-], [
+-  PKG_CHECK_MODULES(LIBJS, [mozjs185], have_mozjs185=yes, have_mozjs185=no)
+-  AS_IF([test x${have_mozjs185} = xno], [
+-  PKG_CHECK_MODULES(LIBJS, [mozjs-17.0], have_mozjs17=yes,
+-   [AC_MSG_ERROR([Could not find mozjs185 or mozjs-17.0; see http://ftp.mozilla.org/pub/mozilla.org/js/])])
++
++AS_IF([test x${enable_polkitd} = yes], [
++  AS_IF([test x${with_mozjs} != xauto], [
++    PKG_CHECK_MODULES(LIBJS, ${with_mozjs})
++  ], [
++    PKG_CHECK_MODULES(LIBJS, [mozjs185], have_mozjs185=yes, have_mozjs185=no)
++    AS_IF([test x${have_mozjs185} = xno], [
++    PKG_CHECK_MODULES(LIBJS, [mozjs-17.0], have_mozjs17=yes,
++     [AC_MSG_ERROR([Could not find mozjs185 or mozjs-17.0; see 
http://ftp.mozilla.org/pub/mozilla.org/js/])])
++    ])
+   ])
++  AC_SUBST(LIBJS_CFLAGS)
++  AC_SUBST(LIBJS_LIBS)
+ ])
+-AC_SUBST(LIBJS_CFLAGS)
+-AC_SUBST(LIBJS_LIBS)
+ 
+ EXPAT_LIB=""
+ AC_ARG_WITH(expat, [  --with-expat=<dir>      Use expat from here],
+@@ -605,6 +615,7 @@ echo "
+         Session tracking:           ${SESSION_TRACKING}
+         PAM support:                ${have_pam}
+         systemdsystemunitdir:       ${systemdsystemunitdir}
++        polkitd:                    ${enable_polkitd}
+         polkitd user:               ${POLKITD_USER}"
+ 
+ if test "$have_pam" = yes ; then
+diff --git a/src/Makefile.am b/src/Makefile.am
+index 09fc7b3..c6fe91b 100644
+--- a/src/Makefile.am
++++ b/src/Makefile.am
+@@ -1,5 +1,9 @@
+ 
+-SUBDIRS = polkit polkitbackend polkitagent programs
++SUBDIRS = polkit polkitagent programs
++
++if BUILD_POLKITD
++SUBDIRS += polkitbackend
++endif
+ 
+ if BUILD_EXAMPLES
+ SUBDIRS += examples
+diff --git a/test/Makefile.am b/test/Makefile.am
+index 59d0680..d43b0fe 100644
+--- a/test/Makefile.am
++++ b/test/Makefile.am
+@@ -1,7 +1,11 @@
+ 
+-SUBDIRS = mocklibc . polkit polkitbackend
++SUBDIRS = mocklibc . polkit
+ AM_CFLAGS = $(GLIB_CFLAGS)
+ 
++if BUILD_POLKITD
++SUBDIRS += polkitbackend
++endif
++
+ noinst_LTLIBRARIES = libpolkit-test-helper.la
+ libpolkit_test_helper_la_SOURCES = polkittesthelper.c polkittesthelper.h
+ libpolkit_test_helper_la_LIBADD = $(GLIB_LIBS)
+-- 
+2.9.3
+


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]