@@ -2181,75 +2181,6 @@ def check_requirements(self):
2181
2181
return "cairocffi version %s" % cairocffi .version
2182
2182
2183
2183
2184
- class DviPng (SetupPackage ):
2185
- name = "dvipng"
2186
- optional = True
2187
-
2188
- def check (self ):
2189
- try :
2190
- output = check_output ('dvipng -version' , shell = True ,
2191
- stderr = subprocess .STDOUT )
2192
- return "version %s" % output .splitlines ()[1 ].decode ().split ()[- 1 ]
2193
- except (IndexError , ValueError , subprocess .CalledProcessError ):
2194
- raise CheckFailed ()
2195
-
2196
-
2197
- class Ghostscript (SetupPackage ):
2198
- name = "ghostscript"
2199
- optional = True
2200
-
2201
- def check (self ):
2202
- if sys .platform == 'win32' :
2203
- # mgs is the name in miktex
2204
- gs_execs = ['gswin32c' , 'gswin64c' , 'mgs' , 'gs' ]
2205
- else :
2206
- gs_execs = ['gs' ]
2207
- for gs_exec in gs_execs :
2208
- try :
2209
- command = gs_exec + ' --version'
2210
- output = check_output (command , shell = True ,
2211
- stderr = subprocess .STDOUT )
2212
- return "version %s" % output .decode ()[:- 1 ]
2213
- except (IndexError , ValueError , subprocess .CalledProcessError ):
2214
- pass
2215
-
2216
- raise CheckFailed ()
2217
-
2218
-
2219
- class LaTeX (SetupPackage ):
2220
- name = "latex"
2221
- optional = True
2222
-
2223
- def check (self ):
2224
- try :
2225
- output = check_output ('latex -version' , shell = True ,
2226
- stderr = subprocess .STDOUT )
2227
- line = output .splitlines ()[0 ].decode ()
2228
- pattern = '(3\.1\d+)|(MiKTeX \d+.\d+)'
2229
- match = re .search (pattern , line )
2230
- return "version %s" % match .group (0 )
2231
- except (IndexError , ValueError , AttributeError , subprocess .CalledProcessError ):
2232
- raise CheckFailed ()
2233
-
2234
-
2235
- class PdfToPs (SetupPackage ):
2236
- name = "pdftops"
2237
- optional = True
2238
-
2239
- def check (self ):
2240
- try :
2241
- output = check_output ('pdftops -v' , shell = True ,
2242
- stderr = subprocess .STDOUT )
2243
- for line in output .splitlines ():
2244
- line = line .decode ()
2245
- if 'version' in line :
2246
- return "version %s" % line .split ()[2 ]
2247
- except (IndexError , ValueError , subprocess .CalledProcessError ):
2248
- pass
2249
-
2250
- raise CheckFailed ()
2251
-
2252
-
2253
2184
class OptionalPackageData (OptionalPackage ):
2254
2185
config_category = "package_data"
2255
2186
0 commit comments