Skip to content

Commit 346e1ac

Browse files
committed
Content for v0.3.0
1 parent e9c914c commit 346e1ac

File tree

2 files changed

+17
-17
lines changed

2 files changed

+17
-17
lines changed

CMakeLists.txt

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,19 @@
11
cmake_minimum_required(VERSION "3.12")
22

3-
project("spackexample" VERSION 0.2.0)
3+
project("spackexample" VERSION 0.3.0)
44

55
find_package(Boost
66
1.65.1
77
REQUIRED
88
filesystem
99
)
1010

11-
#find_package(yaml-cpp
12-
# 0.7.0
13-
# REQUIRED
14-
# )
11+
find_package(yaml-cpp
12+
0.7.0
13+
REQUIRED
14+
)
1515

16-
add_library(spackexamplelib filesystem/filesystem.cpp flatset/flatset.cpp)
17-
#add_library(spackexamplelib filesystem/filesystem.cpp flatset/flatset.cpp yamlParser/yamlParser.cpp)
16+
add_library(spackexamplelib filesystem/filesystem.cpp flatset/flatset.cpp yamlParser/yamlParser.cpp)
1817

1918
set_target_properties(spackexamplelib
2019
PROPERTIES
@@ -23,10 +22,11 @@ set_target_properties(spackexamplelib
2322
PUBLIC_HEADER yamlParser/yamlParser.hpp
2423
)
2524

25+
include_directories(${YAML_CPP_INCLUDE_DIR})
26+
2627
add_executable(spackexample main.cpp)
2728
target_link_libraries(spackexample spackexamplelib)
28-
target_link_libraries(spackexamplelib Boost::filesystem)
29-
#target_link_libraries(spackexamplelib Boost::filesystem ${YAML_CPP_LIBRARIES})
29+
target_link_libraries(spackexamplelib Boost::filesystem yaml-cpp)
3030

3131
target_include_directories(spackexamplelib
3232
PRIVATE

main.cpp

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#include "flatset/flatset.hpp"
22
#include "filesystem/filesystem.hpp"
3-
//#include "yamlParser/yamlParser.hpp"
3+
#include "yamlParser/yamlParser.hpp"
44
#include <iostream>
55

66
int main(int argc, char *argv[])
@@ -15,13 +15,13 @@ int main(int argc, char *argv[])
1515
inspectDirectory();
1616
std::cout << std::endl;
1717

18-
//if ( argc == 2 )
19-
//{
20-
// const std::string yamlFile( argv[1] );
21-
// std::cout << "Parse some yaml file with yaml-cpp" << std::endl;
22-
// std::cout << " " << yamlFile << std::endl;
23-
// parseConfig( yamlFile );
24-
//}
18+
if ( argc == 2 )
19+
{
20+
const std::string yamlFile( argv[1] );
21+
std::cout << "Parse some yaml file with yaml-cpp" << std::endl;
22+
std::cout << " " << yamlFile << std::endl;
23+
parseConfig( yamlFile );
24+
}
2525

2626
return 0;
2727
}

0 commit comments

Comments
 (0)