SELinux can be assumed for Android 4.4+
Change-Id: I7410a0c8e439eec90a955ee9201efd9a92bb9635
diff --git a/partition.cpp b/partition.cpp
index 359d70c..bbee37d 100644
--- a/partition.cpp
+++ b/partition.cpp
@@ -65,10 +65,8 @@
#define CRYPT_FOOTER_OFFSET 0x4000
#endif
}
-#ifdef HAVE_SELINUX
-#include "selinux/selinux.h"
+#include <selinux/selinux.h>
#include <selinux/label.h>
-#endif
#ifdef HAVE_CAPABILITIES
#include <sys/capability.h>
#include <sys/xattr.h>
@@ -1910,7 +1908,7 @@
if (!UnMount(true))
return false;
-#if defined(HAVE_SELINUX) && defined(USE_EXT4)
+#if defined(USE_EXT4)
int ret;
char *secontext = NULL;
@@ -2619,14 +2617,14 @@
#ifdef TW_INTERNAL_STORAGE_PATH
mkdir(EXPAND(TW_INTERNAL_STORAGE_PATH), 0770);
#endif
-#ifdef HAVE_SELINUX
+
// Afterwards, we will try to set the
// default metadata that we were hopefully able to get during
// early boot.
tw_set_default_metadata(Media_Path.c_str());
if (!Internal_path.empty())
tw_set_default_metadata(Internal_path.c_str());
-#endif
+
// Toggle mount to ensure that "internal sdcard" gets mounted
PartitionManager.UnMount_By_Path(Symlink_Mount_Point, true);
PartitionManager.Mount_By_Path(Symlink_Mount_Point, true);