]> git.ozlabs.org Git - ccan/commitdiff
Compile fixes
authorRusty Russell <rusty@vivaldi>
Sun, 29 Jun 2008 05:26:06 +0000 (15:26 +1000)
committerRusty Russell <rusty@vivaldi>
Sun, 29 Jun 2008 05:26:06 +0000 (15:26 +1000)
tools/Makefile
tools/grab_file.c
tools/run_tests.c
tools/tools.h

index c92bb54b7631a054da532b8d368a72e0d3bcc662..8f57630207c68b7b4d43af72caaab4dd5071ef03 100644 (file)
@@ -1,9 +1,11 @@
-tools/run_tests: tools/run_tests.o tools/depends.o tools/split.o tools/grab_file.o ccan/tap/tap.o ccan/talloc/talloc.o 
+tools/run_tests: tools/run_tests.o tools/depends.o tools/split.o tools/grab_file.o ccan/tap/tap.o ccan/talloc/talloc.o
 
 tools/doc_extract: tools/doc_extract.c ccan/talloc/talloc.o
 
 tools/namespacize: tools/namespacize.c tools/split.o tools/grab_file.o tools/depends.o ccan/talloc/talloc.o
 
 
 tools/doc_extract: tools/doc_extract.c ccan/talloc/talloc.o
 
 tools/namespacize: tools/namespacize.c tools/split.o tools/grab_file.o tools/depends.o ccan/talloc/talloc.o
 
+tools/run_tests.o tools/namespacize.o tools/split.o tools/grab_file.o tools/depends.o: tools/tools.h
+
 tools-clean: ccanlint-clean
        rm -f run_tests doc_extract namespacize
 
 tools-clean: ccanlint-clean
        rm -f run_tests doc_extract namespacize
 
index 283a82b8c4cfff26a8038144f761195cd68b85df..8bd18f22553949a14d1fddfabd177018e412d172 100644 (file)
@@ -1,11 +1,11 @@
 #include "tools.h"
 #include "talloc/talloc.h"
 #include "tools.h"
 #include "talloc/talloc.h"
+#include "string/string.h"
 #include <sys/types.h>
 #include <sys/stat.h>
 #include <fcntl.h>
 #include <unistd.h>
 #include <errno.h>
 #include <sys/types.h>
 #include <sys/stat.h>
 #include <fcntl.h>
 #include <unistd.h>
 #include <errno.h>
-#include <string.h>
 
 static int close_no_errno(int fd)
 {
 
 static int close_no_errno(int fd)
 {
index 1a8d75ea4548ecc28836cd2b9d813108103a35d5..aa7f90a9765e4283cbd1439526e653df8090a123 100644 (file)
@@ -7,8 +7,7 @@
 #include "ccan/tap/tap.h"
 #include "ccan/talloc/talloc.h"
 #include "ccan/string/string.h"
 #include "ccan/tap/tap.h"
 #include "ccan/talloc/talloc.h"
 #include "ccan/string/string.h"
-
-#define CFLAGS "-O3 -Wall -Wundef -Wstrict-prototypes -Wold-style-definition -Wmissing-prototypes -Wmissing-declarations -Werror -Iccan -I."
+#include "tools.h"
 
 /* FIXME: Use build bug later. */
 #define ARRAY_SIZE(arr) (sizeof(arr) / sizeof((arr)[0]))
 
 /* FIXME: Use build bug later. */
 #define ARRAY_SIZE(arr) (sizeof(arr) / sizeof((arr)[0]))
index 841265f99ad914e58ffcd918ffa926dd2f00a857..4e8a48e6ab3b664ee4277fadae0725c3601fc7cb 100644 (file)
@@ -1,7 +1,7 @@
 #ifndef CCAN_TOOLS_H
 #define CCAN_TOOLS_H
 
 #ifndef CCAN_TOOLS_H
 #define CCAN_TOOLS_H
 
-#define CFLAGS "-O3 -Wall -Wundef -Wstrict-prototypes -Wold-style-definition -Wmissing-prototypes -Wmissing-declarations -Werror -I."
+#define CFLAGS "-O3 -Wall -Wundef -Wstrict-prototypes -Wold-style-definition -Wmissing-prototypes -Wmissing-declarations -Werror -Iccan/ -I."
 
 char **split(const void *ctx, const char *text, const char *delims,
             unsigned int *nump);
 
 char **split(const void *ctx, const char *text, const char *delims,
             unsigned int *nump);
@@ -11,7 +11,5 @@ char **get_deps(const void *ctx, const char *dir);
 void *grab_fd(const void *ctx, int fd);
 void *grab_file(const void *ctx, const char *filename);
 
 void *grab_fd(const void *ctx, int fd);
 void *grab_file(const void *ctx, const char *filename);
 
-#define streq(a,b) (strcmp((a),(b)) == 0)
-
 #endif /* CCAN_TOOLS_H */
 
 #endif /* CCAN_TOOLS_H */