Add build flags for YouCompleteMe.
authorRalph Giles <giles@thaumas.net>
Mon, 25 Sep 2017 22:58:41 +0000 (15:58 -0700)
committerRalph Giles <giles@thaumas.net>
Mon, 25 Sep 2017 22:58:41 +0000 (15:58 -0700)
Add a .ycm_extra.conf.py script to return the same CFLAGS
we pass for `make debug`. These are passed to libclang
so symbol lookup works correctly.

Note this doesn't pick up changes to the build config,
including non-default locations for the ogg headers,
but it's better than nothing.

.ycm_extra_conf.py [new file with mode: 0644]

diff --git a/.ycm_extra_conf.py b/.ycm_extra_conf.py
new file mode 100644 (file)
index 0000000..f4e30e8
--- /dev/null
@@ -0,0 +1,8 @@
+def FlagsForFile(filename, **kwargs):
+  return {
+    'flags': [
+      '-x', 'c',
+      '-g', '-Wall', '-Wextra',
+      '-D_REENTRANT', '-D__NO_MATH_INLINES', '-fsigned-char'
+    ],
+  }