Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
97 changes: 47 additions & 50 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,76 +44,85 @@ jobs:
matrix:
include:
# Linux, gcc
- { compiler: gcc-4.8, cxxstd: '03,11', os: ubuntu-18.04 }
- { compiler: gcc-5, cxxstd: '03,11', os: ubuntu-18.04 }
- { compiler: gcc-6, cxxstd: '03,11,14,17', os: ubuntu-18.04 }
- { compiler: gcc-7, cxxstd: '03,11,14,17', os: ubuntu-18.04 }
- { compiler: gcc-8, cxxstd: '03,11,14,17,2a', os: ubuntu-18.04 }
- { compiler: gcc-9, cxxstd: '03,11,14,17,2a', os: ubuntu-18.04 }
- { compiler: gcc-10, cxxstd: '03,11,14,17,20', os: ubuntu-20.04 }
- { compiler: gcc-11, cxxstd: '03,11,14,17,20', os: ubuntu-20.04, self-contained-header-tests: 1 }
- { compiler: gcc-4.8, cxxstd: '11', container: 'ubuntu:18.04', os: ubuntu-latest }
- { compiler: gcc-5, cxxstd: '11', container: 'ubuntu:18.04', os: ubuntu-latest }
- { compiler: gcc-6, cxxstd: '11,14,17', container: 'ubuntu:18.04', os: ubuntu-latest }
- { compiler: gcc-7, cxxstd: '11,14,17', container: 'ubuntu:18.04', os: ubuntu-latest }
- { compiler: gcc-8, cxxstd: '11,14,17,2a', container: 'ubuntu:18.04', os: ubuntu-latest }
- { compiler: gcc-9, cxxstd: '11,14,17,2a', container: 'ubuntu:20.04', os: ubuntu-latest }
- { compiler: gcc-10, cxxstd: '11,14,17,20', container: 'ubuntu:20.04', os: ubuntu-latest }
- { compiler: gcc-11, cxxstd: '11,14,17,20', container: 'ubuntu:22.04', os: ubuntu-latest, self-contained-header-tests: 1 }
# disabled: there are too many issues in serialization and not enough time to add suppressions
# - { name: GCC w/ sanitizers, sanitize: yes,
# compiler: gcc-11, cxxstd: '03,11,14,17,20', os: ubuntu-20.04 }
# compiler: gcc-11, cxxstd: '11,14,17,20', container: 'ubuntu:20.04', os: ubuntu-latest }
- { name: Collect coverage, coverage: yes,
compiler: gcc-10, cxxstd: '03,11', os: ubuntu-20.04, install: 'g++-10-multilib', address-model: '32,64' }
compiler: gcc-10, cxxstd: '11', container: 'ubuntu:20.04', os: ubuntu-latest, install: 'g++-10-multilib', address-model: '32,64' }

# Linux, clang
- { compiler: clang-3.9, cxxstd: '03,11,14', os: ubuntu-18.04 }
- { compiler: clang-4.0, cxxstd: '03,11,14', os: ubuntu-18.04 }
- { compiler: clang-5.0, cxxstd: '03,11,14,1z', os: ubuntu-18.04 }
- { compiler: clang-6.0, cxxstd: '03,11,14,17', os: ubuntu-18.04 }
- { compiler: clang-7, cxxstd: '03,11,14,17', os: ubuntu-18.04 }
- { compiler: clang-3.9, cxxstd: '11,14', container: 'ubuntu:18.04', os: ubuntu-latest }
- { compiler: clang-4.0, cxxstd: '11,14', container: 'ubuntu:18.04', os: ubuntu-latest }
- { compiler: clang-5.0, cxxstd: '11,14,1z', container: 'ubuntu:18.04', os: ubuntu-latest }
- { compiler: clang-6.0, cxxstd: '11,14,17', container: 'ubuntu:18.04', os: ubuntu-latest }
- { compiler: clang-7, cxxstd: '11,14,17', container: 'ubuntu:18.04', os: ubuntu-latest }
# Note: clang-8 does not fully support C++20, so it is not compatible with some libstdc++ versions in this mode
- { compiler: clang-8, cxxstd: '03,11,14,17,2a', os: ubuntu-18.04, install: 'clang-8 g++-7', gcc_toolchain: 7 }
- { compiler: clang-9, cxxstd: '03,11,14,17,2a', os: ubuntu-20.04 }
- { compiler: clang-10, cxxstd: '03,11,14,17,20', os: ubuntu-20.04 }
- { compiler: clang-11, cxxstd: '03,11,14,17,20', os: ubuntu-20.04 }
- { compiler: clang-12, cxxstd: '03,11,14,17,20', os: ubuntu-20.04, self-contained-header-tests: 1 }
- { compiler: clang-8, cxxstd: '11,14,17,2a', container: 'ubuntu:18.04', os: ubuntu-latest, install: 'clang-8 g++-7' }
- { compiler: clang-9, cxxstd: '11,14,17,2a', container: 'ubuntu:20.04', os: ubuntu-latest }
- { compiler: clang-10, cxxstd: '11,14,17,20', container: 'ubuntu:20.04', os: ubuntu-latest }
- { compiler: clang-11, cxxstd: '11,14,17,20', container: 'ubuntu:20.04', os: ubuntu-latest }
- { compiler: clang-12, cxxstd: '11,14,17,20', container: 'ubuntu:20.04', os: ubuntu-latest, self-contained-header-tests: 1 }

# libc++
- { compiler: clang-6.0, cxxstd: '03,11,14', os: ubuntu-18.04, stdlib: libc++, install: 'clang-6.0 libc++-dev libc++abi-dev' }
- { compiler: clang-12, cxxstd: '03,11,14,17,20', os: ubuntu-20.04, stdlib: libc++, install: 'clang-12 libc++-12-dev libc++abi-12-dev', self-contained-header-tests: 1 }
- { compiler: clang-6.0, cxxstd: '11,14', container: 'ubuntu:18.04', os: ubuntu-latest, stdlib: libc++, install: 'clang-6.0 libc++-dev libc++abi-dev' }
- { compiler: clang-12, cxxstd: '11,14,17,20', container: 'ubuntu:20.04', os: ubuntu-latest, stdlib: libc++, install: 'clang-12 libc++-12-dev libc++abi-12-dev', self-contained-header-tests: 1 }
# disabled: there are too many issues in serialization and not enough time to add suppressions
# - { name: Clang w/ sanitizers, sanitize: yes,
# compiler: clang-12, cxxstd: '03,11,14,17,20', os: ubuntu-20.04, stdlib: libc++, install: 'clang-12 libc++-12-dev libc++abi-12-dev' }
# compiler: clang-12, cxxstd: '11,14,17,20', container: 'ubuntu:20.04', os: ubuntu-latest, stdlib: libc++, install: 'clang-12 libc++-12-dev libc++abi-12-dev' }

# OSX, clang
# sanitize disabled: there are too many issues in serialization and not enough time to add suppressions
- { compiler: clang, cxxstd: '03,11,14,17,2a', os: macos-11 }
- { compiler: clang, cxxstd: '11,14,17,20', os: macos-latest }

# Coverity Scan
# requires two github secrets in repo to activate; see ci/github/coverity.sh
# does not run on pull requests, only on pushes into develop and master
- { name: Coverity, coverity: yes,
compiler: clang-10, cxxstd: '17', os: ubuntu-20.04, ccache: no }
compiler: clang-10, cxxstd: '17', container: 'ubuntu:20.04', os: ubuntu-latest, ccache: no }

# multiarch (bigendian testing) - does not support coverage yet
# date_time has no endian compile-time branches
# - { name: Big-endian, multiarch: yes,
# compiler: clang, cxxstd: '17', os: ubuntu-20.04, ccache: no, distro: fedora, edition: 34, arch: s390x }
# compiler: clang, cxxstd: '17', container: 'ubuntu:20.04', os: ubuntu-latest, ccache: no, distro: fedora, edition: 34, arch: s390x }


timeout-minutes: 120
runs-on: ${{matrix.os}}
container: ${{matrix.container}}
container:
image: ${{matrix.container}}
volumes:
- /node20217:/node20217:rw,rshared
- ${{ startsWith(matrix.container, 'ubuntu:1') && '/node20217:/__e/node20:ro,rshared' || ' ' }}
env: {B2_USE_CCACHE: 1}

steps:
- name: Setup container environment
if: matrix.container
run: |
apt-get update
apt-get -y install sudo python3 git g++ curl xz-utils

- name: Install nodejs20glibc2.17
if: ${{ startsWith( matrix.container, 'ubuntu:1' ) }}
run: |
curl -LO https://archives.boost.io/misc/node/node-v20.9.0-linux-x64-glibc-217.tar.xz
tar -xf node-v20.9.0-linux-x64-glibc-217.tar.xz --strip-components 1 -C /node20217
ldd /__e/node20/bin/node

- name: Setup environment
run: |
if [ -f "/etc/debian_version" ]; then
echo "DEBIAN_FRONTEND=noninteractive" >> $GITHUB_ENV
export DEBIAN_FRONTEND=noninteractive
fi
if [ -n "${{matrix.container}}" ] && [ -f "/etc/debian_version" ]; then
apt-get -o Acquire::Retries=$NET_RETRY_COUNT update
apt-get -o Acquire::Retries=$NET_RETRY_COUNT install -y sudo software-properties-common
# Need (newer) git
for i in {1..${NET_RETRY_COUNT:-3}}; do sudo -E add-apt-repository -y ppa:git-core/ppa && break || sleep 10; done
apt-get -o Acquire::Retries=$NET_RETRY_COUNT update
apt-get -o Acquire::Retries=$NET_RETRY_COUNT install -y g++ python libpython-dev git
fi
# multiple job types are not compatible with ccache, they use "ccache: no" in the matrix
if [[ "${{ matrix.ccache }}" == "no" ]]; then
echo "B2_USE_CCACHE=0" >> $GITHUB_ENV
Expand Down Expand Up @@ -174,18 +183,6 @@ jobs:
fi
sudo apt-get -o Acquire::Retries=$NET_RETRY_COUNT install -y $pkgs

- name: Setup GCC Toolchain
if: matrix.gcc_toolchain
run: |
GCC_TOOLCHAIN_ROOT="$HOME/gcc-toolchain"
echo "GCC_TOOLCHAIN_ROOT=$GCC_TOOLCHAIN_ROOT" >> $GITHUB_ENV
MULTIARCH_TRIPLET="$(dpkg-architecture -qDEB_HOST_MULTIARCH)"
mkdir -p "$GCC_TOOLCHAIN_ROOT"
ln -s /usr/include "$GCC_TOOLCHAIN_ROOT/include"
ln -s /usr/bin "$GCC_TOOLCHAIN_ROOT/bin"
mkdir -p "$GCC_TOOLCHAIN_ROOT/lib/gcc/$MULTIARCH_TRIPLET"
ln -s "/usr/lib/gcc/$MULTIARCH_TRIPLET/${{matrix.gcc_toolchain}}" "$GCC_TOOLCHAIN_ROOT/lib/gcc/$MULTIARCH_TRIPLET/${{matrix.gcc_toolchain}}"

- name: Setup multiarch
if: matrix.multiarch
run: |
Expand Down Expand Up @@ -240,7 +237,7 @@ jobs:
- { toolset: msvc-14.2, cxxstd: '14,17,20', addrmd: '32,64', os: windows-2019, self-contained-header-tests: 1 }
- { name: Collect coverage, coverage: yes,
toolset: msvc-14.3, cxxstd: '14,17,20', addrmd: '32,64', os: windows-2022 }
- { toolset: gcc, cxxstd: '03,11,14,17,2a', addrmd: '64', os: windows-2019 }
- { toolset: gcc, cxxstd: '11,14,17,2a', addrmd: '64', os: windows-2019 }

runs-on: ${{matrix.os}}

Expand Down Expand Up @@ -296,8 +293,8 @@ jobs:
fail-fast: false
matrix:
include:
- { os: ubuntu-20.04, build_shared: ON, build_type: Release, generator: 'Unix Makefiles' }
- { os: ubuntu-20.04, build_shared: OFF, build_type: Debug, generator: 'Unix Makefiles' }
- { os: ubuntu-latest, build_shared: ON, build_type: Release, generator: 'Unix Makefiles' }
- { os: ubuntu-latest, build_shared: OFF, build_type: Debug, generator: 'Unix Makefiles' }
- { os: windows-2019, build_shared: ON, build_type: Release, generator: 'Visual Studio 16 2019' }
- { os: windows-2019, build_shared: OFF, build_type: Debug, generator: 'Visual Studio 16 2019' }

Expand Down
11 changes: 0 additions & 11 deletions Jamfile

This file was deleted.

38 changes: 38 additions & 0 deletions build.jam
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
# Copyright René Ferdinand Rivera Morell 2023-2024
# Distributed under the Boost Software License, Version 1.0.
# (See accompanying file LICENSE_1_0.txt or copy at
# http://www.boost.org/LICENSE_1_0.txt)

require-b2 5.2 ;

constant boost_dependencies :
/boost/algorithm//boost_algorithm
/boost/assert//boost_assert
/boost/config//boost_config
/boost/core//boost_core
/boost/io//boost_io
/boost/lexical_cast//boost_lexical_cast
/boost/numeric_conversion//boost_numeric_conversion
/boost/range//boost_range
/boost/smart_ptr//boost_smart_ptr
/boost/static_assert//boost_static_assert
/boost/throw_exception//boost_throw_exception
/boost/tokenizer//boost_tokenizer
/boost/type_traits//boost_type_traits
/boost/utility//boost_utility
/boost/winapi//boost_winapi ;

project /boost/date_time
: common-requirements
<include>include
;

explicit
[ alias boost_date_time : build//boost_date_time ]
[ alias all : boost_date_time example test ]
;

call-if : boost-library date_time
: install boost_date_time
;

10 changes: 5 additions & 5 deletions build/Jamfile.v2
Original file line number Diff line number Diff line change
@@ -1,24 +1,24 @@
# Copyright (c) 2002-2005 CrystalClear Software, Inc.
# Use, modification and distribution is subject to the
# Use, modification and distribution is subject to the
# Boost Software License, Version 1.0. (See accompanying
# file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt)
#
# date_time is now header only -- this file provides a stub for backward compatibility
#


project boost/date_time
project
: common-requirements <library>$(boost_dependencies)
: requirements
<define>DATE_TIME_INLINE
<link>shared:<define>BOOST_ALL_DYN_LINK=1
<link>shared:<define>BOOST_ALL_DYN_LINK=1
: usage-requirements
<define>DATE_TIME_INLINE
<link>shared:<define>BOOST_DATE_TIME_DYN_LINK=1
<define>BOOST_DATE_TIME_NO_LINK=1
: source-location ../src
;

# greg_month.cpp is now just a stub so that there is
# still a boost_date_time library to link for backward compatibility
lib boost_date_time : gregorian/greg_month.cpp ;

boost-install boost_date_time ;
2 changes: 2 additions & 0 deletions doc/build.jam
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@
# (See accompanying file LICENSE_1_0.txt or copy at
# http://www.boost.org/LICENSE_1_0.txt)

require-b2 5.2 ;

###############################################################################
alias boostdoc
: ../xmldoc/date_time.xml
Expand Down
14 changes: 7 additions & 7 deletions example/Jamfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
project libs/date_time/example ;
project : requirements <library>/boost/date_time//boost_date_time ;

exe dates_as_strings : gregorian/dates_as_strings.cpp ;
exe days_alive : gregorian/days_alive.cpp ;
Expand All @@ -18,19 +18,19 @@ exe days_since_year_start : gregorian/days_since_year_start.cpp ;


exe local_utc_conversion : posix_time/local_utc_conversion.cpp
: <define>BOOST_DATE_TIME_POSIX_TIME_STD_CONFIG
: <define>BOOST_DATE_TIME_POSIX_TIME_STD_CONFIG
;

exe print_hours : posix_time/print_hours.cpp
: <define>BOOST_DATE_TIME_POSIX_TIME_STD_CONFIG
: <define>BOOST_DATE_TIME_POSIX_TIME_STD_CONFIG
;

exe time_math : posix_time/time_math.cpp
: <define>BOOST_DATE_TIME_POSIX_TIME_STD_CONFIG
: <define>BOOST_DATE_TIME_POSIX_TIME_STD_CONFIG
;

exe time_periods : posix_time/time_periods.cpp
: <define>BOOST_DATE_TIME_POSIX_TIME_STD_CONFIG
: <define>BOOST_DATE_TIME_POSIX_TIME_STD_CONFIG
;

exe simple_time_zone : local_time/simple_time_zone.cpp ;
Expand All @@ -41,7 +41,7 @@ exe io_tutorial : tutorial/io_tutorial.cpp ;

# Copyright (c) 2002-2005
# CrystalClear Software, Inc.
# Subject to the Boost Software License, Version 1.0.
# (See accompanying file LICENSE_1_0.txt or
# Subject to the Boost Software License, Version 1.0.
# (See accompanying file LICENSE_1_0.txt or
# http://www.boost.org/LICENSE_1_0.txt)

2 changes: 1 addition & 1 deletion meta/libraries.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,5 +13,5 @@
"Jeff Garland <jeff -at- crystalclearsoftware.com>",
"James E. King III <jking -at- apache.org>"
],
"cxxstd": "03"
"cxxstd": "11"
}
Loading
Loading