diff mbox series

[2/2] cil: re-enable DISABLE_SYMVER define

Message ID 20200326154641.7253-3-william.c.roberts@intel.com (mailing list archive)
State Accepted
Headers show
Series [1/2] cil: rm dead dso.h file | expand

Commit Message

William Roberts March 26, 2020, 3:46 p.m. UTC
From: William Roberts <william.c.roberts@intel.com>

Fix issues like:
<inline asm>:1:1: error: unknown directive
.symver cil_build_policydb_pdb,        cil_build_policydb@LIBSEPOL_1.0

Which was caused by the DISABLE_SYMVER define not being defined
for static, Mac or Android builds.

Signed-off-by: William Roberts <william.c.roberts@intel.com>
---
 libsepol/cil/src/cil.c | 4 ++++
 1 file changed, 4 insertions(+)
diff mbox series

Patch

diff --git a/libsepol/cil/src/cil.c b/libsepol/cil/src/cil.c
index 12cc28eff389..c8e27c04c954 100644
--- a/libsepol/cil/src/cil.c
+++ b/libsepol/cil/src/cil.c
@@ -51,6 +51,10 @@ 
 #include "cil_policy.h"
 #include "cil_strpool.h"
 
+#if !defined(SHARED) || defined(ANDROID) || defined(__APPLE__)
+    #define DISABLE_SYMVER 1
+#endif
+
 #ifndef DISABLE_SYMVER
 asm(".symver cil_build_policydb_pdb,        cil_build_policydb@LIBSEPOL_1.0");
 asm(".symver cil_build_policydb_create_pdb, cil_build_policydb@@LIBSEPOL_1.1");