]> git.proxmox.com Git - ceph.git/blob - ceph/src/jaegertracing/opentelemetry-cpp/tools/vcpkg/ports/gl2ps/separate-static-dynamic-build.patch
update ceph source to reef 18.1.2
[ceph.git] / ceph / src / jaegertracing / opentelemetry-cpp / tools / vcpkg / ports / gl2ps / separate-static-dynamic-build.patch
1 diff --git a/CMakeLists.txt b/CMakeLists.txt
2 index 0001c4f..36ec0f7 100644
3 --- a/CMakeLists.txt
4 +++ b/CMakeLists.txt
5 @@ -1,33 +1,41 @@
6 # GL2PS, an OpenGL to PostScript Printing Library
7 # Copyright (C) 1999-2017 C. Geuzaine
8 +
9 #
10 # This program is free software; you can redistribute it and/or
11 # modify it under the terms of either:
12 +
13 #
14 # a) the GNU Library General Public License as published by the Free
15 # Software Foundation, either version 2 of the License, or (at your
16 # option) any later version; or
17 +
18 #
19 # b) the GL2PS License as published by Christophe Geuzaine, either
20 # version 2 of the License, or (at your option) any later version.
21 +
22 #
23 # This program is distributed in the hope that it will be useful, but
24 # WITHOUT ANY WARRANTY; without even the implied warranty of
25 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See either
26 # the GNU Library General Public License or the GL2PS License for
27 # more details.
28 +
29 #
30 # You should have received a copy of the GNU Library General Public
31 # License along with this library in the file named "COPYING.LGPL";
32 # if not, write to the Free Software Foundation, Inc., 675 Mass Ave,
33 # Cambridge, MA 02139, USA.
34 +
35 #
36 # You should have received a copy of the GL2PS License with this
37 # library in the file named "COPYING.GL2PS"; if not, I will be glad
38 # to provide one.
39 +
40 #
41 # For the latest info about gl2ps and a full list of contributors,
42 # see http://www.geuz.org/gl2ps/.
43 +
44 #
45 # Please report all bugs and problems to <gl2ps@geuz.org>.
46
47 @@ -59,7 +67,7 @@ set(GL2PS_VERSION "${GL2PS_MAJOR_VERSION}.${GL2PS_MINOR_VERSION}")
48 set(GL2PS_VERSION "${GL2PS_VERSION}.${GL2PS_PATCH_VERSION}${GL2PS_EXTRA_VERSION}")
49
50 execute_process(COMMAND date "+%Y%m%d" OUTPUT_VARIABLE DATE
51 - OUTPUT_STRIP_TRAILING_WHITESPACE)
52 +OUTPUT_STRIP_TRAILING_WHITESPACE)
53 if(NOT DATE)
54 set(DATE "unknown")
55 endif()
56 @@ -138,30 +146,30 @@ if(APPLE)
57 endif()
58 endif()
59
60 -if(OPENGL_FOUND)
61 - add_library(lib STATIC gl2ps.c gl2ps.h)
62 - set_target_properties(lib PROPERTIES OUTPUT_NAME gl2ps)
63 -
64 - add_library(shared SHARED gl2ps.c gl2ps.h)
65 - target_link_libraries(shared ${EXTERNAL_LIBRARIES})
66 - set_target_properties(shared PROPERTIES OUTPUT_NAME gl2ps
67 - VERSION ${GL2PS_MAJOR_VERSION}.${GL2PS_MINOR_VERSION}.${GL2PS_PATCH_VERSION}
68 - SOVERSION ${GL2PS_MAJOR_VERSION})
69 - if(WIN32 OR CYGWIN)
70 - set_target_properties(shared PROPERTIES
71 - COMPILE_FLAGS "-DGL2PSDLL -DGL2PSDLL_EXPORTS")
72 - endif()
73 - install(TARGETS lib shared RUNTIME DESTINATION bin
74 - LIBRARY DESTINATION lib${LIB_SUFFIX}
75 - ARCHIVE DESTINATION lib${LIB_SUFFIX})
76 +add_library(gl2ps gl2ps.c gl2ps.h)
77 +target_link_libraries(gl2ps ${EXTERNAL_LIBRARIES})
78 +set_target_properties(gl2ps PROPERTIES
79 + VERSION ${GL2PS_MAJOR_VERSION}.${GL2PS_MINOR_VERSION}.${GL2PS_PATCH_VERSION}
80 +SOVERSION ${GL2PS_MAJOR_VERSION})
81 +
82 +if(BUILD_SHARED_LIBS)
83 + target_compile_definitions(gl2ps PRIVATE -DGL2PSDLL -DGL2PSDLL_EXPORTS)
84 endif()
85
86 +install(
87 + TARGETS gl2ps
88 + RUNTIME DESTINATION bin
89 + LIBRARY DESTINATION lib
90 + ARCHIVE DESTINATION lib
91 +)
92 +
93 if(WIN32)
94 - set(GL2PS_DOC .)
95 + set(GL2PS_DOC share/gl2ps/docs)
96 else()
97 set(GL2PS_DOC share/doc/gl2ps)
98 endif()
99
100 +if(NOT DISABLE_INSTALL_HEADERS)
101 install(FILES gl2ps.h DESTINATION include)
102 install(FILES ${CMAKE_SOURCE_DIR}/README.txt DESTINATION ${GL2PS_DOC})
103 install(FILES ${CMAKE_SOURCE_DIR}/COPYING.LGPL DESTINATION ${GL2PS_DOC})
104 @@ -169,30 +177,36 @@ install(FILES ${CMAKE_SOURCE_DIR}/COPYING.GL2PS DESTINATION ${GL2PS_DOC})
105 install(FILES ${CMAKE_SOURCE_DIR}/gl2psTest.c DESTINATION ${GL2PS_DOC})
106 install(FILES ${CMAKE_SOURCE_DIR}/gl2psTestSimple.c DESTINATION ${GL2PS_DOC})
107
108 -if(GLUT_FOUND)
109 - add_executable(gl2psTest WIN32 gl2psTest.c)
110 - target_link_libraries(gl2psTest lib ${EXTERNAL_LIBRARIES})
111 - add_executable(gl2psTestSimple WIN32 gl2psTestSimple.c)
112 - target_link_libraries(gl2psTestSimple lib ${EXTERNAL_LIBRARIES})
113 endif()
114
115 -find_package(LATEX)
116 -if(PDFLATEX_COMPILER)
117 - add_custom_command(OUTPUT gl2ps.pdf DEPENDS gl2ps.tex
118 - COMMAND ${PDFLATEX_COMPILER} ARGS ${CMAKE_SOURCE_DIR}/gl2ps.tex
119 - COMMAND ${PDFLATEX_COMPILER} ARGS ${CMAKE_SOURCE_DIR}/gl2ps.tex
120 - COMMAND ${PDFLATEX_COMPILER} ARGS ${CMAKE_SOURCE_DIR}/gl2ps.tex
121 - COMMAND ${CMAKE_COMMAND} -E copy gl2ps.pdf ${CMAKE_SOURCE_DIR})
122 - add_custom_target(pdf ALL DEPENDS gl2ps.pdf)
123 - install(FILES gl2ps.pdf DESTINATION ${GL2PS_DOC})
124 - find_program(TTH tth)
125 - if(TTH)
126 - add_custom_command(OUTPUT gl2ps.html DEPENDS gl2ps.tex gl2ps.pdf
127 - COMMAND ${CMAKE_COMMAND} -E copy_if_different
128 - ${CMAKE_SOURCE_DIR}/gl2ps.tex ${CMAKE_BINARY_DIR}/gl2ps.tex
129 - COMMAND ${TTH} ARGS -w1 gl2ps.tex)
130 - add_custom_target(html DEPENDS gl2ps.html)
131 - endif()
132 +if(BUILD_TESTS)
133 +
134 + if(GLUT_FOUND)
135 + add_executable(gl2psTest gl2psTest.c)
136 + target_link_libraries(gl2psTest gl2ps ${EXTERNAL_LIBRARIES})
137 + add_executable(gl2psTestSimple gl2psTestSimple.c)
138 + target_link_libraries(gl2psTestSimple gl2ps ${EXTERNAL_LIBRARIES})
139 + endif(GLUT_FOUND)
140 +
141 + find_package(LATEX)
142 + if(PDFLATEX_COMPILER)
143 + add_custom_command(OUTPUT gl2ps.pdf DEPENDS gl2ps.tex
144 + COMMAND ${PDFLATEX_COMPILER} ARGS ${CMAKE_SOURCE_DIR}/gl2ps.tex
145 + COMMAND ${PDFLATEX_COMPILER} ARGS ${CMAKE_SOURCE_DIR}/gl2ps.tex
146 + COMMAND ${PDFLATEX_COMPILER} ARGS ${CMAKE_SOURCE_DIR}/gl2ps.tex
147 + COMMAND ${CMAKE_COMMAND} -E copy gl2ps.pdf ${CMAKE_SOURCE_DIR})
148 + add_custom_target(pdf ALL DEPENDS gl2ps.pdf)
149 + install(FILES gl2ps.pdf DESTINATION ${GL2PS_DOC})
150 + find_program(TTH tth)
151 + if(TTH)
152 + add_custom_command(OUTPUT gl2ps.html DEPENDS gl2ps.tex gl2ps.pdf
153 + COMMAND ${CMAKE_COMMAND} -E copy_if_different
154 + ${CMAKE_SOURCE_DIR}/gl2ps.tex ${CMAKE_BINARY_DIR}/gl2ps.tex
155 + COMMAND ${TTH} ARGS -w1 gl2ps.tex)
156 + add_custom_target(html DEPENDS gl2ps.html)
157 + endif(TTH)
158 + endif(PDFLATEX_COMPILER)
159 +
160 endif()
161
162 set(CPACK_PACKAGE_VENDOR "Christophe Geuzaine")
163 @@ -201,27 +215,22 @@ set(CPACK_PACKAGE_VERSION_MINOR ${GL2PS_MINOR_VERSION})
164 set(CPACK_PACKAGE_VERSION_PATCH ${GL2PS_PATCH_VERSION})
165 set(CPACK_PACKAGE_DESCRIPTION_FILE ${CMAKE_SOURCE_DIR}/README.txt)
166 set(CPACK_PACKAGE_DESCRIPTION_SUMMARY
167 - "An OpenGL to PostScript (and PDF, and SVG...) printing library")
168 -if(GL2PS_EXTRA_VERSION MATCHES "-git.*") # so that we'll overwrite the archives
169 - set(CPACK_PACKAGE_FILE_NAME gl2ps-git-${GL2PS_OS})
170 - set(CPACK_SOURCE_PACKAGE_FILE_NAME gl2ps-git)
171 -else()
172 + "An OpenGL to PostScript (and PDF, and SVG...) printing library")
173 set(CPACK_PACKAGE_FILE_NAME gl2ps-${GL2PS_VERSION}-${GL2PS_OS})
174 - set(CPACK_SOURCE_PACKAGE_FILE_NAME gl2ps-${GL2PS_VERSION})
175 -endif()
176 -set(CPACK_PACKAGE_INSTALL_DIRECTORY "gl2ps")
177 -set(CPACK_RESOURCE_FILE_LICENSE ${CMAKE_SOURCE_DIR}/COPYING.LGPL)
178 -set(CPACK_RESOURCE_FILE_README ${CMAKE_SOURCE_DIR}/README.txt)
179 -set(CPACK_RESOURCE_FILE_WELCOME ${CMAKE_SOURCE_DIR}/README.txt)
180 -set(CPACK_PACKAGE_EXECUTABLE "gl2ps;gl2ps")
181 -set(CPACK_STRIP_FILES TRUE)
182 -set(CPACK_SOURCE_GENERATOR TGZ)
183 -set(CPACK_SOURCE_IGNORE_FILES "TODO.txt" "${CMAKE_BINARY_DIR}" "/CVS/"
184 - "/.svn" "/.git" "~$" "DS_Store$" "/tmp/" "/bin/" "/lib/")
185 -if(WIN32)
186 - set(CPACK_GENERATOR ZIP)
187 -else()
188 - set(CPACK_GENERATOR TGZ)
189 -endif()
190 -
191 -include(CPack)
192 + set(CPACK_PACKAGE_INSTALL_DIRECTORY "gl2ps")
193 + set(CPACK_RESOURCE_FILE_LICENSE ${CMAKE_SOURCE_DIR}/COPYING.LGPL)
194 + set(CPACK_RESOURCE_FILE_README ${CMAKE_SOURCE_DIR}/README.txt)
195 + set(CPACK_RESOURCE_FILE_WELCOME ${CMAKE_SOURCE_DIR}/README.txt)
196 + set(CPACK_PACKAGE_EXECUTABLE "gl2ps;gl2ps")
197 + set(CPACK_STRIP_FILES TRUE)
198 + set(CPACK_SOURCE_PACKAGE_FILE_NAME gl2ps-${GL2PS_VERSION}-source)
199 + set(CPACK_SOURCE_GENERATOR TGZ)
200 + set(CPACK_SOURCE_IGNORE_FILES "TODO.txt" "${CMAKE_BINARY_DIR}" "/CVS/"
201 + "/.svn" "~$" "DS_Store$" "/tmp/" "/bin/" "/lib/")
202 + if(WIN32)
203 + set(CPACK_GENERATOR ZIP)
204 + else(WIN32)
205 + set(CPACK_GENERATOR TGZ)
206 + endif(WIN32)
207 +
208 + # include(CPack)