diff --git a/CMakeLists.txt b/CMakeLists.txt index fc21994..af51c87 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -6,7 +6,7 @@ set(CMAKE_CXX_STANDARD 17) project (banana) -file(GLOB SOURCES "lib/*.cpp") +file(GLOB SOURCES "src/lib/*.cpp") add_library(banana_lib ${SOURCES}) target_link_libraries(banana_lib -lffi) diff --git a/native/prime.cpp b/native/prime.cpp index 089b3fe..f453242 100644 --- a/native/prime.cpp +++ b/native/prime.cpp @@ -1,4 +1,4 @@ -#include "../lib/c_interface.h" +#include "../src/lib/c_interface.h" bool is_prime(const long& n) { for (long i=2; i #include #include -#include "../lib/instructions.h" -#include "../lib/byteutils.h" -#include "../lib/fileutils.h" +#include "lib/instructions.h" +#include "lib/byteutils.h" +#include "lib/fileutils.h" std::string trim(const std::string& str, const std::string& character) { size_t begin = str.find_first_not_of(character); diff --git a/src/banana.cpp b/src/banana.cpp index 5d60273..9aa7607 100644 --- a/src/banana.cpp +++ b/src/banana.cpp @@ -1,10 +1,10 @@ #include #include #include -#include "../lib/ast.h" -#include "../lib/scanner.h" -#include "../lib/parser.h" -#include "../lib/fileutils.h" +#include "lib/ast.h" +#include "lib/scanner.h" +#include "lib/parser.h" +#include "lib/fileutils.h" std::vector> get_instructions( const std::string& filename, diff --git a/src/banana_test.cpp b/src/banana_test.cpp index 44068cb..43a7a8f 100644 --- a/src/banana_test.cpp +++ b/src/banana_test.cpp @@ -1,9 +1,9 @@ #include #include -#include "../lib/ast.h" -#include "../lib/scanner.h" -#include "../lib/parser.h" -#include "../lib/vm.h" +#include "lib/ast.h" +#include "lib/scanner.h" +#include "lib/parser.h" +#include "lib/vm.h" #include "gtest/gtest.h" namespace { diff --git a/lib/ast.cpp b/src/lib/ast.cpp similarity index 100% rename from lib/ast.cpp rename to src/lib/ast.cpp diff --git a/lib/ast.h b/src/lib/ast.h similarity index 100% rename from lib/ast.h rename to src/lib/ast.h diff --git a/lib/byteutils.cpp b/src/lib/byteutils.cpp similarity index 100% rename from lib/byteutils.cpp rename to src/lib/byteutils.cpp diff --git a/lib/byteutils.h b/src/lib/byteutils.h similarity index 100% rename from lib/byteutils.h rename to src/lib/byteutils.h diff --git a/lib/c_functions.cpp b/src/lib/c_functions.cpp similarity index 100% rename from lib/c_functions.cpp rename to src/lib/c_functions.cpp diff --git a/lib/c_functions.h b/src/lib/c_functions.h similarity index 100% rename from lib/c_functions.h rename to src/lib/c_functions.h diff --git a/lib/c_interface.h b/src/lib/c_interface.h similarity index 100% rename from lib/c_interface.h rename to src/lib/c_interface.h diff --git a/lib/fileutils.cpp b/src/lib/fileutils.cpp similarity index 100% rename from lib/fileutils.cpp rename to src/lib/fileutils.cpp diff --git a/lib/fileutils.h b/src/lib/fileutils.h similarity index 100% rename from lib/fileutils.h rename to src/lib/fileutils.h diff --git a/lib/instructions.cpp b/src/lib/instructions.cpp similarity index 100% rename from lib/instructions.cpp rename to src/lib/instructions.cpp diff --git a/lib/instructions.h b/src/lib/instructions.h similarity index 100% rename from lib/instructions.h rename to src/lib/instructions.h diff --git a/lib/maputils.h b/src/lib/maputils.h similarity index 100% rename from lib/maputils.h rename to src/lib/maputils.h diff --git a/lib/parser.cpp b/src/lib/parser.cpp similarity index 100% rename from lib/parser.cpp rename to src/lib/parser.cpp diff --git a/lib/parser.h b/src/lib/parser.h similarity index 100% rename from lib/parser.h rename to src/lib/parser.h diff --git a/lib/scanner.cpp b/src/lib/scanner.cpp similarity index 100% rename from lib/scanner.cpp rename to src/lib/scanner.cpp diff --git a/lib/scanner.h b/src/lib/scanner.h similarity index 100% rename from lib/scanner.h rename to src/lib/scanner.h diff --git a/lib/var.cpp b/src/lib/var.cpp similarity index 100% rename from lib/var.cpp rename to src/lib/var.cpp diff --git a/lib/var.h b/src/lib/var.h similarity index 100% rename from lib/var.h rename to src/lib/var.h diff --git a/lib/vm.cpp b/src/lib/vm.cpp similarity index 100% rename from lib/vm.cpp rename to src/lib/vm.cpp diff --git a/lib/vm.h b/src/lib/vm.h similarity index 100% rename from lib/vm.h rename to src/lib/vm.h