Avoid possibly including an old vswitch-idl.h.
authorBen Pfaff <blp@nicira.com>
Tue, 27 Mar 2012 22:57:52 +0000 (15:57 -0700)
committerBen Pfaff <blp@nicira.com>
Tue, 27 Mar 2012 22:57:52 +0000 (15:57 -0700)
Codes that uses #include "vswitch-idl.h" can get an older version of this
header, because this header file moved from vswitchd/ to lib/ and the
older generated file might still be present.

This helps out two ways:

     * "make clean" will delete the generated files from their old
       locations.

     * Use #include "lib/vswitch-idl.h" to explicitly avoid including the
       files from their old locations.

Reported-by: Justin Pettit <jpettit@nicira.com>
Signed-off-by: Ben Pfaff <blp@nicira.com>
utilities/ovs-vsctl.c
vswitchd/automake.mk
vswitchd/bridge.c
vswitchd/ovs-vswitchd.c

index 86889cc..0caf57e 100644 (file)
@@ -41,7 +41,7 @@
 #include "stream-ssl.h"
 #include "sset.h"
 #include "svec.h"
-#include "vswitch-idl.h"
+#include "lib/vswitch-idl.h"
 #include "table.h"
 #include "timeval.h"
 #include "util.h"
index 4df5f22..9092129 100644 (file)
@@ -95,3 +95,7 @@ vswitchd/vswitch.ovsschema.stamp: vswitchd/vswitch.ovsschema
          exit 1; \
        fi
 CLEANFILES += vswitchd/vswitch.ovsschema.stamp
+
+# Clean up generated files from older OVS versions.  (This is important so that
+# #include "vswitch-idl.h" doesn't get the wrong copy.)
+CLEANFILES += vswitchd/vswitch-idl.c vswitchd/vswitch-idl.h
index 1778227..e15d57b 100644 (file)
@@ -50,7 +50,7 @@
 #include "util.h"
 #include "unixctl.h"
 #include "vlandev.h"
-#include "vswitch-idl.h"
+#include "lib/vswitch-idl.h"
 #include "xenserver.h"
 #include "vlog.h"
 #include "sflow_api.h"
index ebac1aa..f7ddee1 100644 (file)
@@ -49,7 +49,7 @@
 #include "util.h"
 #include "vconn.h"
 #include "vlog.h"
-#include "vswitch-idl.h"
+#include "lib/vswitch-idl.h"
 
 VLOG_DEFINE_THIS_MODULE(vswitchd);