Skip to content

Commit c6313f1

Browse files
committed
Up version to v0.1.8
1 parent 62a6f85 commit c6313f1

File tree

5 files changed

+77
-43
lines changed

5 files changed

+77
-43
lines changed

build_simple.sh

Lines changed: 24 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,26 @@
11
#!/bin/bash
22

3-
if [ ! -d tmp/linux ]; then
4-
mkdir -p tmp/linux
5-
fi
6-
7-
cd tmp/linux
8-
cmake ../..
9-
make
10-
# cp -rf wsjcpp-yaml ../
3+
check_ret() {
4+
if [ $1 -ne 0 ]; then
5+
echo ""
6+
echo "!!! FAIL: $2"
7+
echo "********************************************************************************"
8+
echo ""
9+
exit $1
10+
else
11+
echo ""
12+
echo "*** SUCCESS: $2"
13+
echo "********************************************************************************"
14+
echo ""
15+
fi
16+
}
17+
18+
# if [ ! -d tmp/linux_release ]; then
19+
# mkdir -p tmp/linux_release
20+
# fi
21+
22+
cmake -H. -B./tmp/linux_release -DCMAKE_BUILD_TYPE=Release
23+
check_ret $? "configure"
24+
25+
cmake --build ./tmp/linux_release --config Release
26+
check_ret $? "build"

src.wsjcpp/CMakeLists.txt

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
# Automaticly generated by wsjcpp@v0.2.2
22
cmake_minimum_required(VERSION 3.0)
33

4-
add_definitions(-DWSJCPP_APP_VERSION="v0.1.7")
4+
add_definitions(-DWSJCPP_APP_VERSION="v0.1.8")
55
add_definitions(-DWSJCPP_APP_NAME="wsjcpp-yaml")
66

77
if (${CMAKE_SYSTEM_NAME} MATCHES "Darwin")
88
set(MACOSX TRUE)
99
endif()
1010

11-
set(CMAKE_CXX_STANDARD 11)
11+
set(CMAKE_CXX_STANDARD 17)
1212

1313
set (WSJCPP_LIBRARIES "")
1414
set (WSJCPP_INCLUDE_DIRS "")
@@ -18,8 +18,8 @@ find_package(Threads REQUIRED)
1818
list (APPEND WSJCPP_LIBRARIES ${CMAKE_THREAD_LIBS_INIT})
1919

2020
# wsjcpp-core:v0.2.1
21-
list (APPEND WSJCPP_INCLUDE_DIRS "./src.wsjcpp/wsjcpp_core/")
22-
list (APPEND WSJCPP_SOURCES "./src.wsjcpp/wsjcpp_core/wsjcpp_core.cpp")
23-
list (APPEND WSJCPP_SOURCES "./src.wsjcpp/wsjcpp_core/wsjcpp_core.h")
21+
list (APPEND WSJCPP_INCLUDE_DIRS "${CMAKE_SOURCE_DIR}/./src.wsjcpp/wsjcpp_core/")
22+
list (APPEND WSJCPP_SOURCES "${CMAKE_SOURCE_DIR}/./src.wsjcpp/wsjcpp_core/wsjcpp_core.cpp")
23+
list (APPEND WSJCPP_SOURCES "${CMAKE_SOURCE_DIR}/./src.wsjcpp/wsjcpp_core/wsjcpp_core.h")
2424

2525

unit-tests.wsjcpp/CMakeLists.txt

Lines changed: 28 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
cmake_minimum_required(VERSION 3.0)
33

44
project(unit-tests C CXX)
5-
add_definitions(-DWSJCPP_APP_VERSION="ut-v0.1.7")
5+
add_definitions(-DWSJCPP_APP_VERSION="ut-v0.1.8")
66
add_definitions(-DWSJCPP_APP_NAME="unit-tests-wsjcpp-yaml")
77

88
if (${CMAKE_SYSTEM_NAME} MATCHES "Darwin")
@@ -21,37 +21,37 @@ list (APPEND WSJCPP_LIBRARIES ${CMAKE_THREAD_LIBS_INIT})
2121

2222
# wsjcpp-core:v0.2.1
2323
list (APPEND WSJCPP_INCLUDE_DIRS "../src.wsjcpp/wsjcpp_core/")
24-
list (APPEND WSJCPP_SOURCES "../src.wsjcpp/wsjcpp_core/wsjcpp_core.cpp")
25-
list (APPEND WSJCPP_SOURCES "../src.wsjcpp/wsjcpp_core/wsjcpp_core.h")
26-
list (APPEND WSJCPP_SOURCES "../src.wsjcpp/wsjcpp_core/wsjcpp_unit_tests.cpp")
27-
list (APPEND WSJCPP_SOURCES "../src.wsjcpp/wsjcpp_core/wsjcpp_unit_tests.h")
28-
list (APPEND WSJCPP_SOURCES "../src.wsjcpp/wsjcpp_core/wsjcpp_unit_tests_main.cpp")
24+
list (APPEND WSJCPP_SOURCES "${CMAKE_SOURCE_DIR}/../src.wsjcpp/wsjcpp_core/wsjcpp_core.cpp")
25+
list (APPEND WSJCPP_SOURCES "${CMAKE_SOURCE_DIR}/../src.wsjcpp/wsjcpp_core/wsjcpp_core.h")
26+
list (APPEND WSJCPP_SOURCES "${CMAKE_SOURCE_DIR}/../src.wsjcpp/wsjcpp_core/wsjcpp_unit_tests.cpp")
27+
list (APPEND WSJCPP_SOURCES "${CMAKE_SOURCE_DIR}/../src.wsjcpp/wsjcpp_core/wsjcpp_unit_tests.h")
28+
list (APPEND WSJCPP_SOURCES "${CMAKE_SOURCE_DIR}/../src.wsjcpp/wsjcpp_core/wsjcpp_unit_tests_main.cpp")
2929

30-
# wsjcpp-yaml:v0.1.7
31-
list (APPEND WSJCPP_INCLUDE_DIRS "../src")
32-
list (APPEND WSJCPP_SOURCES "../src/wsjcpp_yaml.cpp")
33-
list (APPEND WSJCPP_SOURCES "../src/wsjcpp_yaml.h")
30+
# wsjcpp-yaml:v0.1.8
31+
list (APPEND WSJCPP_INCLUDE_DIRS "${CMAKE_SOURCE_DIR}/../src")
32+
list (APPEND WSJCPP_SOURCES "${CMAKE_SOURCE_DIR}/../src/wsjcpp_yaml.cpp")
33+
list (APPEND WSJCPP_SOURCES "${CMAKE_SOURCE_DIR}/../src/wsjcpp_yaml.h")
3434

3535
# unit-tests
3636
list (APPEND WSJCPP_INCLUDE_DIRS "src")
37-
list (APPEND WSJCPP_SOURCES "../unit-tests.wsjcpp/src/unit_test_line_parser.cpp")
38-
list (APPEND WSJCPP_SOURCES "../unit-tests.wsjcpp/src/unit_test_yaml_parser_simple_array.cpp")
39-
list (APPEND WSJCPP_SOURCES "../unit-tests.wsjcpp/src/unit_test_yaml_parser_simple_map.cpp")
40-
list (APPEND WSJCPP_SOURCES "../unit-tests.wsjcpp/src/unit_test_yaml_parser_hierarchical_map.cpp")
41-
list (APPEND WSJCPP_SOURCES "../unit-tests.wsjcpp/src/unit_test_yaml_parser_quotes.cpp")
42-
list (APPEND WSJCPP_SOURCES "../unit-tests.wsjcpp/src/unit_test_yaml_parser_comments.cpp")
43-
list (APPEND WSJCPP_SOURCES "../unit-tests.wsjcpp/src/unit_test_yaml_parser_all.cpp")
44-
list (APPEND WSJCPP_SOURCES "../unit-tests.wsjcpp/src/unit_test_yaml_parser_array_included_map.cpp")
45-
list (APPEND WSJCPP_SOURCES "../unit-tests.wsjcpp/src/unit_test_remove_element_for_map.cpp")
46-
list (APPEND WSJCPP_SOURCES "../unit-tests.wsjcpp/src/unit_test_remove_element_in_array.cpp")
47-
list (APPEND WSJCPP_SOURCES "../unit-tests.wsjcpp/src/unit_test_memory_leaks.cpp")
48-
list (APPEND WSJCPP_SOURCES "../unit-tests.wsjcpp/src/unit_test_read_yaml.cpp")
49-
list (APPEND WSJCPP_SOURCES "../unit-tests.wsjcpp/src/unit_test_read_write_file.cpp")
50-
list (APPEND WSJCPP_SOURCES "../unit-tests.wsjcpp/src/unit_test_cursor.cpp")
51-
list (APPEND WSJCPP_SOURCES "../unit-tests.wsjcpp/src/unit_test_tag_names.cpp")
52-
list (APPEND WSJCPP_SOURCES "../unit-tests.wsjcpp/src/unit_test_cleanup.cpp")
53-
list (APPEND WSJCPP_SOURCES "../unit-tests.wsjcpp/src/unit_test_append_elements.cpp")
54-
list (APPEND WSJCPP_SOURCES "../unit-tests.wsjcpp/src/unit_test_keep_format.cpp")
37+
list (APPEND WSJCPP_SOURCES "${CMAKE_SOURCE_DIR}/../unit-tests.wsjcpp/src/unit_test_line_parser.cpp")
38+
list (APPEND WSJCPP_SOURCES "${CMAKE_SOURCE_DIR}/../unit-tests.wsjcpp/src/unit_test_yaml_parser_simple_array.cpp")
39+
list (APPEND WSJCPP_SOURCES "${CMAKE_SOURCE_DIR}/../unit-tests.wsjcpp/src/unit_test_yaml_parser_simple_map.cpp")
40+
list (APPEND WSJCPP_SOURCES "${CMAKE_SOURCE_DIR}/../unit-tests.wsjcpp/src/unit_test_yaml_parser_hierarchical_map.cpp")
41+
list (APPEND WSJCPP_SOURCES "${CMAKE_SOURCE_DIR}/../unit-tests.wsjcpp/src/unit_test_yaml_parser_quotes.cpp")
42+
list (APPEND WSJCPP_SOURCES "${CMAKE_SOURCE_DIR}/../unit-tests.wsjcpp/src/unit_test_yaml_parser_comments.cpp")
43+
list (APPEND WSJCPP_SOURCES "${CMAKE_SOURCE_DIR}/../unit-tests.wsjcpp/src/unit_test_yaml_parser_all.cpp")
44+
list (APPEND WSJCPP_SOURCES "${CMAKE_SOURCE_DIR}/../unit-tests.wsjcpp/src/unit_test_yaml_parser_array_included_map.cpp")
45+
list (APPEND WSJCPP_SOURCES "${CMAKE_SOURCE_DIR}/../unit-tests.wsjcpp/src/unit_test_remove_element_for_map.cpp")
46+
list (APPEND WSJCPP_SOURCES "${CMAKE_SOURCE_DIR}/../unit-tests.wsjcpp/src/unit_test_remove_element_in_array.cpp")
47+
list (APPEND WSJCPP_SOURCES "${CMAKE_SOURCE_DIR}/../unit-tests.wsjcpp/src/unit_test_memory_leaks.cpp")
48+
list (APPEND WSJCPP_SOURCES "${CMAKE_SOURCE_DIR}/../unit-tests.wsjcpp/src/unit_test_read_yaml.cpp")
49+
list (APPEND WSJCPP_SOURCES "${CMAKE_SOURCE_DIR}/../unit-tests.wsjcpp/src/unit_test_read_write_file.cpp")
50+
list (APPEND WSJCPP_SOURCES "${CMAKE_SOURCE_DIR}/../unit-tests.wsjcpp/src/unit_test_cursor.cpp")
51+
list (APPEND WSJCPP_SOURCES "${CMAKE_SOURCE_DIR}/../unit-tests.wsjcpp/src/unit_test_tag_names.cpp")
52+
list (APPEND WSJCPP_SOURCES "${CMAKE_SOURCE_DIR}/../unit-tests.wsjcpp/src/unit_test_cleanup.cpp")
53+
list (APPEND WSJCPP_SOURCES "${CMAKE_SOURCE_DIR}/../unit-tests.wsjcpp/src/unit_test_append_elements.cpp")
54+
list (APPEND WSJCPP_SOURCES "${CMAKE_SOURCE_DIR}/../unit-tests.wsjcpp/src/unit_test_keep_format.cpp")
5555

5656
include(${CMAKE_CURRENT_SOURCE_DIR}/CMakeLists.user-custom.txt)
5757

unit-tests.wsjcpp/build_simple.sh

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,28 @@
11
#!/bin/bash
22

3+
check_ret() {
4+
if [ $1 -ne 0 ]; then
5+
echo ""
6+
echo "!!! FAIL: $2"
7+
echo "********************************************************************************"
8+
echo ""
9+
exit $1
10+
else
11+
echo ""
12+
echo "*** SUCCESS: $2"
13+
echo "********************************************************************************"
14+
echo ""
15+
fi
16+
}
17+
318
if [ ! -d tmp ]; then
419
mkdir -p tmp
520
fi
621

722
cd tmp
823
cmake ..
24+
check_ret $? "configure"
25+
926
make
27+
check_ret $? "make"
1028

wsjcpp.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
wsjcpp_version: v0.0.1
22
cmake_minimum_required: 3.0
3-
cmake_cxx_standard: 11
3+
cmake_cxx_standard: 17
44
name: wsjcpp-yaml
5-
version: v0.1.7
5+
version: v0.1.8
66
description: Read/Write yaml files
77
issues: https://github.com/wsjcpp/wsjcpp-yaml/issues
88

0 commit comments

Comments
 (0)