Разные правки

This commit is contained in:
Andrei Astafev 2020-04-23 12:11:03 +03:00
parent 8d9a5590d7
commit cde0cf76a7
11 changed files with 29 additions and 20 deletions

View File

@ -2,4 +2,4 @@
#error Define MYXLIB_BUILD_LIBRARIES to compile this file. #error Define MYXLIB_BUILD_LIBRARIES to compile this file.
#endif #endif
#include "config.hpp" #include <myx/base/config-inl.hpp>

View File

@ -5,9 +5,20 @@
#ifdef MYXLIB_BUILD_LIBRARIES #ifdef MYXLIB_BUILD_LIBRARIES
#undef MYXLIB_HEADER_ONLY #undef MYXLIB_HEADER_ONLY
#if defined( _WIN32 ) && defined( MYXLIB_SHARED_LIB )
#ifdef myxlib_EXPORTS
#define MYXLIB_API __declspec( dllexport )
#else
#define MYXLIB_API __declspec( dllimport )
#endif
#else
#define MYXLIB_API
#endif
#define MYXLIB_INLINE inline #define MYXLIB_INLINE inline
#else #else
#define MYXLIB_HEADER_ONLY #define MYXLIB_HEADER_ONLY
#define MYXLIB_API
#define MYXLIB_INLINE inline #define MYXLIB_INLINE inline
#endif #endif

View File

@ -48,4 +48,4 @@ MYXLIB_INLINE bool almost_equal_relative( const double a, const double b,
} // namespace myx } // namespace myx
#endif #endif // ifndef MYX_MATH_ALMOST_EQUAL_RELATIVE_INL_HPP_

View File

@ -62,4 +62,4 @@ MYXLIB_INLINE bool almost_equal_relative_and_abs( const double a, const double b
} // namespace myx } // namespace myx
#endif #endif // ifndef MYX_MATH_ALMOST_EQUAL_RELATIVE_AND_ABS_INL_HPP_

View File

@ -90,4 +90,4 @@ MYXLIB_INLINE bool almost_equal_ulps( const double a, const double b,
} // namespace myx } // namespace myx
#endif #endif // ifndef MYX_MATH_ALMOST_EQUAL_ULPS_INL_HPP_

View File

@ -84,4 +84,4 @@ MYXLIB_INLINE bool almost_equal_ulps_and_abs( const double a, const double b,
} // namespace myx } // namespace myx
#endif #endif // ifndef MYX_MATH_ALMOST_EQUAL_ULPS_INL_HPP_

View File

@ -15,4 +15,4 @@ namespace math {
} // namespace myx } // namespace myx
#endif #endif // ifndef MYX_MATH_CONSTANTS_INL_HPP_

View File

@ -12,7 +12,7 @@ namespace myx {
namespace math { namespace math {
const auto ImpedanceOfFreeSpace = (M_PI * 119.9169832); const auto ImpedanceOfFreeSpace = ( M_PI * 119.9169832 );
} // namespace math } // namespace math

View File

@ -3,10 +3,8 @@ set(TRGT qt)
# cmake-format: off # cmake-format: off
# Список файлов исходных текстов # Список файлов исходных текстов
if(NOT MYXLIB_HEADER_ONLY)
set(TRGT_cpp set(TRGT_cpp
${CMAKE_CURRENT_SOURCE_DIR}/translators.cpp) ${CMAKE_CURRENT_SOURCE_DIR}/translators.cpp)
endif()
# Список заголовочных файлов (используется для установки) # Список заголовочных файлов (используется для установки)
set(TRGT_hpp set(TRGT_hpp

View File

@ -3,12 +3,12 @@
#pragma once #pragma once
#include <myx/base/config.hpp>
#ifndef MYXLIB_HEADER_ONLY #ifndef MYXLIB_HEADER_ONLY
#include <myx/qt/translators.hpp> #include <myx/qt/translators.hpp>
#endif #endif
#include <myx/base/config.hpp>
#include <QCoreApplication> #include <QCoreApplication>
#include <QLibraryInfo> #include <QLibraryInfo>
#include <QLocale> #include <QLocale>

View File

@ -2,4 +2,4 @@
#error Define MYXLIB_BUILD_LIBRARIES to compile this file. #error Define MYXLIB_BUILD_LIBRARIES to compile this file.
#endif #endif
#include <myx/qt/translators.hpp> #include <myx/qt/translators-inl.hpp>