]> saetta.ns0.it Git - libzakutils/commitdiff
Added project files for meson build system.
authorAndrea Zagli <azagli@libero.it>
Wed, 24 Aug 2016 15:23:50 +0000 (17:23 +0200)
committerAndrea Zagli <azagli@libero.it>
Wed, 24 Aug 2016 15:23:50 +0000 (17:23 +0200)
.gitignore
meson.build [new file with mode: 0644]
src/meson.build [new file with mode: 0644]
tests/meson.build [new file with mode: 0644]

index 5b43953a5983e5ff4325d4c1bb3b6ad5c8db560e..57816643cb820d665d89636a4c1d175a2aadbeb0 100644 (file)
@@ -50,4 +50,5 @@ intltool-*
 Rules-quot
 *.exe
 *.csv
-tests/format_money
\ No newline at end of file
+tests/format_money
+build/
\ No newline at end of file
diff --git a/meson.build b/meson.build
new file mode 100644 (file)
index 0000000..78f119b
--- /dev/null
@@ -0,0 +1,13 @@
+project('libzakutils', 'c',
+        version: '0.0.1')
+
+add_global_link_arguments('-lm', language: 'c')
+
+glib_dep = dependency('glib-2.0')
+gobject_dep = dependency('gobject-2.0')
+gio_dep = dependency('gio-2.0')
+
+inc = include_directories('src')
+
+subdir('src')
+subdir('tests')
\ No newline at end of file
diff --git a/src/meson.build b/src/meson.build
new file mode 100644 (file)
index 0000000..031ec9a
--- /dev/null
@@ -0,0 +1,9 @@
+install_headers(['libzakutils.h', 'datetime.h', 'generic.h'],
+                subdir: 'libzakutils')
+
+libzakutils_sources = ['datetime.c', 'generic.c']
+
+libzakutils = shared_library ('zakutils',
+                              libzakutils_sources,
+                              dependencies: [glib_dep, gobject_dep, gio_dep],
+                              install: true)
\ No newline at end of file
diff --git a/tests/meson.build b/tests/meson.build
new file mode 100644 (file)
index 0000000..542edf2
--- /dev/null
@@ -0,0 +1,4 @@
+format_money_exe = executable('format_money', 'format_money.c',
+                              include_directories: inc,
+                              dependencies: [glib_dep, gobject_dep, gio_dep],
+                              link_with: libzakutils)
\ No newline at end of file