mirror of
https://github.com/HowardHinnant/date.git
synced 2024-12-25 23:40:53 +08:00
Ensure Android private functions dont show up
... for external consumers like tests Signed-off-by: Vasyl Gello <vasek.gello@gmail.com>
This commit is contained in:
parent
7657ad7855
commit
fca69e308d
@ -112,6 +112,7 @@ endif()
|
||||
#]===================================================================]
|
||||
if( BUILD_TZ_LIB )
|
||||
add_library( date-tz )
|
||||
target_compile_definitions( date-tz PRIVATE BUILD_TZ_LIB=1 )
|
||||
target_sources( date-tz
|
||||
PUBLIC
|
||||
$<BUILD_INTERFACE:${CMAKE_CURRENT_LIST_DIR}/include>$<INSTALL_INTERFACE:${CMAKE_INSTALL_INCLUDEDIR}>/date/tz.h
|
||||
|
@ -139,10 +139,12 @@ namespace date
|
||||
|
||||
enum class choose {earliest, latest};
|
||||
|
||||
#if defined(ANDROID) || defined(__ANDROID__)
|
||||
#if defined(BUILD_TZ_LIB)
|
||||
# if defined(ANDROID) || defined(__ANDROID__)
|
||||
struct tzdb;
|
||||
static std::unique_ptr<tzdb> init_tzdb();
|
||||
#endif // defined(ANDROID) || defined(__ANDROID__)
|
||||
# endif // defined(ANDROID) || defined(__ANDROID__)
|
||||
#endif // defined(BUILD_TZ_LIB)
|
||||
|
||||
namespace detail
|
||||
{
|
||||
@ -827,9 +829,11 @@ public:
|
||||
#if !USE_OS_TZDB
|
||||
DATE_API void add(const std::string& s);
|
||||
#else
|
||||
#if defined(ANDROID) || defined(__ANDROID__)
|
||||
# if defined(BUILD_TZ_LIB)
|
||||
# if defined(ANDROID) || defined(__ANDROID__)
|
||||
friend std::unique_ptr<tzdb> init_tzdb();
|
||||
#endif // defined(ANDROID) || defined(__ANDROID__)
|
||||
# endif // defined(ANDROID) || defined(__ANDROID__)
|
||||
# endif // defined(BUILD_TZ_LIB)
|
||||
#endif // !USE_OS_TZDB
|
||||
|
||||
private:
|
||||
|
Loading…
x
Reference in New Issue
Block a user