commit
fe3efcd035
|
@ -103,6 +103,27 @@ set( CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${WARNING_FLAGS} ${MSVC_FLAGS} -D_REENTRANT
|
|||
set( CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${WARNING_FLAGS} ${MSVC_FLAGS} -D_REENTRANT" )
|
||||
set( CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} ${MSVC_LD_FLAGS}" )
|
||||
|
||||
# option to use static windows runtime - maybe only applies to WIN32/MSVC
|
||||
if (MSVC)
|
||||
option( USE_STATIC_RUNTIME "Set ON to change /MD(DLL) to /MT(static)" OFF )
|
||||
if (USE_STATIC_RUNTIME)
|
||||
set(CompilerFlags
|
||||
CMAKE_CXX_FLAGS
|
||||
CMAKE_CXX_FLAGS_DEBUG
|
||||
CMAKE_CXX_FLAGS_RELEASE
|
||||
CMAKE_C_FLAGS
|
||||
CMAKE_C_FLAGS_DEBUG
|
||||
CMAKE_C_FLAGS_RELEASE
|
||||
)
|
||||
foreach(CompilerFlag ${CompilerFlags})
|
||||
string(REPLACE "/MD" "/MT" ${CompilerFlag} "${${CompilerFlag}}")
|
||||
endforeach()
|
||||
message(STATUS "Using /MT STATIC runtime")
|
||||
else ()
|
||||
message(STATUS "Using /MD DYNAMIC runtime")
|
||||
endif ()
|
||||
endif ()
|
||||
|
||||
add_definitions ( -DHAVE_CONFIG_H )
|
||||
add_definitions ( -DSUPPORT_UTF16_ENCODINGS=1 )
|
||||
add_definitions ( -DSUPPORT_ASIAN_ENCODINGS=1 )
|
||||
|
@ -313,14 +334,28 @@ if (UNIX AND SUPPORT_CONSOLE_APP)
|
|||
endif ()
|
||||
endif ()
|
||||
|
||||
##########################################################
|
||||
### Create MSI,EXE, DMG, DEB/RPM
|
||||
### TODO: Check each of these builds
|
||||
##########################################################
|
||||
set(BITNESS 32)
|
||||
if(CMAKE_SIZEOF_VOID_P EQUAL 8)
|
||||
set(BITNESS 64)
|
||||
endif()
|
||||
|
||||
##########################################################
|
||||
### Create MSI,EXE, DMG, DEB/RPM
|
||||
### TODO: Check each of these builds
|
||||
##########################################################
|
||||
# Need to ensure that system dlls get included in a binary distribution
|
||||
# But since it can miss some... seems incomplete, make optionional
|
||||
option( ADD_SYSTEM_RUNTIMES "Set ON to include system runtime DLLS in distribution" OFF )
|
||||
if (MSVC AND ADD_SYSTEM_RUNTIMES)
|
||||
if (NOT DEFINED CMAKE_INSTALL_SYSTEM_RUNTIME_LIBS_NO_WARNINGS)
|
||||
# Visual Studio Express does include redistributable components so
|
||||
# squelch the warning.
|
||||
set (CMAKE_INSTALL_SYSTEM_RUNTIME_LIBS_NO_WARNINGS ON)
|
||||
endif ()
|
||||
set (CMAKE_INSTALL_DEBUG_LIBRARIES OFF)
|
||||
include (InstallRequiredSystemLibraries)
|
||||
endif ()
|
||||
##########################################################
|
||||
if (WIN32)
|
||||
# MSI - this needs WiX Tooset installed and a path to candle.exe
|
||||
# EXE - this needs NSIS tools to be in path
|
||||
|
@ -345,8 +380,8 @@ set(CPACK_PACKAGE_VERSION_MAJOR "${TIDY_MAJOR_VERSION}")
|
|||
set(CPACK_PACKAGE_VERSION_MINOR "${TIDY_MINOR_VERSION}")
|
||||
set(CPACK_PACKAGE_VERSION_PATCH "${TIDY_POINT_VERSION}")
|
||||
set(CPACK_PACKAGE_DESCRIPTION_FILE "${CMAKE_CURRENT_SOURCE_DIR}/README/README.html")
|
||||
|
||||
set(CPACK_RESOURCE_FILE_LICENSE "${CMAKE_CURRENT_SOURCE_DIR}/README/LICENSE.md")
|
||||
# use one compatible license file for all
|
||||
set(CPACK_RESOURCE_FILE_LICENSE "${CMAKE_CURRENT_SOURCE_DIR}/README/LICENSE.txt")
|
||||
set(CPACK_RESOURCE_FILE_README "${CMAKE_CURRENT_SOURCE_DIR}/README/README.html")
|
||||
set(CPACK_RESOURCE_FILE_WELCOME "${CMAKE_CURRENT_SOURCE_DIR}/README/README.html")
|
||||
|
||||
|
@ -355,6 +390,9 @@ set(CPACK_DEBIAN_PACKAGE_MAINTAINER ${CPACK_PACKAGE_CONTACT})
|
|||
set(CPACK_DEBIAN_PACKAGE_HOMEPAGE "http://www.html-tidy.org/")
|
||||
#set(CPACK_DEBIAN_PACKAGE_DEPENDS "libc")
|
||||
set(CPACK_DEBIAN_PACKAGE_SECTION "Libraries")
|
||||
set(CPACK_SOURCE_IGNORE_FILES
|
||||
"${PROJECT_SOURCE_DIR}/build"
|
||||
)
|
||||
|
||||
## RPM config
|
||||
set(CPACK_RPM_EXCLUDE_FROM_AUTO_FILELIST_ADDITION "/usr/share/man" "/usr/share/man/man1")
|
||||
|
|
50
README/LICENSE.txt
Normal file
50
README/LICENSE.txt
Normal file
|
@ -0,0 +1,50 @@
|
|||
# HTML Tidy
|
||||
|
||||
## HTML parser and pretty printer
|
||||
|
||||
Copyright (c) 1998-2016 World Wide Web Consortium
|
||||
(Massachusetts Institute of Technology, European Research
|
||||
Consortium for Informatics and Mathematics, Keio University).
|
||||
All Rights Reserved.
|
||||
|
||||
Additional contributions (c) 2001-2016 University of Toronto, Terry Teague,
|
||||
@geoffmcl, HTACG, and others.
|
||||
|
||||
### Contributing Author(s):
|
||||
|
||||
Dave Raggett <dsr@w3.org>
|
||||
|
||||
The contributing author(s) would like to thank all those who
|
||||
helped with testing, bug fixes and suggestions for improvements.
|
||||
This wouldn't have been possible without your help.
|
||||
|
||||
## COPYRIGHT NOTICE:
|
||||
|
||||
This software and documentation is provided "as is," and
|
||||
the copyright holders and contributing author(s) make no
|
||||
representations or warranties, express or implied, including
|
||||
but not limited to, warranties of merchantability or fitness
|
||||
for any particular purpose or that the use of the software or
|
||||
documentation will not infringe any third party patents,
|
||||
copyrights, trademarks or other rights.
|
||||
|
||||
The copyright holders and contributing author(s) will not be held
|
||||
liable for any direct, indirect, special or consequential damages
|
||||
arising out of any use of the software or documentation, even if
|
||||
advised of the possibility of such damage.
|
||||
|
||||
Permission is hereby granted to use, copy, modify, and distribute
|
||||
this source code, or portions hereof, documentation and executables,
|
||||
for any purpose, without fee, subject to the following restrictions:
|
||||
|
||||
1. The origin of this source code must not be misrepresented.
|
||||
2. Altered versions must be plainly marked as such and must
|
||||
not be misrepresented as being the original source.
|
||||
3. This Copyright notice may not be removed or altered from any
|
||||
source or altered source distribution.
|
||||
|
||||
The copyright holders and contributing author(s) specifically
|
||||
permit, without fee, and encourage the use of this source code
|
||||
as a component for supporting the Hypertext Markup Language in
|
||||
commercial products. If you use this source code in a product,
|
||||
acknowledgement is not required but would be appreciated.
|
Loading…
Reference in a new issue