changeset 84:d3f1051ae5e0

misc: remove export files, closes #1656
author David Demelier <markand@malikania.fr>
date Thu, 02 May 2019 13:55:56 +0200
parents 6355e45750bc
children 5b411d614878
files cmake/MarkerDefineRenderer.cmake libmarker-bulma/CMakeLists.txt libmarker-bulma/marker/bulma_renderer.hpp libmarker-dump/CMakeLists.txt libmarker-dump/marker/dump_export.hpp libmarker-dump/marker/dump_renderer.hpp libmarker-html/CMakeLists.txt libmarker-html/marker/html_export.hpp libmarker-html/marker/html_renderer.hpp libmarker-man/CMakeLists.txt libmarker-man/marker/man_export.hpp libmarker-man/marker/man_renderer.hpp libmarker/CMakeLists.txt libmarker/marker/export.hpp.in libmarker/marker/renderer.hpp libmarker/marker/unicode.hpp
diffstat 16 files changed, 28 insertions(+), 185 deletions(-) [+]
line wrap: on
line diff
--- a/cmake/MarkerDefineRenderer.cmake	Fri Dec 07 21:13:03 2018 +0100
+++ b/cmake/MarkerDefineRenderer.cmake	Thu May 02 13:55:56 2019 +0200
@@ -40,6 +40,7 @@
 			PREFIX ""
 			IMPORT_PREFIX ""
 			FOLDER "renderers"
+			WINDOWS_EXPORT_ALL_SYMBOLS On
 			RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin
 			${RDR_PROPERTIES}
 	)
--- a/libmarker-bulma/CMakeLists.txt	Fri Dec 07 21:13:03 2018 +0100
+++ b/libmarker-bulma/CMakeLists.txt	Thu May 02 13:55:56 2019 +0200
@@ -20,14 +20,12 @@
 
 set(
 	SOURCES
-	${PROJECT_SOURCE_DIR}/marker/bulma_export.hpp
 	${PROJECT_SOURCE_DIR}/marker/bulma_renderer.cpp
 	${PROJECT_SOURCE_DIR}/marker/bulma_renderer.hpp
 )
 
 marker_define_renderer(
 	NAME libmarker-bulma
-	PROPERTIES DEFINE_SYMBOL MARKER_BULMA_BUILDING
 	SOURCES ${SOURCES}
 	LIBRARIES libmarker-html
 	HEADERS ${PROJECT_SOURCE_DIR}/marker/
--- a/libmarker-bulma/marker/bulma_renderer.hpp	Fri Dec 07 21:13:03 2018 +0100
+++ b/libmarker-bulma/marker/bulma_renderer.hpp	Thu May 02 13:55:56 2019 +0200
@@ -26,14 +26,12 @@
 
 #include <marker/html_renderer.hpp>
 
-#include "bulma_export.hpp"
-
 namespace marker {
 
 /**
  * \brief Bulma.io renderer.
  */
-class MARKER_BULMA_EXPORT bulma_renderer : public html_renderer {
+class bulma_renderer : public html_renderer {
 public:
 	/**
 	 * \copydoc renderer::header
--- a/libmarker-dump/CMakeLists.txt	Fri Dec 07 21:13:03 2018 +0100
+++ b/libmarker-dump/CMakeLists.txt	Thu May 02 13:55:56 2019 +0200
@@ -20,14 +20,12 @@
 
 set(
 	SOURCES
-	${PROJECT_SOURCE_DIR}/marker/dump_export.hpp
 	${PROJECT_SOURCE_DIR}/marker/dump_renderer.cpp
 	${PROJECT_SOURCE_DIR}/marker/dump_renderer.hpp
 )
 
 marker_define_renderer(
 	NAME libmarker-dump
-	PROPERTIES DEFINE_SYMBOL MARKER_DUMP_BUILDING
 	SOURCES ${SOURCES}
 	LIBRARIES libmarker
 	HEADERS ${PROJECT_SOURCE_DIR}/marker/
--- a/libmarker-dump/marker/dump_export.hpp	Fri Dec 07 21:13:03 2018 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,30 +0,0 @@
-/*
- * dump_export.hpp -- dump export file
- *
- * Copyright (c) 2018 David Demelier <markand@malikania.fr>
- *
- * Permission to use, copy, modify, and/or distribute this software for any
- * purpose with or without fee is hereby granted, provided that the above
- * copyright notice and this permission notice appear in all copies.
- *
- * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
- * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
- * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
- * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
- * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
- * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
- * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
- */
-
-#ifndef MARKER_DUMP_EXPORT_HPP
-#define MARKER_DUMP_EXPORT_HPP
-
-#include <boost/config.hpp>
-
-#if defined(MARKER_DUMP_BUILDING)
-#	define MARKER_DUMP_EXPORT BOOST_SYMBOL_EXPORT
-#else
-#	define MARKER_DUMP_EXPORT BOOST_SYMBOL_IMPORT
-#endif
-
-#endif // MARKER_DUMP_EXPORT_HPP
--- a/libmarker-dump/marker/dump_renderer.hpp	Fri Dec 07 21:13:03 2018 +0100
+++ b/libmarker-dump/marker/dump_renderer.hpp	Thu May 02 13:55:56 2019 +0200
@@ -26,14 +26,12 @@
 
 #include <marker/renderer.hpp>
 
-#include "dump_export.hpp"
-
 namespace marker {
 
 /**
  * \brief Debug output renderer.
  */
-class MARKER_DUMP_EXPORT dump_renderer : public renderer {
+class dump_renderer : public renderer {
 public:
 	/**
 	 * \copydoc renderer::alert
--- a/libmarker-html/CMakeLists.txt	Fri Dec 07 21:13:03 2018 +0100
+++ b/libmarker-html/CMakeLists.txt	Thu May 02 13:55:56 2019 +0200
@@ -20,14 +20,12 @@
 
 set(
 	SOURCES
-	${PROJECT_SOURCE_DIR}/marker/html_export.hpp
 	${PROJECT_SOURCE_DIR}/marker/html_renderer.cpp
 	${PROJECT_SOURCE_DIR}/marker/html_renderer.hpp
 )
 
 marker_define_renderer(
 	NAME libmarker-html
-	PROPERTIES DEFINE_SYMBOL MARKER_HTML_BUILDING
 	SOURCES ${SOURCES}
 	LIBRARIES libmarker libhoedown
 	HEADERS ${PROJECT_SOURCE_DIR}/marker/
--- a/libmarker-html/marker/html_export.hpp	Fri Dec 07 21:13:03 2018 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,30 +0,0 @@
-/*
- * html_export.hpp -- html export file
- *
- * Copyright (c) 2018 David Demelier <markand@malikania.fr>
- *
- * Permission to use, copy, modify, and/or distribute this software for any
- * purpose with or without fee is hereby granted, provided that the above
- * copyright notice and this permission notice appear in all copies.
- *
- * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
- * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
- * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
- * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
- * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
- * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
- * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
- */
-
-#ifndef MARKER_HTML_EXPORT_HPP
-#define MARKER_HTML_EXPORT_HPP
-
-#include <boost/config.hpp>
-
-#if defined(MARKER_HTML_BUILDING)
-#	define MARKER_HTML_EXPORT BOOST_SYMBOL_EXPORT
-#else
-#	define MARKER_HTML_EXPORT BOOST_SYMBOL_IMPORT
-#endif
-
-#endif // MARKER_HTML_EXPORT_HPP
--- a/libmarker-html/marker/html_renderer.hpp	Fri Dec 07 21:13:03 2018 +0100
+++ b/libmarker-html/marker/html_renderer.hpp	Thu May 02 13:55:56 2019 +0200
@@ -26,14 +26,12 @@
 
 #include <marker/renderer.hpp>
 
-#include "html_export.hpp"
-
 namespace marker {
 
 /**
  * \brief Simple HTML5 writer.
  */
-class MARKER_HTML_EXPORT html_renderer : public renderer {
+class html_renderer : public renderer {
 public:
 	/**
 	 * Escape a reference link.
--- a/libmarker-man/CMakeLists.txt	Fri Dec 07 21:13:03 2018 +0100
+++ b/libmarker-man/CMakeLists.txt	Thu May 02 13:55:56 2019 +0200
@@ -20,14 +20,12 @@
 
 set(
 	SOURCES
-	${PROJECT_SOURCE_DIR}/marker/man_export.hpp
 	${PROJECT_SOURCE_DIR}/marker/man_renderer.cpp
 	${PROJECT_SOURCE_DIR}/marker/man_renderer.hpp
 )
 
 marker_define_renderer(
 	NAME libmarker-man
-	PROPERTIES DEFINE_SYMBOL MARKER_MAN_BUILDING
 	SOURCES ${SOURCES}
 	LIBRARIES libmarker
 	HEADERS ${PROJECT_SOURCE_DIR}/marker/
--- a/libmarker-man/marker/man_export.hpp	Fri Dec 07 21:13:03 2018 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,30 +0,0 @@
-/*
- * man_export.hpp -- man export file
- *
- * Copyright (c) 2018 David Demelier <markand@malikania.fr>
- *
- * Permission to use, copy, modify, and/or distribute this software for any
- * purpose with or without fee is hereby granted, provided that the above
- * copyright notice and this permission notice appear in all copies.
- *
- * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
- * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
- * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
- * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
- * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
- * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
- * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
- */
-
-#ifndef MARKER_MAN_EXPORT_HPP
-#define MARKER_MAN_EXPORT_HPP
-
-#include <boost/config.hpp>
-
-#if defined(MARKER_MAN_BUILDING)
-#	define MARKER_MAN_EXPORT BOOST_SYMBOL_EXPORT
-#else
-#	define MARKER_MAN_EXPORT BOOST_SYMBOL_IMPORT
-#endif
-
-#endif // MARKER_MAN_EXPORT_HPP
--- a/libmarker-man/marker/man_renderer.hpp	Fri Dec 07 21:13:03 2018 +0100
+++ b/libmarker-man/marker/man_renderer.hpp	Thu May 02 13:55:56 2019 +0200
@@ -26,14 +26,12 @@
 
 #include <marker/renderer.hpp>
 
-#include "man_export.hpp"
-
 namespace marker {
 
 /**
  * \brief Simple man writer.
  */
-class MARKER_MAN_EXPORT man_renderer : public renderer {
+class man_renderer : public renderer {
 private:
 	unsigned table_current_cell_{0U};
 	unsigned table_max_cells_{0U};
--- a/libmarker/CMakeLists.txt	Fri Dec 07 21:13:03 2018 +0100
+++ b/libmarker/CMakeLists.txt	Thu May 02 13:55:56 2019 +0200
@@ -18,19 +18,8 @@
 
 project(libmarker)
 
-if (BUILD_SHARED_LIBS)
-	set(MARKER_SHARED On)
-endif ()
-
-configure_file(
-	${libmarker_SOURCE_DIR}/marker/export.hpp.in
-	${libmarker_BINARY_DIR}/marker/export.hpp
-)
-
 set(
 	SOURCES
-	${libmarker_BINARY_DIR}/marker/export.hpp
-	${libmarker_SOURCE_DIR}/marker/export.hpp.in
 	${libmarker_SOURCE_DIR}/marker/renderer.cpp
 	${libmarker_SOURCE_DIR}/marker/renderer.hpp
 	${libmarker_SOURCE_DIR}/marker/unicode.cpp
@@ -44,10 +33,10 @@
 	PROPERTIES
 		PREFIX ""
 		IMPORT_PREFIX ""
-		DEFINE_SYMBOL MARKER_BUILDING
 		VERSION ${MARKER_VERSION}
 		SOVERSION ${MARKER_VERSION_SHLIB}
 		INSTALL_RPATH "$ORIGIN/marker"
+		WINDOWS_EXPORT_ALL_SYMBOLS On
 		RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin
 )
 
@@ -81,7 +70,6 @@
 
 install(
 	FILES
-		${libmarker_BINARY_DIR}/marker/export.hpp
 		${libmarker_SOURCE_DIR}/marker/renderer.hpp
 		${libmarker_SOURCE_DIR}/marker/unicode.hpp
 	COMPONENT Devel
--- a/libmarker/marker/export.hpp.in	Fri Dec 07 21:13:03 2018 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,36 +0,0 @@
-/*
- * bulma_export.hpp -- bulma.io export file
- *
- * Copyright (c) 2018 David Demelier <markand@malikania.fr>
- *
- * Permission to use, copy, modify, and/or distribute this software for any
- * purpose with or without fee is hereby granted, provided that the above
- * copyright notice and this permission notice appear in all copies.
- *
- * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
- * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
- * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
- * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
- * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
- * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
- * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
- */
-
-#ifndef MARKER_EXPORT_HPP
-#define MARKER_EXPORT_HPP
-
-#include <boost/config.hpp>
-
-#cmakedefine MARKER_SHARED
-
-#if defined(MARKER_SHARED)
-#	if defined(MARKER_BUILDING)
-#		define MARKER_EXPORT BOOST_SYMBOL_EXPORT
-#	else
-#		define MARKER_EXPORT BOOST_SYMBOL_IMPORT
-#	endif
-#else
-#	define MARKER_EXPORT
-#endif
-
-#endif // MARKER_EXPORT_HPP
--- a/libmarker/marker/renderer.hpp	Fri Dec 07 21:13:03 2018 +0100
+++ b/libmarker/marker/renderer.hpp	Thu May 02 13:55:56 2019 +0200
@@ -27,8 +27,6 @@
 #include <map>
 #include <string>
 
-#include "export.hpp"
-
 /**
  * The marker namespace.
  */
@@ -51,7 +49,7 @@
  * 3. Call metadata to create optionally extra variable to substitude in the
  *    final document.
  */
-class MARKER_EXPORT renderer {
+class renderer {
 public:
 	/**
 	 * \brief Which kind of list.
@@ -909,7 +907,7 @@
  * \param input
  * \return the cleaned input
  */
-MARKER_EXPORT auto noeol(std::string input) noexcept -> std::string;
+auto noeol(std::string input) noexcept -> std::string;
 
 // }}}
 
--- a/libmarker/marker/unicode.hpp	Fri Dec 07 21:13:03 2018 +0100
+++ b/libmarker/marker/unicode.hpp	Thu May 02 13:55:56 2019 +0200
@@ -30,8 +30,6 @@
 #include <string>
 #include <string_view>
 
-#include "export.hpp"
-
 /**
  * \brief Unicode namespace.
  */
@@ -43,7 +41,7 @@
  * \param point the unicode code point
  * \param res the output buffer
  */
-MARKER_EXPORT void encode(char32_t point, char res[5]) noexcept;
+void encode(char32_t point, char res[5]) noexcept;
 
 /**
  * Decode the multibyte buffer into an unicode code point.
@@ -51,7 +49,7 @@
  * \param c the code point destination
  * \param res the multibyte string.
  */
-MARKER_EXPORT void decode(char32_t& c, const char* res) noexcept;
+void decode(char32_t& c, const char* res) noexcept;
 
 /**
  * Get the number of bytes for the first multi byte character from a
@@ -63,7 +61,7 @@
  * \param c the first multi byte character
  * \return the number of bytes [1-4] or -1 if invalid
  */
-MARKER_EXPORT auto nbytes_utf8(char c) noexcept -> int;
+auto nbytes_utf8(char c) noexcept -> int;
 
 /**
  * Get the number of bytes for the unicode point.
@@ -71,7 +69,7 @@
  * \param point the unicode point
  * \return the number of bytes [1-4] or -1 if invalid
  */
-MARKER_EXPORT auto nbytes_point(char32_t point) noexcept -> int;
+auto nbytes_point(char32_t point) noexcept -> int;
 
 /**
  * Get real number of character in a string.
@@ -80,7 +78,7 @@
  * \return the length
  * \throw std::invalid_argument on invalid sequence
  */
-MARKER_EXPORT auto length(std::string_view str) -> unsigned;
+auto length(std::string_view str) -> unsigned;
 
 /**
  * Iterate over all real characters in the UTF-8 string.
@@ -116,7 +114,7 @@
  * \return the UTF-8 string
  * \throw std::invalid_argument on invalid sequence
  */
-MARKER_EXPORT auto to_utf8(std::u32string_view array) -> std::string;
+auto to_utf8(std::u32string_view array) -> std::string;
 
 /**
  * Convert a UTF-8 string to UTF-32 string.
@@ -125,7 +123,7 @@
  * \return the UTF-32 string
  * \throw std::invalid_argument on invalid sequence
  */
-MARKER_EXPORT auto to_utf32(std::string_view str) -> std::u32string;
+auto to_utf32(std::string_view str) -> std::u32string;
 
 /**
  * Check if the unicode character is space.
@@ -133,7 +131,7 @@
  * \param c the character
  * \return true if space
  */
-MARKER_EXPORT auto isspace(char32_t c) noexcept -> bool;
+auto isspace(char32_t c) noexcept -> bool;
 
 /**
  * Check if the unicode character is digit.
@@ -141,7 +139,7 @@
  * \param c the character
  * \return true if digit
  */
-MARKER_EXPORT auto isdigit(char32_t c) noexcept -> bool;
+auto isdigit(char32_t c) noexcept -> bool;
 
 /**
  * Check if the unicode character is alpha category.
@@ -149,7 +147,7 @@
  * \param c the character
  * \return true if alpha
  */
-MARKER_EXPORT auto isalpha(char32_t c) noexcept -> bool;
+auto isalpha(char32_t c) noexcept -> bool;
 
 /**
  * Check if the unicode character is upper case.
@@ -157,7 +155,7 @@
  * \param c the character
  * \return true if upper case
  */
-MARKER_EXPORT auto isupper(char32_t c) noexcept -> bool;
+auto isupper(char32_t c) noexcept -> bool;
 
 /**
  * Check if the unicode character is lower case.
@@ -165,7 +163,7 @@
  * \param c the character
  * \return true if lower case
  */
-MARKER_EXPORT auto islower(char32_t c) noexcept -> bool;
+auto islower(char32_t c) noexcept -> bool;
 
 /**
  * Check if the unicode character is title case.
@@ -173,7 +171,7 @@
  * \param c the character
  * \return true if title case
  */
-MARKER_EXPORT auto istitle(char32_t c) noexcept -> bool;
+auto istitle(char32_t c) noexcept -> bool;
 
 /**
  * Convert to upper case.
@@ -181,7 +179,7 @@
  * \param c the character
  * \return the upper case character
  */
-MARKER_EXPORT auto toupper(char32_t c) noexcept -> char32_t;
+auto toupper(char32_t c) noexcept -> char32_t;
 
 /**
  * Convert to lower case.
@@ -189,7 +187,7 @@
  * \param c the character
  * \return the lower case character
  */
-MARKER_EXPORT auto tolower(char32_t c) noexcept -> char32_t;
+auto tolower(char32_t c) noexcept -> char32_t;
 
 /**
  * Convert to title case.
@@ -197,7 +195,7 @@
  * \param c the character
  * \return the title case character
  */
-MARKER_EXPORT auto totitle(char32_t c) noexcept -> char32_t;
+auto totitle(char32_t c) noexcept -> char32_t;
 
 /**
  * Convert the UTF-32 string to upper case.
@@ -205,7 +203,7 @@
  * \param str the string
  * \return the upper case string
  */
-MARKER_EXPORT auto toupper(std::u32string_view str) -> std::u32string;
+auto toupper(std::u32string_view str) -> std::u32string;
 
 /**
  * Convert the UTF-8 string to upper case.
@@ -214,7 +212,7 @@
  * \return the upper case string
  * \warning very slow at the moment
  */
-MARKER_EXPORT auto toupper(std::string_view str) -> std::string;
+auto toupper(std::string_view str) -> std::string;
 
 /**
  * Convert the UTF-32 string to lower case.
@@ -222,7 +220,7 @@
  * \param str the string
  * \return the lower case string
  */
-MARKER_EXPORT auto tolower(std::u32string_view str) -> std::u32string;
+auto tolower(std::u32string_view str) -> std::u32string;
 
 /**
  * Convert the UTF-8 string to lower case.
@@ -231,7 +229,7 @@
  * \return the lower case string
  * \warning very slow at the moment
  */
-MARKER_EXPORT auto tolower(std::string_view str) -> std::string;
+auto tolower(std::string_view str) -> std::string;
 
 } // !marker::unicode