forked from fmtlib/fmt
Fix linkage errors when linking with a shared library (#2011)
This commit is contained in:
7
.github/workflows/windows.yml
vendored
7
.github/workflows/windows.yml
vendored
@ -12,6 +12,11 @@ jobs:
|
|||||||
os: [windows-2016, windows-2019]
|
os: [windows-2016, windows-2019]
|
||||||
platform: [Win32, x64]
|
platform: [Win32, x64]
|
||||||
build_type: [Debug, Release]
|
build_type: [Debug, Release]
|
||||||
|
include:
|
||||||
|
- os: windows-2016
|
||||||
|
platform: Win32
|
||||||
|
build_type: Debug
|
||||||
|
shared: -DBUILD_SHARED_LIBS=ON
|
||||||
exclude:
|
exclude:
|
||||||
- os: windows-2016
|
- os: windows-2016
|
||||||
platform: Win32
|
platform: Win32
|
||||||
@ -27,7 +32,7 @@ jobs:
|
|||||||
shell: bash
|
shell: bash
|
||||||
working-directory: ${{runner.workspace}}/build
|
working-directory: ${{runner.workspace}}/build
|
||||||
run: |
|
run: |
|
||||||
cmake -DCMAKE_BUILD_TYPE=${{matrix.build_type}} \
|
cmake -DCMAKE_BUILD_TYPE=${{matrix.build_type}} ${{matrix.shared}} \
|
||||||
-A ${{matrix.platform}} $GITHUB_WORKSPACE
|
-A ${{matrix.platform}} $GITHUB_WORKSPACE
|
||||||
|
|
||||||
- name: Build
|
- name: Build
|
||||||
|
@ -37,9 +37,9 @@
|
|||||||
#include <cmath>
|
#include <cmath>
|
||||||
#include <cstdint>
|
#include <cstdint>
|
||||||
#include <limits>
|
#include <limits>
|
||||||
|
#include <memory>
|
||||||
#include <stdexcept>
|
#include <stdexcept>
|
||||||
#include <utility> // std::swap
|
#include <utility> // std::swap
|
||||||
#include <memory>
|
|
||||||
|
|
||||||
#include "core.h"
|
#include "core.h"
|
||||||
|
|
||||||
@ -1295,7 +1295,7 @@ template <typename T> struct decimal_fp {
|
|||||||
int exponent;
|
int exponent;
|
||||||
};
|
};
|
||||||
|
|
||||||
template <typename T> decimal_fp<T> to_decimal(T x) FMT_NOEXCEPT;
|
template <typename T> FMT_API decimal_fp<T> to_decimal(T x) FMT_NOEXCEPT;
|
||||||
} // namespace dragonbox
|
} // namespace dragonbox
|
||||||
|
|
||||||
template <typename T>
|
template <typename T>
|
||||||
|
@ -378,7 +378,7 @@ struct ostream_params {
|
|||||||
static constexpr detail::buffer_size buffer_size;
|
static constexpr detail::buffer_size buffer_size;
|
||||||
|
|
||||||
// A fast output stream which is not thread-safe.
|
// A fast output stream which is not thread-safe.
|
||||||
class ostream final : private detail::buffer<char> {
|
class FMT_API ostream final : private detail::buffer<char> {
|
||||||
private:
|
private:
|
||||||
file file_;
|
file file_;
|
||||||
|
|
||||||
|
@ -24,9 +24,9 @@ int format_float(char* buf, std::size_t size, const char* format, int precision,
|
|||||||
: snprintf_ptr(buf, size, format, precision, value);
|
: snprintf_ptr(buf, size, format, precision, value);
|
||||||
}
|
}
|
||||||
|
|
||||||
template dragonbox::decimal_fp<float> dragonbox::to_decimal(float x)
|
template FMT_API dragonbox::decimal_fp<float> dragonbox::to_decimal(float x)
|
||||||
FMT_NOEXCEPT;
|
FMT_NOEXCEPT;
|
||||||
template dragonbox::decimal_fp<double> dragonbox::to_decimal(double x)
|
template FMT_API dragonbox::decimal_fp<double> dragonbox::to_decimal(double x)
|
||||||
FMT_NOEXCEPT;
|
FMT_NOEXCEPT;
|
||||||
|
|
||||||
// DEPRECATED! This function exists for ABI compatibility.
|
// DEPRECATED! This function exists for ABI compatibility.
|
||||||
|
Reference in New Issue
Block a user