[ccan] [PATCH 7/7] cpuid: small fix

Ahmed Samy f.fallen45 at gmail.com
Thu Sep 26 02:44:52 EST 2013


Signed-off-by: Ahmed Samy <f.fallen45 at gmail.com>
---
 ccan/cpuid/_info   | 5 +++++
 ccan/cpuid/cpuid.h | 1 +
 2 files changed, 6 insertions(+)

diff --git a/ccan/cpuid/_info b/ccan/cpuid/_info
index b6e0caf..1603b4b 100644
--- a/ccan/cpuid/_info
+++ b/ccan/cpuid/_info
@@ -29,7 +29,12 @@ int main(int argc, char *argv[])
 		return 1;
 
 	if (strcmp(argv[1], "depends") == 0) {
+#if defined(__i386__) || defined(__i386) || defined(__x86_64) \
+		|| defined(_M_AMD64) || defined(__M_X64)
 		/* Nothing.  */
+#else
+		printf("ccan/build_assert\n");
+#endif
 		return 0;
 	}
 
diff --git a/ccan/cpuid/cpuid.h b/ccan/cpuid/cpuid.h
index b0d9df1..8988949 100644
--- a/ccan/cpuid/cpuid.h
+++ b/ccan/cpuid/cpuid.h
@@ -235,6 +235,7 @@ bool cpuid_test_feature(cpuid_t feature);
 bool cpuid_has_feature(int feature, bool extended);
 
 #else
+#include <ccan/build_assert/build_assert.h>
 
 #define cpuid_get_cpu_type() 			BUILD_ASSERT_OR_ZERO(0)
 #define cpuid_get_cpu_type_string() 		BUILD_ASSERT_OR_ZERO(0)
-- 
1.8.4



More information about the ccan mailing list