]> git.pld-linux.org Git - packages/plplot.git/blob - plplot-no-DISPLAY.patch
- gcc 7.2 rebuild
[packages/plplot.git] / plplot-no-DISPLAY.patch
1 --- plplot-5.11.1/cmake/modules/tcl-related.cmake.orig  2015-08-12 19:35:27.000000000 +0200
2 +++ plplot-5.11.1/cmake/modules/tcl-related.cmake       2016-03-10 21:56:04.514553220 +0100
3 @@ -265,45 +265,10 @@
4        message(STATUS "Looking for wish - found")
5        message(STATUS "TK_WISH = ${TK_WISH}")
6        if(NOT PLPLOT_TK_VERSION)
7 -       file(WRITE ${CMAKE_CURRENT_BINARY_DIR}/CheckTK_VERSION.tcl "puts -nonewline [package require Tk]; exit")
8 -       # Find Tk version via wish or fail.
9 -       execute_process(
10 -         COMMAND ${TK_WISH} ${CMAKE_CURRENT_BINARY_DIR}/CheckTK_VERSION.tcl
11 -         RESULT_VARIABLE TK_RC
12 -         OUTPUT_VARIABLE _plplot_tk_version
13 -         )
14 -       if(NOT TK_RC)
15 -         message(STATUS "Looking for Tk version with wish - found")
16 -         # Store result in cached variable so it will be remembered
17 -          # when cmake is re-run, but use type of STRING rather than
18 -          # INTERNAL to allow users to specify the value with a
19 -          # -DPLPLOT_TK_VERSION:STRING=<whatever> on the command
20 -          # line for those rare cases when "package require Tk"
21 -          # would error out due to some wish issue.
22 -         set(PLPLOT_TK_VERSION ${_plplot_tk_version}
23 +         set(PLPLOT_TK_VERSION ${PLPLOT_TCL_VERSION}
24             CACHE STRING "Tk version found by wish"
25             )
26  
27 -         if(PLPLOT_TCL_VERSION STREQUAL PLPLOT_TK_VERSION)
28 -           # Cross check that wish finds the same Tcl version as tclsh.
29 -           execute_process(
30 -             COMMAND ${TK_WISH} ${CMAKE_CURRENT_BINARY_DIR}/CheckTCL_VERSION.tcl
31 -             RESULT_VARIABLE TCL_RC
32 -             OUTPUT_VARIABLE _plplot_tcl_version
33 -             )
34 -
35 -           if(NOT TCL_RC AND _plplot_tcl_version STREQUAL PLPLOT_TCL_VERSION)
36 -             # Cross check that tclsh finds the same Tk version as wish.
37 -             execute_process(
38 -               COMMAND ${TCL_TCLSH} ${CMAKE_CURRENT_BINARY_DIR}/CheckTK_VERSION.tcl
39 -               RESULT_VARIABLE TK_RC
40 -               OUTPUT_VARIABLE _plplot_tk_version
41 -               )
42 -             if(NOT TK_RC AND _plplot_tk_version STREQUAL PLPLOT_TK_VERSION)
43 -               message(STATUS "Tcl and Tk versions found by both tclsh and wish are identical")
44 -               # Sanity checking of Tk version consistency _if_ a Tk
45 -               # version string can be extracted from the Tk library
46 -               # name.
47                 get_filename_component(library_name ${TK_LIBRARY} NAME)
48                 string(REGEX MATCH "[0-9]+[.]?[0-9]+" library_version ${library_name})
49                 if(library_version)
50 @@ -320,40 +285,6 @@
51     library name is not consistent with PLPLOT_TK_VERSION = ${PLPLOT_TK_VERSION}")
52                   endif(NOT truncated_version STREQUAL library_version)
53                 endif(library_version)
54 -             elseif(TK_RC)
55 -               message(STATUS "Looking for Tk version with tclsh - not found")
56 -               message(STATUS "WARNING: setting ENABLE_tk to OFF")
57 -               set(ENABLE_tk OFF CACHE BOOL "Enable Tk binding" FORCE)
58 -             else(NOT TK_RC AND _plplot_tk_version STREQUAL PLPLOT_TK_VERSION)
59 -               message(STATUS "Tk version = ${_plplot_tk_version} found by tclsh is not consistent with
60 -   Tk version = ${PLPLOT_TK_VERSION} found by wish"
61 -                 )
62 -               message(STATUS "WARNING: setting ENABLE_tk to OFF")
63 -               set(ENABLE_tk OFF CACHE BOOL "Enable Tk binding" FORCE)
64 -             endif(NOT TK_RC AND _plplot_tk_version STREQUAL PLPLOT_TK_VERSION)
65 -           elseif(TCL_RC)
66 -             message(STATUS "Looking for Tcl version with wish - not found")
67 -             message(STATUS "WARNING: setting ENABLE_tk to OFF")
68 -             set(ENABLE_tk OFF CACHE BOOL "Enable Tk binding" FORCE)
69 -           else(NOT TCL_RC AND _plplot_tcl_version STREQUAL PLPLOT_TCL_VERSION)
70 -             message(STATUS "Tcl version = ${_plplot_tcl_version} found by wish is not consistent with
71 -   Tcl version = ${PLPLOT_TCL_VERSION} found by tclsh"
72 -               )
73 -             message(STATUS "WARNING: setting ENABLE_tk to OFF")
74 -             set(ENABLE_tk OFF CACHE BOOL "Enable Tk binding" FORCE)
75 -           endif(NOT TCL_RC AND _plplot_tcl_version STREQUAL PLPLOT_TCL_VERSION)
76 -         else(PLPLOT_TCL_VERSION STREQUAL PLPLOT_TK_VERSION)
77 -           message(STATUS "Tk version = ${PLPLOT_TK_VERSION} found by wish is not consistent with
78 -   Tcl version = ${PLPLOT_TCL_VERSION} found by tclsh"
79 -             )
80 -           message(STATUS "WARNING: setting ENABLE_tk to OFF")
81 -           set(ENABLE_tk OFF CACHE BOOL "Enable Tk binding" FORCE)
82 -         endif(PLPLOT_TCL_VERSION STREQUAL PLPLOT_TK_VERSION)
83 -       else(NOT TK_RC)
84 -         message(STATUS "Looking for Tk version with wish - not found")
85 -         message(STATUS "WARNING: setting ENABLE_tk to OFF")
86 -         set(ENABLE_tk OFF CACHE BOOL "Enable Tk binding" FORCE)
87 -       endif(NOT TK_RC)
88        else(NOT PLPLOT_TK_VERSION)
89         set(TK_RC 0)
90        endif(NOT PLPLOT_TK_VERSION)
91 @@ -318,7 +318,7 @@
92        file(WRITE ${CMAKE_CURRENT_BINARY_DIR}/CheckITK_Available.tcl "puts -nonewline [package require Itk ${SUGGESTED_ITK_VERSION}]; exit")
93        # Refine SUGGESTED_ITK_VERSION to exact value or fail.
94        execute_process(
95 -       COMMAND ${TCL_TCLSH} ${CMAKE_CURRENT_BINARY_DIR}/CheckITK_Available.tcl
96 +       COMMAND ${TCL_TCLSH} ${CMAKE_CURRENT_LIST_DIR}/CheckTclPackage_Available.tcl itk ${SUGGESTED_ITK_VERSION}
97         RESULT_VARIABLE ITK_RC
98         OUTPUT_VARIABLE _plplot_itk_version
99         )
100 --- plplot-5.11.1/cmake/modules/CheckTclPackage_Available.tcl.orig      1970-01-01 01:00:00.000000000 +0100
101 +++ plplot-5.11.1/cmake/modules/CheckTclPackage_Available.tcl   2016-04-20 17:35:06.305618401 +0200
102 @@ -0,0 +1,11 @@
103 +catch {package require bogusPackageNameToScanAvailablePackages}
104 +
105 +set packageName [lindex $argv 0]
106 +set packageReq [lindex $argv 1]
107 +set matchingVersions {}
108 +foreach packageVersion [package versions $packageName] {
109 +       if [package vsatisfies $packageVersion $packageReq] { lappend matchingVersions $packageVersion }
110 +}
111 +
112 +puts [lindex [lsort -command {package vcompare} -decreasing $matchingVersions] 0]
113 +exit
This page took 0.085647 seconds and 3 git commands to generate.