[tor-commits] [obfsproxy/master] Fix typo in makefile; fix include search path so subdirectory sources don't need to use ../whatever.h

nickm at torproject.org nickm at torproject.org
Fri Sep 9 17:08:58 UTC 2011


commit 60fa1ee82bf5077d0a8194be694a094d7d8c3289
Author: Zack Weinberg <zackw at panix.com>
Date:   Thu Aug 4 15:27:12 2011 -0700

    Fix typo in makefile; fix include search path so subdirectory sources don't need to use ../whatever.h
    
    Conflicts:
    
    	Makefile.am
---
 Makefile.am                   |    1 +
 configure.ac                  |    2 +-
 src/protocols/dummy.c         |    2 +-
 src/protocols/dummy.h         |    4 ++--
 src/protocols/obfs2.c         |    2 +-
 src/protocols/obfs2.h         |    4 ++--
 src/test/unittest.c           |    2 +-
 src/test/unittest_container.c |    6 +++---
 src/test/unittest_crypt.c     |    4 ++--
 src/test/unittest_dummy.c     |    4 ++--
 src/test/unittest_obfs2.c     |    6 +++---
 src/test/unittest_socks.c     |    6 +++---
 12 files changed, 22 insertions(+), 21 deletions(-)

diff --git a/Makefile.am b/Makefile.am
index 617fd27..ece6069 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -1,6 +1,7 @@
 
 ACLOCAL_AMFLAGS = -I m4
 WARNINGS = -Wall -Wwrite-strings -Werror
+AM_CPPFLAGS = -I. -I$(srcdir)/src
 AM_CFLAGS = $(WARNINGS) @libevent_CFLAGS@ @libcrypto_CFLAGS@
 LDADD = libobfsproxy.a @libevent_LIBS@ @libcrypto_LIBS@ @ws32_LIBS@
 
diff --git a/configure.ac b/configure.ac
index ceeec89..3809750 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1,7 +1,7 @@
 AC_PREREQ([2.61])dnl Possibly earlier will do, but this is what I have
 AC_INIT([obfsproxy], [0.0])
 AC_CONFIG_SRCDIR([src/main.c])
-AM_INIT_AUTOMAKE([foreign])
+AM_INIT_AUTOMAKE([foreign nostdinc])
 
 dnl The stock definition of AC_INCLUDES_DEFAULT performs a whole bunch
 dnl of completely unnecessary checks *even if* you override its
diff --git a/src/protocols/dummy.c b/src/protocols/dummy.c
index e55699d..6489f58 100644
--- a/src/protocols/dummy.c
+++ b/src/protocols/dummy.c
@@ -2,7 +2,7 @@
    See LICENSE for other credits and copying information
 */
 
-#include "../util.h"
+#include "util.h"
 
 #define PROTOCOL_DUMMY_PRIVATE
 #include "dummy.h"
diff --git a/src/protocols/dummy.h b/src/protocols/dummy.h
index 6a957bb..d243f06 100644
--- a/src/protocols/dummy.h
+++ b/src/protocols/dummy.h
@@ -14,8 +14,8 @@ extern const protocol_vtable dummy_vtable;
    ==========
 */
 
-#include "../network.h"
-#include "../protocol.h"
+#include "network.h"
+#include "protocol.h"
 
 /* Dummy presently needs only the obligatory extensions to the generic
    protocol structures, but we have shims for future expansion, and
diff --git a/src/protocols/obfs2.c b/src/protocols/obfs2.c
index f313204..94fd173 100644
--- a/src/protocols/obfs2.c
+++ b/src/protocols/obfs2.c
@@ -2,7 +2,7 @@
    See LICENSE for other credits and copying information
 */
 
-#include "../util.h"
+#include "util.h"
 
 #define PROTOCOL_OBFS2_PRIVATE
 #include "obfs2.h"
diff --git a/src/protocols/obfs2.h b/src/protocols/obfs2.h
index ce28217..e994d97 100644
--- a/src/protocols/obfs2.h
+++ b/src/protocols/obfs2.h
@@ -9,8 +9,8 @@ extern const protocol_vtable obfs2_vtable;
 
 #ifdef PROTOCOL_OBFS2_PRIVATE
 
-#include "../crypt.h"
-#include "../protocol.h"
+#include "crypt.h"
+#include "protocol.h"
 
 /* ==========
    These definitions are not part of the obfs2_protocol interface.
diff --git a/src/test/unittest.c b/src/test/unittest.c
index 29c0af9..13557bf 100644
--- a/src/test/unittest.c
+++ b/src/test/unittest.c
@@ -3,7 +3,7 @@
 */
 
 #include "tinytest.h"
-#include "../crypt.h"
+#include "crypt.h"
 
 extern struct testcase_t container_tests[];
 extern struct testcase_t crypt_tests[];
diff --git a/src/test/unittest_container.c b/src/test/unittest_container.c
index 4731139..2806520 100644
--- a/src/test/unittest_container.c
+++ b/src/test/unittest_container.c
@@ -3,11 +3,11 @@
  * Copyright (c) 2007-2011, The Tor Project, Inc. */
 /* See LICENSE for licensing information */
 
-#include "../util.h"
+#include "util.h"
 #include "tinytest_macros.h"
 
-#include "../container.h"
-#include "../crypt.h"
+#include "container.h"
+#include "crypt.h"
 
 /** Helper: return a tristate based on comparing the strings in *<b>a</b> and
  * *<b>b</b>. */
diff --git a/src/test/unittest_crypt.c b/src/test/unittest_crypt.c
index 112da20..08d53a5 100644
--- a/src/test/unittest_crypt.c
+++ b/src/test/unittest_crypt.c
@@ -2,11 +2,11 @@
    See LICENSE for other credits and copying information
 */
 
-#include "../util.h"
+#include "util.h"
 #include "tinytest_macros.h"
 
 #define CRYPT_PRIVATE
-#include "../crypt.h"
+#include "crypt.h"
 
 /* Test vectors for sha256 */
 static void
diff --git a/src/test/unittest_dummy.c b/src/test/unittest_dummy.c
index 0eb133c..19a82d4 100644
--- a/src/test/unittest_dummy.c
+++ b/src/test/unittest_dummy.c
@@ -2,8 +2,8 @@
    See LICENSE for other credits and copying information
 */
 
-#include "../util.h"
-#include "../protocol.h"
+#include "util.h"
+#include "protocol.h"
 #include "tinytest_macros.h"
 
 #include <event2/buffer.h>
diff --git a/src/test/unittest_obfs2.c b/src/test/unittest_obfs2.c
index c6d793c..e5addcc 100644
--- a/src/test/unittest_obfs2.c
+++ b/src/test/unittest_obfs2.c
@@ -2,13 +2,13 @@
    See LICENSE for other credits and copying information
 */
 
-#include "../util.h"
+#include "util.h"
 #include "tinytest_macros.h"
 
 #define PROTOCOL_OBFS2_PRIVATE
 #define CRYPT_PRIVATE
-#include "../protocols/obfs2.h"
-#include "../crypt.h"
+#include "protocols/obfs2.h"
+#include "crypt.h"
 
 #include <event2/buffer.h>
 
diff --git a/src/test/unittest_socks.c b/src/test/unittest_socks.c
index d213a80..7293d68 100644
--- a/src/test/unittest_socks.c
+++ b/src/test/unittest_socks.c
@@ -2,12 +2,12 @@
    See LICENSE for other credits and copying information
 */
 
-#include "../util.h"
+#include "util.h"
 #include "tinytest_macros.h"
 
 #define SOCKS_PRIVATE
-#include "../socks.h"
-#include "../crypt.h"
+#include "socks.h"
+#include "crypt.h"
 
 #include <event2/buffer.h>
 





More information about the tor-commits mailing list