-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcmake.py
More file actions
29 lines (25 loc) · 960 Bytes
/
cmake.py
File metadata and controls
29 lines (25 loc) · 960 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
""" Formula for building cmake """
from pakit import Archive, Git, Recipe
class Cmake(Recipe):
"""
A cross-platform build tool for C++
"""
def __init__(self):
super(Cmake, self).__init__()
self.homepage = 'www.cmake.org'
self.repos = {
'stable': Archive('https://github.com/Kitware/CMake/releases/download/v3.23.2/cmake-3.23.2.tar.gz',
hash='f316b40053466f9a416adf981efda41b160ca859e97f6a484b447ea299ff26aa'),
'unstable': Git('git://cmake.org/cmake.git'),
}
self.opts = {
'bootstrap': '--sphinx-html --sphinx-man'
}
def build(self):
self.cmd('./bootstrap --prefix={prefix} --mandir=share/man '
'{bootstrap}')
self.cmd('make -j')
self.cmd('make install')
def verify(self):
lines = self.cmd('cmake --version').output()
assert lines[0].find('cmake version') != -1