[gimp/meson: 83/128] Continue plugin/pygimp.



commit 6b1ae4254a4863090b0363517528c3255a60dd34
Author: Félix Piédallu <felix piedallu me>
Date:   Tue Jan 9 18:08:54 2018 +0100

    Continue plugin/pygimp.

 plug-ins/pygimp/meson.build          |   96 +++++++++++++++++++++++-----------
 plug-ins/pygimp/plug-ins/meson.build |    1 +
 2 files changed, 66 insertions(+), 31 deletions(-)
---
diff --git a/plug-ins/pygimp/meson.build b/plug-ins/pygimp/meson.build
index 93ec07b..093c4ee 100644
--- a/plug-ins/pygimp/meson.build
+++ b/plug-ins/pygimp/meson.build
@@ -1,40 +1,74 @@
 subdir('doc')
 subdir('plug-ins')
 
-plugin_pygimp_sources = [
-  'gimpmodule.c',
-  'pygimp-display.c',
-  'pygimp-drawable.c',
-  'pygimp-image.c',
-  'pygimp-item.c',
-  'pygimp-parasite.c',
-  'pygimp-pdb.c',
-  'pygimp-tile.c',
-  'pygimp-vectors.c',
-]
-# TODO pygimp.rc.o
-pygimp = executable('pygimp',
-  plugin_pygimp_sources,
-  include_directories: [ rootInclude, ],
-  dependencies: [
-    gtk2, gegl,
-    x11, xmu, xext, xfixes,
-  ],
-  link_with: [
-    libgimp,
-    libgimpbase,
-    libgimpcolor,
-    libgimpconfig,
-    libgimpmath,
-    libgimpui,
-    libgimpwidgets,
-  ],
-  install: true,
-  install_dir: join_paths(gimpplugindir, 'plug-ins'),
-)
+
+#
+# .defs.c:
+#      (cd $(srcdir) \
+#       && $(PYGTK_CODEGEN) \
+#          --override $*.override \
+#          --register $(PYGTK_DEFSDIR)/gdk-types.defs \
+#          --register $(PYGTK_DEFSDIR)/gtk-types.defs \
+#          --register gimp-types.defs \
+#          --register gimpcolor-types.defs \
+#          --register gimpenums-types.defs \
+#          --prefix $* $*.defs) > gen-$*.c \
+#       && cp gen-$*.c $*.c \
+#       && rm -f gen-$*.c
 
 
 
+python_so_libs = [
+  [ 'gimp', [
+      'gimpmodule.c',
+      'pygimp-display.c',
+      'pygimp-drawable.c',
+      'pygimp-image.c',
+      'pygimp-item.c',
+      'pygimp-parasite.c',
+      'pygimp-pdb.c',
+      'pygimp-tile.c',
+      'pygimp-vectors.c',
+    ],
+  ],
+  [ '_gimpenums', [ 'gimpenumsmodule.c',                    ], ],
+  [ '_gimpui',    [ 'gimpuimodule.c',    'gimpui.c',        ], ],
+  [ 'gimpcolor',  [ 'gimpcolormodule.c', 'pygimp-colors.c', ], ],
+  [ 'gimpthumb',  [ 'gimpthumbmodule.c', 'gimpthumb.c',     ], ],
+]
+
+foreach pylib : python_so_libs
+  shared_library(pylib[0],
+    pylib[1],
+    include_directories: [ rootInclude, ],
+    dependencies: [
+      gtk2, gegl,
+      x11, xmu, xext, xfixes,
+    ],
+    link_with: [
+      libgimp,
+      libgimpbase,
+      libgimpcolor,
+      libgimpconfig,
+      libgimpmath,
+      libgimpui,
+      libgimpwidgets,
+    ],
+    install: true,
+    install_dir: join_paths(gimpplugindir, 'python'),
+  )
+endforeach
+
+install_data([
+  'gimpenums.py',
+  'gimpfu.py',
+  'gimpplugin.py',
+  'gimpshelf.py',
+  'gimpui.py',
+  'pygimp-logo.png',
+  ],
+  install_dir: join_paths(gimpplugindir, 'python'),
+)
 
 
 
diff --git a/plug-ins/pygimp/plug-ins/meson.build b/plug-ins/pygimp/plug-ins/meson.build
index 2500b55..e3f5332 100644
--- a/plug-ins/pygimp/plug-ins/meson.build
+++ b/plug-ins/pygimp/plug-ins/meson.build
@@ -13,6 +13,7 @@ install_data([
   install_dir: join_paths(gimpplugindir, 'plug-ins'),
 )
 install_data([
+    'pyconsole.py',
     'python-console.py',
   ],
   install_dir: join_paths(gimpplugindir, 'plug-ins', 'python-console'),


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