summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDan Goodliffe <dan@randomdan.homeip.net>2021-10-08 17:59:50 +0100
committerDan Goodliffe <dan@randomdan.homeip.net>2021-10-08 20:33:10 +0100
commitc7fd077dae2807060957ccc69463d15a05c17907 (patch)
tree09f42ff7d5db4dc31a5a6ecc8096e9ff3d14f339
parentAdd stub header for all header only files, fix up most IWYU errors (diff)
downloadslicer-c7fd077dae2807060957ccc69463d15a05c17907.tar.bz2
slicer-c7fd077dae2807060957ccc69463d15a05c17907.tar.xz
slicer-c7fd077dae2807060957ccc69463d15a05c17907.zip
Fix the messy include problemslicer-1.10.6.1
Avoids the inconsitent include rules across the build using an install rule. Fixes the includes in this project to use the same definition as outside.
-rw-r--r--slicer/db/Jamfile.jam5
-rw-r--r--slicer/db/sqlCommon.cpp2
-rw-r--r--slicer/db/sqlExceptions.ice2
-rw-r--r--slicer/db/sqlInsertSerializer.h2
-rw-r--r--slicer/db/sqlSelectDeserializer.h4
-rw-r--r--slicer/db/sqlTablePatchSerializer.h2
-rw-r--r--slicer/db/sqlUpdateSerializer.h2
-rw-r--r--slicer/db/testInsert.cpp2
-rw-r--r--slicer/ice/Jamfile.jam2
-rw-r--r--slicer/ice/serializer.h2
-rw-r--r--slicer/ice/testSpecifics.cpp2
-rw-r--r--slicer/json/Jamfile.jam2
-rw-r--r--slicer/json/serializer.h4
-rw-r--r--slicer/slicer/Jamfile.jam11
-rw-r--r--slicer/test/conversions.cpp4
-rw-r--r--slicer/test/serializers.cpp6
-rw-r--r--slicer/test/slicer.jam4
-rw-r--r--slicer/test/streams.cpp8
-rw-r--r--slicer/tool/icemetadata.cpp2
-rw-r--r--slicer/tool/icemetadata.h2
-rw-r--r--slicer/xml/Jamfile.jam1
-rw-r--r--slicer/xml/serializer.h2
-rw-r--r--slicer/xml/xmlExceptions.ice2
23 files changed, 36 insertions, 39 deletions
diff --git a/slicer/db/Jamfile.jam b/slicer/db/Jamfile.jam
index bc43dcb..2e5c69f 100644
--- a/slicer/db/Jamfile.jam
+++ b/slicer/db/Jamfile.jam
@@ -10,7 +10,6 @@ lib slicer-db :
[ glob *.cpp : test*.cpp ]
sqlExceptions
:
- <include>..
<library>..//Ice
<library>dbppcore
<library>../..//glibmm
@@ -141,6 +140,6 @@ alias install : install-lib install-slice ;
explicit install ;
explicit install-lib ;
explicit install-slice ;
-package.install install-lib : <install-header-subdir>slicer/db : : slicer-db : [ glob-tree *.h ] ;
-package.install-data install-slice : slicer/ice : [ glob *.ice ] ;
+package.install install-lib : <install-header-subdir>slicer/db : : slicer-db : [ glob-tree *.h : test*.h ] ;
+package.install-data install-slice : slicer/ice : [ glob *.ice : test*.ice ] ;
diff --git a/slicer/db/sqlCommon.cpp b/slicer/db/sqlCommon.cpp
index f60d33f..40e43f7 100644
--- a/slicer/db/sqlCommon.cpp
+++ b/slicer/db/sqlCommon.cpp
@@ -1,6 +1,6 @@
#include "sqlCommon.h"
#include <compileTimeFormatter.h>
-#include <modelParts.h>
+#include <slicer/modelParts.h>
#include <sqlExceptions.h>
#include <string_view>
diff --git a/slicer/db/sqlExceptions.ice b/slicer/db/sqlExceptions.ice
index 3aca6a2..d56c956 100644
--- a/slicer/db/sqlExceptions.ice
+++ b/slicer/db/sqlExceptions.ice
@@ -1,7 +1,7 @@
#ifndef SLICER_XML
#define SLICER_XML
-#include <common.ice>
+#include <slicer/common.ice>
module Slicer {
["cpp:ice_print"]
diff --git a/slicer/db/sqlInsertSerializer.h b/slicer/db/sqlInsertSerializer.h
index 6bcfae3..26989fc 100644
--- a/slicer/db/sqlInsertSerializer.h
+++ b/slicer/db/sqlInsertSerializer.h
@@ -1,9 +1,9 @@
#ifndef SLICER_DB_SQLINSERTSERIALIZER_H
#define SLICER_DB_SQLINSERTSERIALIZER_H
-#include "modelParts.h"
#include <command_fwd.h>
#include <ostream>
+#include <slicer/modelParts.h>
#include <slicer/serializer.h>
#include <string>
#include <visibility.h>
diff --git a/slicer/db/sqlSelectDeserializer.h b/slicer/db/sqlSelectDeserializer.h
index b681817..bf2b351 100644
--- a/slicer/db/sqlSelectDeserializer.h
+++ b/slicer/db/sqlSelectDeserializer.h
@@ -1,9 +1,9 @@
#ifndef SLICER_DB_SQLSELECTDESERIALIZER_H
#define SLICER_DB_SQLSELECTDESERIALIZER_H
-#include "modelParts.h"
-#include "slicer/serializer.h"
#include <optional>
+#include <slicer/modelParts.h>
+#include <slicer/serializer.h>
#include <string>
#include <visibility.h>
namespace DB {
diff --git a/slicer/db/sqlTablePatchSerializer.h b/slicer/db/sqlTablePatchSerializer.h
index 8973072..21c8b3d 100644
--- a/slicer/db/sqlTablePatchSerializer.h
+++ b/slicer/db/sqlTablePatchSerializer.h
@@ -1,7 +1,7 @@
#ifndef SLICER_DB_SQLTABLEPATCHSERIALIZER_H
#define SLICER_DB_SQLTABLEPATCHSERIALIZER_H
-#include "modelParts.h"
+#include <slicer/modelParts.h>
#include <slicer/serializer.h>
#include <visibility.h>
namespace DB {
diff --git a/slicer/db/sqlUpdateSerializer.h b/slicer/db/sqlUpdateSerializer.h
index 4204b86..8707988 100644
--- a/slicer/db/sqlUpdateSerializer.h
+++ b/slicer/db/sqlUpdateSerializer.h
@@ -1,8 +1,8 @@
#ifndef SLICER_DB_SQLUPDATESERIALIZER_H
#define SLICER_DB_SQLUPDATESERIALIZER_H
-#include "modelParts.h"
#include <command_fwd.h>
+#include <slicer/modelParts.h>
#include <slicer/serializer.h>
#include <string>
#include <visibility.h>
diff --git a/slicer/db/testInsert.cpp b/slicer/db/testInsert.cpp
index 37196b1..a9e42f1 100644
--- a/slicer/db/testInsert.cpp
+++ b/slicer/db/testInsert.cpp
@@ -4,7 +4,6 @@
#include "classes.h"
#include "collections.h"
#include "common.h"
-#include "slicer/slicer.h"
#include "sqlInsertSerializer.h"
#include "sqlSelectDeserializer.h"
#include "structs.h"
@@ -14,6 +13,7 @@
#include <connection.h>
#include <iosfwd>
#include <memory>
+#include <slicer/slicer.h>
#include <string>
#include <string_view>
#include <vector>
diff --git a/slicer/ice/Jamfile.jam b/slicer/ice/Jamfile.jam
index ef5c0e8..79cfaba 100644
--- a/slicer/ice/Jamfile.jam
+++ b/slicer/ice/Jamfile.jam
@@ -5,7 +5,6 @@ lib stdc++fs ;
lib slicer-ice :
[ glob *.cpp : test*.cpp ]
:
- <include>..
<library>stdc++fs
<library>..//Ice
<library>..//adhocutil
@@ -23,7 +22,6 @@ run testSpecifics.cpp
<implicit-dependency>../test//types
<library>../test//common
<library>../slicer//slicer
- <include>..
:
testSpecifics
;
diff --git a/slicer/ice/serializer.h b/slicer/ice/serializer.h
index f507c58..c45ece8 100644
--- a/slicer/ice/serializer.h
+++ b/slicer/ice/serializer.h
@@ -1,10 +1,10 @@
#ifndef SLICER_ICE_H
#define SLICER_ICE_H
-#include "modelParts.h"
#include <Ice/BuiltinSequences.h>
#include <Ice/CommunicatorF.h>
#include <iosfwd>
+#include <slicer/modelParts.h>
#include <slicer/serializer.h>
#include <visibility.h>
diff --git a/slicer/ice/testSpecifics.cpp b/slicer/ice/testSpecifics.cpp
index 715ccbd..2080993 100644
--- a/slicer/ice/testSpecifics.cpp
+++ b/slicer/ice/testSpecifics.cpp
@@ -10,7 +10,7 @@
#include <functional>
#include <iosfwd>
#include <memory>
-#include <slicer.h>
+#include <slicer/slicer.h>
#include <string>
#include <typeinfo>
// IWYU pragma: no_forward_declare Slicer::IceStreamDeserializer
diff --git a/slicer/json/Jamfile.jam b/slicer/json/Jamfile.jam
index be5f951..8c533bb 100644
--- a/slicer/json/Jamfile.jam
+++ b/slicer/json/Jamfile.jam
@@ -9,7 +9,6 @@ lib stdc++fs ;
lib slicer-json :
[ glob *.cpp : test*.cpp ]
:
- <include>..
<library>stdc++fs
<library>jsonpp
<library>../..//glibmm
@@ -29,7 +28,6 @@ run testSpecifics.cpp
<implicit-dependency>../test//types
<library>../test//common
<library>../slicer//slicer
- <include>..
:
testSpecifics
;
diff --git a/slicer/json/serializer.h b/slicer/json/serializer.h
index ef79b47..32500e8 100644
--- a/slicer/json/serializer.h
+++ b/slicer/json/serializer.h
@@ -1,11 +1,11 @@
#ifndef SLICER_JSON_H
#define SLICER_JSON_H
-#include "modelParts.h"
-#include "slicer/serializer.h"
#include <filesystem>
#include <iosfwd>
#include <jsonpp.h>
+#include <slicer/modelParts.h>
+#include <slicer/serializer.h>
#include <string>
#include <visibility.h>
diff --git a/slicer/slicer/Jamfile.jam b/slicer/slicer/Jamfile.jam
index 8fde048..083ebff 100644
--- a/slicer/slicer/Jamfile.jam
+++ b/slicer/slicer/Jamfile.jam
@@ -6,11 +6,11 @@ compile enum-test.cpp ;
compile hook-test.cpp : <use>..//adhocutil <implicit-dependency>common ;
compile metadata-test.cpp : <use>..//adhocutil <implicit-dependency>common ;
-obj common : common.ice : <toolset>tidy:<checker>none ;
+h common : common.ice ;
lib slicer :
[ glob *.cpp : *-test.cpp ]
- common
+ [ obj c : common : <implicit-dependency>common ]
:
<library>..//Ice
<library>..//adhocutil
@@ -18,15 +18,18 @@ lib slicer :
<implicit-dependency>common
: :
<include>..
- <include>.
<implicit-dependency>common
<library>stdc++fs
+ <include>bin/include
+ <dependency>../slicer//install-headers-local
;
alias install : install-lib install-slice ;
explicit install ;
explicit install-lib ;
explicit install-slice ;
-package.install install-lib : <install-header-subdir>slicer/slicer : : slicer : [ glob-tree *.h ] ;
+package.install install-lib : <install-header-subdir>slicer/slicer : : slicer : [ glob-tree-ex . : *.h : include ] ;
package.install-data install-slice : slicer/ice : [ glob *.ice ] ;
+explicit install-headers-local ;
+install install-headers-local : common : <location>bin/include/slicer ;
diff --git a/slicer/test/conversions.cpp b/slicer/test/conversions.cpp
index 400daa0..f34c467 100644
--- a/slicer/test/conversions.cpp
+++ b/slicer/test/conversions.cpp
@@ -1,6 +1,4 @@
#include "conversions.h"
-#include "modelParts.h"
-#include "modelPartsTypes.h"
#include <boost/date_time/date.hpp>
#include <boost/date_time/gregorian_calendar.hpp>
#include <boost/date_time/time.hpp>
@@ -9,6 +7,8 @@
#include <cstdio>
#include <ctime>
#include <memory>
+#include <slicer/modelParts.h>
+#include <slicer/modelPartsTypes.h>
#include <stdexcept>
#include <visibility.h>
diff --git a/slicer/test/serializers.cpp b/slicer/test/serializers.cpp
index 68998e4..9389090 100644
--- a/slicer/test/serializers.cpp
+++ b/slicer/test/serializers.cpp
@@ -10,7 +10,6 @@
#include "functions.h"
#include "helpers.h"
#include "inheritance.h"
-#include "modelPartsTypes.h"
#include "optionals.h"
#include "structs.h"
#include "xml/serializer.h"
@@ -30,8 +29,9 @@
#include <locals.h>
#include <map>
#include <memory>
-#include <modelParts.h>
-#include <slicer.h>
+#include <slicer/modelParts.h>
+#include <slicer/modelPartsTypes.h>
+#include <slicer/slicer.h>
#include <sstream>
#include <string>
#include <types.h>
diff --git a/slicer/test/slicer.jam b/slicer/test/slicer.jam
index f413628..e86049a 100644
--- a/slicer/test/slicer.jam
+++ b/slicer/test/slicer.jam
@@ -14,11 +14,11 @@ toolset.flags slicer INCLUDES <include> ;
actions slicer bind SLICERBIN
{
slice2cpp -I"$(INCLUDES)" --checksum --output-dir $(1[1]:D) $(2) --dll-export JAM_DLL_PUBLIC
- "$(SLICERBIN)" -I"$(INCLUDES)" $(2) $(1[2]) --headerPrefix="\"\""
+ "$(SLICERBIN)" -I"$(INCLUDES)" $(2) $(1[2])
}
actions slicer.pure bind SLICERBIN
{
- "$(SLICERBIN)" -I"$(INCLUDES)" $(2) $(1[1]) --headerPrefix="\"\""
+ "$(SLICERBIN)" -I"$(INCLUDES)" $(2) $(1[1])
}
diff --git a/slicer/test/streams.cpp b/slicer/test/streams.cpp
index d2667b0..ccc0190 100644
--- a/slicer/test/streams.cpp
+++ b/slicer/test/streams.cpp
@@ -2,16 +2,16 @@
#include <boost/test/unit_test.hpp>
#include "helpers.h"
-#include "modelPartsTypes.h"
#include "streams.h"
-#include "xml/serializer.h"
-#include "json/serializer.h"
#include <collections.h>
#include <definedDirs.h>
#include <filesystem>
-#include <slicer.h>
+#include <json/serializer.h>
+#include <slicer/modelPartsTypes.h>
+#include <slicer/slicer.h>
#include <string>
#include <vector>
+#include <xml/serializer.h>
void
TestStream::Produce(const Consumer & c)
diff --git a/slicer/tool/icemetadata.cpp b/slicer/tool/icemetadata.cpp
index 69709a1..fee29ae 100644
--- a/slicer/tool/icemetadata.cpp
+++ b/slicer/tool/icemetadata.cpp
@@ -1,6 +1,6 @@
#include "icemetadata.h"
-#include "metadata.h"
#include <algorithm>
+#include <slicer/metadata.h>
// IWYU pragma: no_include <list>
namespace Slicer {
diff --git a/slicer/tool/icemetadata.h b/slicer/tool/icemetadata.h
index ad396b5..f9f10fd 100644
--- a/slicer/tool/icemetadata.h
+++ b/slicer/tool/icemetadata.h
@@ -4,7 +4,7 @@
#include <Slice/Parser.h>
#include <c++11Helpers.h>
#include <cstddef>
-#include <metadata.h>
+#include <slicer/metadata.h>
#include <string>
#include <string_view>
#include <utility>
diff --git a/slicer/xml/Jamfile.jam b/slicer/xml/Jamfile.jam
index 408b15a..d227b83 100644
--- a/slicer/xml/Jamfile.jam
+++ b/slicer/xml/Jamfile.jam
@@ -7,7 +7,6 @@ lib slicer-xml :
[ glob *.cpp : test*.cpp ]
xmlExceptions
:
- <include>..
<library>stdc++fs
<library>..//Ice
<library>../..//libxmlpp
diff --git a/slicer/xml/serializer.h b/slicer/xml/serializer.h
index b2c0b7c..fd8616c 100644
--- a/slicer/xml/serializer.h
+++ b/slicer/xml/serializer.h
@@ -10,10 +10,10 @@
#endif
#include <libxml++/nodes/element.h>
#pragma GCC diagnostic pop
-#include "modelParts.h"
#include <filesystem>
#include <functional>
#include <iosfwd>
+#include <slicer/modelParts.h>
#include <slicer/serializer.h>
#include <string>
#include <visibility.h>
diff --git a/slicer/xml/xmlExceptions.ice b/slicer/xml/xmlExceptions.ice
index 94dee30..390f458 100644
--- a/slicer/xml/xmlExceptions.ice
+++ b/slicer/xml/xmlExceptions.ice
@@ -1,7 +1,7 @@
#ifndef SLICER_XML
#define SLICER_XML
-#include <common.ice>
+#include <slicer/common.ice>
module Slicer {
["cpp:ice_print"]