[gimp/meson: 49/127] Temporarily disable plug-ins build. Add tools/pdbgen build (not finished). Fix archlinux build.



commit 022cdbfe907d21359d18f52b00f0c5beb9d6241a
Author: Félix Piédallu <felix piedallu me>
Date:   Thu Nov 23 15:13:54 2017 +0100

    Temporarily disable plug-ins build. Add tools/pdbgen build (not finished).
    Fix archlinux build.

 build/archlinux/PKGBUILD |    5 +-
 meson.build              |    3 +-
 tools/meson.build        |    2 -
 tools/pdbgen/meson.build |  151 ++++++++++++++++++++++++++++++++++++++++++++++
 4 files changed, 156 insertions(+), 5 deletions(-)
---
diff --git a/build/archlinux/PKGBUILD b/build/archlinux/PKGBUILD
index a73b79a..19fbe9c 100644
--- a/build/archlinux/PKGBUILD
+++ b/build/archlinux/PKGBUILD
@@ -21,6 +21,7 @@ depends=(
   'libart-lgpl>=2.3.19'
   'libexif>=0.6.15'
   'libgexiv2'
+  'libmng'
   'libmypaint>=1.3.0'
   'librsvg>=2.16.1'
   'libwmf>=0.2.8'
@@ -49,11 +50,11 @@ provides=('gimp')
 conflicts=('gimp')
 source=(
   # 'git://git.gnome.org/gimp'
-  # 'linux.gpl'
+  'linux.gpl'
 )
 md5sums=(
   # 'SKIP'
-  # 'bb27bc214261d36484093e857f015f38'
+  'bb27bc214261d36484093e857f015f38'
 )
 
 _gitname='gimp'
diff --git a/meson.build b/meson.build
index 5c8ca56..c34fd31 100644
--- a/meson.build
+++ b/meson.build
@@ -832,9 +832,10 @@ subdir('libgimp')
 
 # Executables, plugins
 subdir('modules')
-subdir('plug-ins')
+# subdir('plug-ins')
 subdir('app')
 
+subdir('tools/pdbgen')
 
 # subdir('build')
 # build/windows/gimp-plug-ins.rc
diff --git a/tools/meson.build b/tools/meson.build
index 4440ebe..7c8fc76 100644
--- a/tools/meson.build
+++ b/tools/meson.build
@@ -1,6 +1,4 @@
 
-
-
 if os_win32
   gimp_debug_resume = executable('gimp-debug-resume', 'gimp-debug-resume.c')
 endif
diff --git a/tools/pdbgen/meson.build b/tools/pdbgen/meson.build
new file mode 100644
index 0000000..5ab9d3b
--- /dev/null
+++ b/tools/pdbgen/meson.build
@@ -0,0 +1,151 @@
+pdbgen_backup = false
+pdbgen_groups = false
+
+pdb_names = [
+  'brush_select',
+  'brush',
+  'brushes',
+  'buffer',
+  'channel',
+  'color',
+  'context',
+  'debug',
+  'display',
+  'drawable_color',
+  'drawable_transform',
+  'drawable',
+  'dynamics',
+  'edit',
+  'fileops',
+  'floating_sel',
+  'font_select',
+  'fonts',
+  'gimp',
+  'gimprc',
+  'gradient_select',
+  'gradient',
+  'gradients',
+  'help',
+  'image_color_profile',
+  'image_convert',
+  'image_grid',
+  'image_guides',
+  'image_sample_points',
+  'image_select',
+  'image_transform',
+  'image_undo',
+  'image',
+  'item_transform',
+  'item',
+  'layer',
+  'message',
+  'paint_tools',
+  'palette_select',
+  'palette',
+  'palettes',
+  'paths',
+  'pattern_select',
+  'pattern',
+  'patterns',
+  'plug_in_compat',
+  'plug_in',
+  'procedural_db',
+  'progress',
+  'selection_tools',
+  'selection',
+  'text_layer',
+  'text_tool',
+  'transform_tools',
+  'unit',
+  'vectors',
+]
+
+pdb_sources = []
+pdb_outputs = []
+foreach name : pdb_names
+  pdb_sources += join_paths('pdb', name + '.pdb')
+  pdb_sources += join_paths('pdb', name + '.pdb')
+endforeach
+
+
+enum_headers = [
+  gimpbaseenums,
+  appconfigenums,
+  appoperationsenums,
+  appcoreenums,
+  apppaintenums,
+]
+
+# Perl environment
+perlsrcdir = join_paths(meson.source_root(), meson.current_source_dir())
+perlbindir = join_paths(meson.build_root(),  meson.current_source_dir())
+
+perl_env = [
+  'PDBGEN_BACKUP=' + (pdbgen_backup ? '1' : '0'),
+  'PDBGEN_GROUPS=' + (pdbgen_groups ? '1' : '0'),
+  'rootme='   + perlbindir,
+  'srcdir='   + perlsrcdir,
+  'destdir='  + meson.build_root(),
+  'builddir=' + meson.build_root(),
+  perl,
+  '-I', perlbindir,
+  '-I', perlsrcdir,
+]
+
+groups_pl_content    = '# This file is autogenerated\n'
+groups_pl_content   += '@groups = qw(\n'
+foreach source : pdb_names
+  groups_pl_content += '    '+ source +'\n'
+endforeach
+groups_pl_content   += ');\n'
+
+
+
+# All perl files
+
+groups_pl = custom_target('groups.pl',
+  input : [ ],
+  output: [ 'groups.pl', ],
+  command: [ 'echo', groups_pl_content, ],
+  capture: true,
+)
+
+enumgen_pl = files('enumgen.pl')
+
+enums_pl = custom_target('enums.pl',
+  input : [ enumgen_pl, enum_headers, ],
+  output: [ 'enums.pl', ],
+  command: [
+    perl_env, enumgen_pl,
+    enum_headers,
+  ],
+)
+
+pdbgen_pl   = files('pdbgen.pl')
+app_pl      = files('app.pl')
+lib_pl      = files('lib.pl')
+pdb_pl      = files('pdb.pl')
+util_pl     = files('util.pl')
+stddefs_pdb = files('stddefs.pdb')
+
+pdbgen = custom_target('stamp-pdbgen',
+  input : [
+    app_pl, enums_pl, groups_pl, lib_pl, pdb_pl, pdbgen_pl, util_pl, stddefs_pdb,
+    pdb_sources,
+  ],
+  output: [ 'stamp-pdbgen', ],
+  command: [
+    perl_env, pdbgen_pl,
+    'app', 'lib',
+  ],
+)
+
+enumcode_pl = files('enumcode.pl')
+
+stamp_enumcode = custom_target('stamp-enum-code',
+  input : [ enumcode_pl, ],
+  output: [ 'stamp-enum-code', ],
+  command: [
+    perl_env, enumcode_pl,
+  ],
+)


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