chiark / gitweb /
Drop my copyright headers
[elogind.git] / src / systemd / meson.build
index aa43dedac20471f5cc8fa1e518b04e96f1abd9fd..66b1737faab94fa492c7ae56a22797b613b2379f 100644 (file)
@@ -1,3 +1,5 @@
+# SPDX-License-Identifier: LGPL-2.1+
+
 #if 0 /// No systemd-journal in elogind ...
 # _systemd_headers = '''
 #         sd-bus.h
@@ -50,22 +52,36 @@ install_headers(
 #         subdir : 'systemd')
 #else
         subdir : 'elogind/systemd')
-#endif // 0
 
 meson.add_install_script(meson_symlink_headers,
                          includedir,
-                         _systemd_headers)
+                         _systemd_headers,
+                         '_sd-common.h')
+#endif // 0
 
 
 ############################################################
 
 opts = [['c'],
         ['c', '-ansi'],
-        ['c', '-std=iso9899:1990']]
+        ['c', '-std=iso9899:1990'],
+        ['c', '-std=iso9899:2011']]
+
+if cc.has_argument('-std=iso9899:2017')
+        opts += [['c', '-std=iso9899:2017']]
+endif
 
 cxx = find_program('c++', required : false)
 if cxx.found()
-        opts += [['c++']]
+        opts += [['c++'],
+                 ['c++', '-std=c++98'],
+                 ['c++', '-std=c++11']]
+        if cc.has_argument('-std=c++14')
+                opts += [['c++', '-std=c++14']]
+        endif
+        if cc.has_argument('-std=c++17')
+                opts += [['c++', '-std=c++17']]
+        endif
 endif
 
 foreach header : _systemd_headers