summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIñigo Martínez <inigomartinez@gmail.com>2018-02-22 13:15:24 +0100
committerFelix Riemann <friemann@gnome.org>2018-03-05 21:25:50 +0100
commit9ce1df2230b638473adfdc28f8a1ae0f2222cc1a (patch)
treebb6345363e6b04528960486e88933078bde23e42
parentd1984b0ee8a98dccfab0cd8c70f40e5ed64b7c74 (diff)
downloadeog-9ce1df2230b638473adfdc28f8a1ae0f2222cc1a.tar.gz
build: Fix compiler flags
The compiler flags used for the shared library and the executable are different. They have been modified so now only those that are necessary are added to each targets. https://bugzilla.gnome.org/show_bug.cgi?id=793719
-rw-r--r--src/meson.build18
1 files changed, 9 insertions, 9 deletions
diff --git a/src/meson.build b/src/meson.build
index d18a8ab1..179b5062 100644
--- a/src/meson.build
+++ b/src/meson.build
@@ -1,10 +1,5 @@
src_inc = include_directories('.')
-cflags = [
- '-DEOG_DATA_DIR="@0@"'.format(eog_datadir),
- '-DEOG_LOCALE_DIR="@0@"'.format(eog_localedir)
-]
-
enum_headers = files(
'eog-scroll-view.h',
'eog-window.h'
@@ -137,10 +132,10 @@ deps = common_deps + [
cc.find_library('m')
]
-libeog_cflags = cflags + [
- '-DEOG_PLUGIN_DIR="@0@"'.format(eog_pluginsdir),
- '-DEOG_PREFIX="@0@"'.format(eog_prefix),
+cflags = [
'-DG_LOG_DOMAIN="@0@"'.format(meson.project_name().to_upper()),
+ '-DEOG_DATA_DIR="@0@"'.format(eog_datadir),
+ '-DEOG_PLUGIN_DIR="@0@"'.format(eog_pluginsdir),
'-DLIBDIR="@0@"'.format(eog_libdir)
]
@@ -168,7 +163,7 @@ libeog = shared_library(
sources: sources,
include_directories: top_inc,
dependencies: deps,
- c_args: libeog_cflags,
+ c_args: cflags,
link_args: ldflags,
link_depends: symbol_map,
install: true,
@@ -197,6 +192,11 @@ pkg.generate(
deps = [libeog_dep]
+cflags = [
+ '-DG_LOG_DOMAIN="@0@"'.format(meson.project_name().to_upper()),
+ '-DEOG_LOCALE_DIR="@0@"'.format(eog_localedir)
+]
+
if enable_introspection
deps += gir_dep
endif