Skip to content

Commit

Permalink
Merge pull request #1038 from redboltz/fix_1037
Browse files Browse the repository at this point in the history
Fixed #1037.
  • Loading branch information
redboltz authored Nov 2, 2022
2 parents fb64ea0 + 535bf33 commit 2603c2a
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 13 deletions.
6 changes: 3 additions & 3 deletions .github/depends/zlib.sh
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,9 @@ while getopts "b:t:p:" c; do
done

mkdir $prefix || exit 1
wget https://zlib.net/zlib-1.2.12.tar.gz || exit 1
tar -xf zlib-1.2.12.tar.gz || exit 1
cd zlib-1.2.12
wget https://zlib.net/zlib-1.2.13.tar.gz || exit 1
tar -xf zlib-1.2.13.tar.gz || exit 1
cd zlib-1.2.13

build()
{
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/gha.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ jobs:
uses: actions/cache@v2
with:
path: ~/boost-prefix/
key: ${{ runner.os }}-boost-1-76-0-2021-08-09
key: ${{ runner.os }}-boost-1-76-0-2022-08-09

- name: Build boost
if: steps.cache-boost.outputs.cache-hit != 'true'
Expand All @@ -36,7 +36,7 @@ jobs:
uses: actions/cache@v2
with:
path: ~/zlib-prefix/
key: ${{ runner.os }}-zlib-1-2-12-2021-08-09
key: ${{ runner.os }}-zlib-1-2-13-2022-11-02

- name: Build zlib
if: steps.cache-zlib.outputs.cache-hit != 'true'
Expand Down Expand Up @@ -111,7 +111,7 @@ jobs:
uses: actions/cache@v2
with:
path: ~/zlib-prefix/
key: ${{ runner.os }}-zlib-1-2-12-2021-08-09
key: ${{ runner.os }}-zlib-1-2-13-2022-11-02

- name: Build zlib
if: steps.cache-zlib.outputs.cache-hit != 'true'
Expand Down
14 changes: 7 additions & 7 deletions appveyor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,18 +23,18 @@ environment:
boost_subdir: lib32-msvc-14.0
build_script:
- ps: |
appveyor DownloadFile http://zlib.net/zlib-1.2.12.tar.gz -FileName zlib-1.2.12.tar.gz
7z x zlib-1.2.12.tar.gz 2> $null
7z x zlib-1.2.12.tar 2> $null
cd zlib-1.2.12
appveyor DownloadFile http://zlib.net/zlib-1.2.13.tar.gz -FileName zlib-1.2.13.tar.gz
7z x zlib-1.2.13.tar.gz 2> $null
7z x zlib-1.2.13.tar 2> $null
cd zlib-1.2.13
md build
md prefix
cd build
cmake `
-G $env:msvc `
-D CMAKE_INSTALL_PREFIX="$env:APPVEYOR_BUILD_FOLDER\zlib-1.2.12\prefix" `
-D CMAKE_INSTALL_PREFIX="$env:APPVEYOR_BUILD_FOLDER\zlib-1.2.13\prefix" `
..
if ($LastExitCode -ne 0) { exit $LastExitCode }
Expand All @@ -52,7 +52,7 @@ build_script:
-D MSGPACK_BUILD_EXAMPLES=ON `
-D MSGPACK_BUILD_TESTS=ON `
-D CMAKE_EXE_LINKER_FLAGS=/LIBPATH:"$env:boost_prefix\$env:boost_subdir" `
-D CMAKE_PREFIX_PATH="$env:boost_prefix;$env:APPVEYOR_BUILD_FOLDER\zlib-1.2.12\prefix" `
-D CMAKE_PREFIX_PATH="$env:boost_prefix;$env:APPVEYOR_BUILD_FOLDER\zlib-1.2.13\prefix" `
-D CMAKE_INSTALL_PREFIX="$env:APPVEYOR_BUILD_FOLDER\prefix" `
-D CMAKE_CXX_FLAGS="/D_VARIADIC_MAX=10 /EHsc /DBOOST_ALL_DYN_LINK" `
..
Expand All @@ -62,5 +62,5 @@ build_script:
if ($LastExitCode -ne 0) { exit $LastExitCode }
test_script:
- set PATH=%PATH%;%APPVEYOR_BUILD_FOLDER%\zlib-1.2.12\build\Release;%APPVEYOR_BUILD_FOLDER%\build\release;%boost_prefix%\%boost_subdir%
- set PATH=%PATH%;%APPVEYOR_BUILD_FOLDER%\zlib-1.2.13\build\Release;%APPVEYOR_BUILD_FOLDER%\build\release;%boost_prefix%\%boost_subdir%
- ctest -VV -C Release
4 changes: 4 additions & 0 deletions include/msgpack/v1/adaptor/cpp11/chrono.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@
#ifndef MSGPACK_V1_TYPE_CPP11_CHRONO_HPP
#define MSGPACK_V1_TYPE_CPP11_CHRONO_HPP

#if !defined(MSGPACK_NO_BOOST)

#include "msgpack/versioning.hpp"
#include "msgpack/adaptor/adaptor_base.hpp"
#include "msgpack/object.hpp"
Expand Down Expand Up @@ -248,4 +250,6 @@ struct object_with_zone<std::chrono::time_point<Clock, Duration>> {

} // namespace msgpack

#endif // !defined(MSGPACK_NO_BOOST)

#endif // MSGPACK_V1_TYPE_CPP11_CHRONO_HPP

0 comments on commit 2603c2a

Please sign in to comment.