Skip to content

Commit

Permalink
Move public headers out of the src folder
Browse files Browse the repository at this point in the history
  • Loading branch information
= committed Oct 25, 2023
1 parent b123208 commit bb52a10
Show file tree
Hide file tree
Showing 47 changed files with 41 additions and 61 deletions.
15 changes: 9 additions & 6 deletions CMakeLists.txt
Expand Up @@ -25,11 +25,13 @@ add_library(oink::oink ALIAS oink)
set_target_properties(oink PROPERTIES VERSION ${oink_VERSION} SOVERSION ${oink_VERSION_MAJOR})

set(OINK_HDRS
src/oink.hpp
src/error.hpp
src/game.hpp
src/bitset.hpp
src/uintqueue.hpp
include/oink/oink.hpp
include/oink/error.hpp
include/oink/game.hpp
include/oink/solvers.hpp
include/oink/bitset.hpp
include/oink/uintqueue.hpp
include/oink/libpopcnt.h
)

target_compile_features(oink PUBLIC c_std_11 cxx_std_11)
Expand All @@ -47,8 +49,9 @@ target_include_directories(oink
${CMAKE_CURRENT_LIST_DIR}/src
PUBLIC
$<BUILD_INTERFACE:${CMAKE_CURRENT_LIST_DIR}/src>
$<BUILD_INTERFACE:${CMAKE_CURRENT_LIST_DIR}/include>
$<BUILD_INTERFACE:${Boost_INCLUDE_DIRS}>
$<INSTALL_INTERFACE:include/oink>
$<INSTALL_INTERFACE:include>
)

target_link_libraries(oink pthread lace::lace)
Expand Down
2 changes: 1 addition & 1 deletion src/bitset.hpp → include/oink/bitset.hpp
Expand Up @@ -17,7 +17,7 @@
#ifndef BITSET_HPP
#define BITSET_HPP

#include <libpopcnt.h>
#include <oink/libpopcnt.h>

namespace pg
{
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion src/game.hpp → include/oink/game.hpp
Expand Up @@ -24,7 +24,7 @@
#include <boost/random/mersenne_twister.hpp>
#include <boost/random/uniform_int_distribution.hpp>

#include <bitset.hpp>
#include <oink/bitset.hpp>

namespace pg {

Expand Down
File renamed without changes.
6 changes: 3 additions & 3 deletions src/oink.hpp → include/oink/oink.hpp
Expand Up @@ -20,9 +20,9 @@
#include <iostream>
#include <vector>

#include "error.hpp"
#include "game.hpp"
#include "uintqueue.hpp"
#include "oink/error.hpp"
#include "oink/game.hpp"
#include "oink/uintqueue.hpp"

namespace pg {

Expand Down
File renamed without changes.
File renamed without changes.
1 change: 0 additions & 1 deletion src/dtl.hpp
Expand Up @@ -17,7 +17,6 @@
#ifndef DTL_HPP
#define DTL_HPP

#include "oink.hpp"
#include "solver.hpp"

namespace pg {
Expand Down
1 change: 0 additions & 1 deletion src/fpi.cpp
Expand Up @@ -19,7 +19,6 @@
#include <unistd.h>

#include "fpi.hpp"
#include "uintqueue.hpp"

namespace pg {

Expand Down
1 change: 0 additions & 1 deletion src/fpj.cpp
Expand Up @@ -20,7 +20,6 @@
#include <stack>

#include "fpj.hpp"
#include "uintqueue.hpp"

namespace pg {

Expand Down
2 changes: 1 addition & 1 deletion src/game.cpp
Expand Up @@ -20,7 +20,7 @@
#include <iostream>
#include <ctime>

#include "game.hpp"
#include "oink/game.hpp"

#define USE_MMAP 1

Expand Down
1 change: 0 additions & 1 deletion src/mspm.hpp
Expand Up @@ -19,7 +19,6 @@

#include <queue>

#include "oink.hpp"
#include "solver.hpp"

namespace pg {
Expand Down
2 changes: 0 additions & 2 deletions src/npp.hpp
Expand Up @@ -21,9 +21,7 @@
#include <deque>
#include <vector>

#include "oink.hpp"
#include "solver.hpp"
#include "uintqueue.hpp"

namespace pg
{
Expand Down
4 changes: 2 additions & 2 deletions src/oink.cpp
Expand Up @@ -22,8 +22,8 @@
#include <iostream>
#include <chrono>

#include "oink.hpp"
#include "solvers.hpp"
#include "oink/oink.hpp"
#include "oink/solvers.hpp"
#include "solver.hpp"
#include "lace.h"

Expand Down
1 change: 0 additions & 1 deletion src/pp.hpp
Expand Up @@ -19,7 +19,6 @@

#include <queue>

#include "oink.hpp"
#include "solver.hpp"

namespace pg {
Expand Down
1 change: 0 additions & 1 deletion src/ptl.hpp
Expand Up @@ -17,7 +17,6 @@
#ifndef PTL_HPP
#define PTL_HPP

#include "oink.hpp"
#include "solver.hpp"

namespace pg {
Expand Down
1 change: 0 additions & 1 deletion src/qpt.hpp
Expand Up @@ -18,7 +18,6 @@
#define QPT_HPP

#include "solver.hpp"
#include "uintqueue.hpp"

namespace pg {

Expand Down
2 changes: 0 additions & 2 deletions src/rtl.hpp
Expand Up @@ -22,9 +22,7 @@
#include <map>
#include <tuple>

#include "oink.hpp"
#include "solver.hpp"
#include "npp.hpp"

namespace pg {

Expand Down
2 changes: 1 addition & 1 deletion src/scc.cpp
Expand Up @@ -19,7 +19,7 @@
#include <deque>
#include <stack>
#include <cstring> // for memset
#include "oink.hpp"
#include "oink/oink.hpp"

namespace pg {

Expand Down
6 changes: 3 additions & 3 deletions src/solver.hpp
Expand Up @@ -17,9 +17,9 @@
#ifndef SOLVER_HPP
#define SOLVER_HPP

#include "game.hpp"
#include "oink.hpp"
#include "error.hpp"
#include "oink/game.hpp"
#include "oink/oink.hpp"
#include "oink/error.hpp"

namespace pg {

Expand Down
2 changes: 1 addition & 1 deletion src/solvers.cpp
Expand Up @@ -14,7 +14,7 @@
* limitations under the License.
*/

#include "solvers.hpp"
#include "oink/solvers.hpp"

#include "zlk.hpp"
#include "pp.hpp"
Expand Down
1 change: 0 additions & 1 deletion src/spm.hpp
Expand Up @@ -19,7 +19,6 @@

#include <queue>

#include "oink.hpp"
#include "solver.hpp"

namespace pg {
Expand Down
2 changes: 0 additions & 2 deletions src/sspm.hpp
Expand Up @@ -17,9 +17,7 @@
#ifndef SSPM_HPP
#define SSPM_HPP

#include "oink.hpp"
#include "solver.hpp"
#include "uintqueue.hpp"

namespace pg {

Expand Down
1 change: 0 additions & 1 deletion src/tl.hpp
Expand Up @@ -17,7 +17,6 @@
#ifndef TL_HPP
#define TL_HPP

#include "oink.hpp"
#include "solver.hpp"

namespace pg {
Expand Down
2 changes: 1 addition & 1 deletion src/tools/counter_core.cpp
Expand Up @@ -16,7 +16,7 @@

#include <iostream>

#include "game.hpp"
#include "oink/game.hpp"

using namespace pg;

Expand Down
2 changes: 1 addition & 1 deletion src/tools/counter_dp.cpp
Expand Up @@ -16,7 +16,7 @@

#include <iostream>

#include "game.hpp"
#include "oink/game.hpp"

using namespace pg;

Expand Down
2 changes: 1 addition & 1 deletion src/tools/counter_m.cpp
Expand Up @@ -16,7 +16,7 @@

#include <iostream>

#include "game.hpp"
#include "oink/game.hpp"

using namespace pg;

Expand Down
2 changes: 1 addition & 1 deletion src/tools/counter_ortl.cpp
Expand Up @@ -16,7 +16,7 @@

#include <iostream>

#include "game.hpp"
#include "oink/game.hpp"

using namespace pg;

Expand Down
2 changes: 1 addition & 1 deletion src/tools/counter_rob.cpp
Expand Up @@ -16,7 +16,7 @@

#include <iostream>

#include "game.hpp"
#include "oink/game.hpp"

using namespace pg;

Expand Down
2 changes: 1 addition & 1 deletion src/tools/counter_rr.cpp
Expand Up @@ -16,7 +16,7 @@

#include <iostream>

#include "game.hpp"
#include "oink/game.hpp"

using namespace pg;

Expand Down
2 changes: 1 addition & 1 deletion src/tools/counter_symsi.cpp
Expand Up @@ -17,7 +17,7 @@
#include <iostream>
#include <memory>

#include "game.hpp"
#include "oink/game.hpp"

using namespace pg;

Expand Down
2 changes: 1 addition & 1 deletion src/tools/dotty.cpp
Expand Up @@ -17,7 +17,7 @@
#include <iostream>
#include <fstream>

#include "game.hpp"
#include "oink/game.hpp"

using namespace pg;

Expand Down
2 changes: 1 addition & 1 deletion src/tools/nudge.cpp
Expand Up @@ -20,7 +20,7 @@
#include <random>

#include "cxxopts.hpp"
#include "game.hpp"
#include "oink/game.hpp"

using namespace std;
using namespace pg;
Expand Down
2 changes: 1 addition & 1 deletion src/tools/simple.cpp
Expand Up @@ -16,7 +16,7 @@

#include <fstream>

#include "oink.hpp"
#include "oink/oink.hpp"

int
main(int argc, char** argv)
Expand Down
5 changes: 2 additions & 3 deletions src/tools/solve.cpp
Expand Up @@ -27,9 +27,8 @@
#include <boost/iostreams/filter/gzip.hpp>

#include "cxxopts.hpp"
#include "game.hpp"
#include "oink.hpp"
#include "solvers.hpp"
#include "oink/oink.hpp"
#include "oink/solvers.hpp"
#include "verifier.hpp"
#include "tools/getrss.h"

Expand Down
2 changes: 1 addition & 1 deletion src/tools/stgame.cpp
Expand Up @@ -19,7 +19,7 @@
#include <random>
#include <cstring>

#include "game.hpp"
#include "oink/game.hpp"

using namespace std;

Expand Down
2 changes: 1 addition & 1 deletion src/tools/tc+.cpp
Expand Up @@ -17,7 +17,7 @@
#include <iostream>
#include <memory>

#include "game.hpp"
#include "oink/game.hpp"

using namespace std;
using namespace pg;
Expand Down
2 changes: 1 addition & 1 deletion src/tools/tc.cpp
Expand Up @@ -17,7 +17,7 @@
#include <iostream>
#include <memory>

#include "game.hpp"
#include "oink/game.hpp"

#define DOUBLEDISTRACTION 0

Expand Down
2 changes: 1 addition & 1 deletion src/tools/verify.cpp
Expand Up @@ -18,7 +18,7 @@
#include <fstream>
#include <sys/time.h>

#include "game.hpp"
#include "oink/game.hpp"
#include "verifier.hpp"

using namespace std;
Expand Down
1 change: 0 additions & 1 deletion src/tspm.hpp
Expand Up @@ -19,7 +19,6 @@

#include <queue>

#include "oink.hpp"
#include "solver.hpp"

namespace pg {
Expand Down
1 change: 0 additions & 1 deletion src/verifier.cpp
Expand Up @@ -24,7 +24,6 @@
#include <deque>
#include <stack>

#include "game.hpp"
#include "verifier.hpp"

using namespace std;
Expand Down
2 changes: 1 addition & 1 deletion src/verifier.hpp
Expand Up @@ -18,7 +18,7 @@
#define VERIFIER_HPP

#include <istream>
#include "game.hpp"
#include "oink/game.hpp"

namespace pg {

Expand Down
2 changes: 0 additions & 2 deletions src/zlk.hpp
Expand Up @@ -20,8 +20,6 @@
#include <queue>

#include "solver.hpp"
#include "lace.h"
#include "uintqueue.hpp"

namespace pg {

Expand Down
1 change: 0 additions & 1 deletion src/zlkpp.hpp
Expand Up @@ -7,7 +7,6 @@

#include <vector>

#include "oink.hpp"
#include "solver.hpp"

namespace pg {
Expand Down

0 comments on commit bb52a10

Please sign in to comment.