If _info handles the arg "ported" it should print out 1 or 0; 0 means
it can't be compiled/run/tested on this platform. This lets ccanlint
easily skip such modules.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
if (strcmp(argv[1], "depends") == 0)
return 0;
+ if (strcmp(argv[1], "ported") == 0) {
+#if __x86_64__
+ printf("1\n");
+#else
+ printf("0\n");
+#endif
+ }
+
return 1;
}
.name = "Module's CCAN dependencies can be found or built",
.check = check_depends_built,
.can_run = can_build,
- .needs = "depends_exist test_depends_exist"
+ .needs = "depends_exist test_depends_exist info_ported"
};
REGISTER_TEST(depends_build);
.name = "Modules main header compiles",
.check = check_includes_build,
.can_run = can_build,
- .needs = "depends_exist main_header_exists"
+ .needs = "depends_exist main_header_exists info_ported"
};
REGISTER_TEST(main_header_compiles);
.compulsory = true,
.check = check_objs_build,
.can_run = can_build,
- .needs = "depends_exist"
+ .needs = "depends_exist info_ported"
};
REGISTER_TEST(objects_build);