1
- # Copyright (c) 2015, 2018 , Oracle and/or its affiliates. All rights reserved.
1
+ # Copyright (c) 2015, 2019 , Oracle and/or its affiliates. All rights reserved.
2
2
#
3
3
# This program is free software; you can redistribute it and/or modify
4
4
# it under the terms of the GNU General Public License, version 2.0, as
@@ -122,12 +122,11 @@ if(APPLE AND NOT CMAKE_CXX_COMPILER_ID MATCHES "Clang")
122
122
message (FATAL_ERROR "To create packages for OSX, build with clang compiler." )
123
123
endif ()
124
124
125
+
125
126
# ======================================================================
126
127
# Licenses for binary packages
127
128
# ======================================================================
128
129
129
- #if (0)
130
-
131
130
if (EXISTS "${CMAKE_SOURCE_DIR} /LICENSE.mysql.txt" )
132
131
set (LIC_FILE "LICENSE.mysql" ) # Without ".txt" extension
133
132
else ()
@@ -142,34 +141,22 @@ else()
142
141
set (newline UNIX )
143
142
endif ()
144
143
145
-
146
- if (EXISTS "${CMAKE_SOURCE_DIR} /README.txt" )
147
- set (info_files README ${LIC_FILE} )
148
- set (CPACK_RESOURCE_FILE_README "README${info_ext} " )
149
- else ()
150
- set (info_files README.md CONTRIBUTING.md ${LIC_FILE} )
151
- set (CPACK_RESOURCE_FILE_README "README.md" )
152
- endif ()
144
+ set (info_files README ${LIC_FILE} )
153
145
154
146
foreach (file ${info_files} )
155
- if (${file} MATCHES "[.]*\\ .md" )
156
- set (file_src "${CMAKE_SOURCE_DIR} /${file} " )
157
- set (file_bin "${CMAKE_BINARY_DIR} /${file} " )
158
- else ()
159
- set (file_src "${CMAKE_SOURCE_DIR} /${file} .txt" )
160
- set (file_bin "${CMAKE_BINARY_DIR} /${file}${info_ext} " )
161
- endif ()
147
+
148
+ set (file_src "${CMAKE_SOURCE_DIR} /${file} .txt" )
149
+ set (file_bin "${CMAKE_BINARY_DIR} /${file}${info_ext} " )
162
150
163
151
configure_file ("${file_src} " "${file_bin} " NEWLINE_STYLE ${newline} )
164
152
install (FILES "${file_bin} " DESTINATION ${INSTALL_DOC_DIR} COMPONENT Readme )
165
- message ("Installing README files: ${file_bin} " )
166
153
167
154
endforeach ()
168
155
156
+ set (CPACK_RESOURCE_FILE_README "README${info_ext} " )
169
157
set (CPACK_RESOURCE_FILE_LICENSE "${LIC_FILE}${info_ext} " )
170
158
#set(CPACK_RESOURCE_FILE_INSTALL "...") # FIXME
171
159
172
- #endif()
173
160
174
161
# ======================================================================
175
162
# Specs for source package
0 commit comments