[gnome-builder] configuration: add helper to apply PATH to launcher



commit 5d22feeaf84d714cd4b4cf4202bb6e66ae2171a4
Author: Christian Hergert <chergert redhat com>
Date:   Tue Jan 16 00:45:56 2018 -0800

    configuration: add helper to apply PATH to launcher

 src/libide/buildsystem/ide-configuration.c | 14 ++++++++++++++
 src/libide/buildsystem/ide-configuration.h |  3 +++
 2 files changed, 17 insertions(+)
---
diff --git a/src/libide/buildsystem/ide-configuration.c b/src/libide/buildsystem/ide-configuration.c
index cc0788e69..3cba6ea41 100644
--- a/src/libide/buildsystem/ide-configuration.c
+++ b/src/libide/buildsystem/ide-configuration.c
@@ -31,6 +31,7 @@
 #include "devices/ide-device.h"
 #include "runtimes/ide-runtime-manager.h"
 #include "runtimes/ide-runtime.h"
+#include "subprocess/ide-subprocess-launcher.h"
 
 typedef struct
 {
@@ -1736,6 +1737,19 @@ ide_configuration_set_append_path (IdeConfiguration *self,
     }
 }
 
+void
+ide_configuration_apply_path (IdeConfiguration      *self,
+                              IdeSubprocessLauncher *launcher)
+{
+  IdeConfigurationPrivate *priv = ide_configuration_get_instance_private (self);
+
+  g_return_if_fail (IDE_IS_CONFIGURATION (self));
+  g_return_if_fail (IDE_IS_SUBPROCESS_LAUNCHER (launcher));
+
+  if (priv->append_path != NULL)
+    ide_subprocess_launcher_append_path (launcher, priv->append_path);
+}
+
 IdeBuildLocality
 ide_configuration_get_locality (IdeConfiguration *self)
 {
diff --git a/src/libide/buildsystem/ide-configuration.h b/src/libide/buildsystem/ide-configuration.h
index b4ce5102a..70844ea3b 100644
--- a/src/libide/buildsystem/ide-configuration.h
+++ b/src/libide/buildsystem/ide-configuration.h
@@ -183,6 +183,9 @@ const gchar          *ide_configuration_get_app_id                (IdeConfigurat
 IDE_AVAILABLE_IN_ALL
 void                  ide_configuration_set_app_id                (IdeConfiguration      *self,
                                                                    const gchar           *app_id);
+IDE_AVAILABLE_IN_3_28
+void                  ide_configuration_apply_path                (IdeConfiguration      *self,
+                                                                   IdeSubprocessLauncher *launcher);
 IDE_AVAILABLE_IN_ALL
 gboolean              ide_configuration_supports_device           (IdeConfiguration      *self,
                                                                    IdeDevice             *device);


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