X-Git-Url: http://git.ozlabs.org/?a=blobdiff_plain;f=ccan%2Fmem%2F_info;fp=ccan%2Fmem%2F_info;h=19b22287fcc713694cbad4a658b367eb66f01623;hb=992931f06cf25d24fe74b4c617753aef2de70426;hp=0000000000000000000000000000000000000000;hpb=fe6805a9cfb6f880dc0b161b647a8d97123ad2a3;p=ccan diff --git a/ccan/mem/_info b/ccan/mem/_info new file mode 100644 index 00000000..19b22287 --- /dev/null +++ b/ccan/mem/_info @@ -0,0 +1,30 @@ +#include "config.h" +#include +#include + +/** + * mem - Provide mem*() functions if missing from C library + * + * This code implements some string.h mem*() functions if they're not + * already available in the C library. Functions included are: + * memmem() + * + * License: CC0 + */ +int main(int argc, char *argv[]) +{ + /* Expect exactly one argument */ + if (argc != 2) + return 1; + + if (strcmp(argv[1], "depends") == 0) { + return 0; + } + + if (strcmp(argv[1], "testdepends") == 0) { + printf("ccan/array_size"); + return 0; + } + + return 1; +}