[gimp/mypaint-brush: 8/10] app: clean compilation with external libmypaint.



commit 9eeb80aee7f0561559dce8c8a726a9eb76984bf4
Author: Jehan <jehan girinstud io>
Date:   Sat Jul 12 16:47:29 2014 +0000

    app: clean compilation with external libmypaint.
    
    The work-in-progress was using a source tree of libmypaint embedded
    into GIMP tree. This is a cleaning with pkg-config test in configure,
    and correct includes.

 app/Makefile.am         |    2 +-
 app/paint/Makefile.am   |   41 ++---------------------------------------
 app/paint/gimpmybrush.c |    6 +++---
 configure.ac            |   15 +++++----------
 4 files changed, 11 insertions(+), 53 deletions(-)
---
diff --git a/app/Makefile.am b/app/Makefile.am
index c029536..0db7b69 100644
--- a/app/Makefile.am
+++ b/app/Makefile.am
@@ -165,7 +165,6 @@ gimpconsoleldadd = \
        file/libappfile.a               \
        text/libapptext.a               \
        paint/libapppaint.a             \
-       paint/libmypaint.a              \
        operations/libappoperations.a   \
        gegl/libappgegl.a               \
        config/libappconfig.a           \
@@ -189,6 +188,7 @@ gimpconsoleldadd = \
        $(LCMS_LIBS)                    \
        $(Z_LIBS)                       \
        $(JSON_C_LIBS)                  \
+       $(LIBMYPAINTGEGL_LIBS)          \
        $(INTLLIBS)                     \
        $(RT_LIBS)                      \
        $(libm)
diff --git a/app/paint/Makefile.am b/app/paint/Makefile.am
index c678cc5..22e4b25 100644
--- a/app/paint/Makefile.am
+++ b/app/paint/Makefile.am
@@ -6,50 +6,13 @@ AM_CPPFLAGS = \
        -I$(top_srcdir)                         \
        -I$(top_builddir)/app                   \
        -I$(top_srcdir)/app                     \
-       -I$(top_srcdir)/app/paint/libmypaint    \
-       -std=c99                                \
-       -DHAVE_JSON_C=1                         \
-       $(JSON_C_CFLAGS)                        \
        $(CAIRO_CFLAGS)                         \
        $(GEGL_CFLAGS)                          \
        $(GDK_PIXBUF_CFLAGS)                    \
+       $(LIBMYPAINTGEGL_CFLAGS)                \
        -I$(includedir)
 
-noinst_LIBRARIES = libmypaint.a libapppaint.a
-
-libmypaint_a_SOURCES = \
-       libmypaint/mapping.c                            \
-       libmypaint/mapping.h                            \
-       libmypaint/helpers.c                            \
-       libmypaint/helpers.h                            \
-       libmypaint/brushmodes.c                         \
-       libmypaint/brushmodes.h                         \
-       libmypaint/fifo.c                               \
-       libmypaint/fifo.h                               \
-       libmypaint/operationqueue.c                     \
-       libmypaint/operationqueue.h                     \
-       libmypaint/rng-double.c                         \
-       libmypaint/rng-double.h                         \
-       libmypaint/utils.c                              \
-       libmypaint/utils.h                              \
-       libmypaint/tilemap.c                            \
-       libmypaint/tilemap.h                            \
-       libmypaint/mypaint.c                            \
-       libmypaint/mypaint.h                            \
-       libmypaint/mypaint-brush.c                      \
-       libmypaint/mypaint-brush.h                      \
-       libmypaint/mypaint-brush-settings.c             \
-       libmypaint/mypaint-brush-settings.h             \
-       libmypaint/mypaint-fixed-tiled-surface.c        \
-       libmypaint/mypaint-fixed-tiled-surface.h        \
-       libmypaint/mypaint-surface.c                    \
-       libmypaint/mypaint-surface.h                    \
-       libmypaint/mypaint-tiled-surface.c              \
-       libmypaint/mypaint-tiled-surface.h              \
-       libmypaint/mypaint-rectangle.c                  \
-       libmypaint/mypaint-rectangle.h                  \
-       libmypaint/gegl/mypaint-gegl-surface.c          \
-       libmypaint/gegl/mypaint-gegl-surface.h
+noinst_LIBRARIES = libapppaint.a
 
 libapppaint_a_sources = \
        paint-enums.h                   \
diff --git a/app/paint/gimpmybrush.c b/app/paint/gimpmybrush.c
index e4499b5..d7c9d4b 100644
--- a/app/paint/gimpmybrush.c
+++ b/app/paint/gimpmybrush.c
@@ -23,9 +23,9 @@
 #include <gdk-pixbuf/gdk-pixbuf.h>
 #include <gegl.h>
 
-#include "libmypaint/mypaint-brush.h"
-#include "libmypaint/mypaint-tiled-surface.h"
-#include "libmypaint/gegl/mypaint-gegl-surface.h"
+#include <mypaint-brush.h>
+#include <mypaint-tiled-surface.h>
+#include <mypaint-gegl-surface.h>
 
 #include "libgimpmath/gimpmath.h"
 #include "libgimpcolor/gimpcolor.h"
diff --git a/configure.ac b/configure.ac
index 9d7b32f..36c9c0e 100644
--- a/configure.ac
+++ b/configure.ac
@@ -66,6 +66,7 @@ m4_define([poppler_required_version], [0.12.4])
 m4_define([poppler_data_required_version], [0.4.7])
 m4_define([libgudev_required_version], [167])
 m4_define([gexiv2_required_version], [0.6.1])
+m4_define([libmypaint_required_version], [1.1])
 m4_define([lcms_required_version], [2.6])
 m4_define([libpng_required_version], [1.2.37])
 m4_define([liblzma_required_version], [5.0.0])
@@ -396,9 +397,8 @@ CFLAGS="$CFLAGS $extra_warnings"
 # can cause random behavior. If compile breaks due to the following,
 # come to us and we will point you to a newer version which works.
 #
-# Temporarily disabled -- mypaint brush
-# GIMP_DETECT_CFLAGS(extra_warnings, '-Werror=missing-prototypes')
-# CFLAGS="$CFLAGS $extra_warnings"
+GIMP_DETECT_CFLAGS(extra_warnings, '-Werror=missing-prototypes')
+CFLAGS="$CFLAGS $extra_warnings"
 
 GIMP_DETECT_CFLAGS(extra_warnings, '-Wstrict-prototypes')
 CFLAGS="$CFLAGS $extra_warnings"
@@ -725,6 +725,8 @@ PKG_CHECK_MODULES(HARFBUZZ, harfbuzz >= harfbuzz_required_version)
 
 PKG_CHECK_MODULES(GEXIV2, gexiv2 >= gexiv2_required_version)
 
+PKG_CHECK_MODULES(LIBMYPAINTGEGL, libmypaint-gegl >= libmypaint_required_version)
+
 ##########################################
 # Check for some special functions we need
 ##########################################
@@ -1630,13 +1632,6 @@ AC_SUBST(JP2_LIBS)
 PKG_CHECK_MODULES(LCMS, lcms2 >= lcms_required_version)
 
 
-##################
-# Check for json-c -- temporary for mypaint brush
-##################
-
-PKG_CHECK_MODULES(JSON_C, json-c)
-
-
 ######################
 # Check for libXcursor
 ######################


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