ciel 2.0.1__tar.gz → 2.0.2__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {ciel-2.0.1 → ciel-2.0.2}/PKG-INFO +2 -2
- {ciel-2.0.1 → ciel-2.0.2}/Readme.md +1 -1
- {ciel-2.0.1 → ciel-2.0.2}/ciel/build/__init__.py +15 -17
- {ciel-2.0.1 → ciel-2.0.2}/ciel/build/git_multi_clone.py +9 -9
- {ciel-2.0.1 → ciel-2.0.2}/ciel/click_common.py +12 -4
- {ciel-2.0.1 → ciel-2.0.2}/ciel/manage.py +2 -2
- {ciel-2.0.1 → ciel-2.0.2}/pyproject.toml +1 -1
- {ciel-2.0.1 → ciel-2.0.2}/ciel/__init__.py +0 -0
- {ciel-2.0.1 → ciel-2.0.2}/ciel/__main__.py +0 -0
- {ciel-2.0.1 → ciel-2.0.2}/ciel/__version__.py +0 -0
- {ciel-2.0.1 → ciel-2.0.2}/ciel/build/common.py +0 -0
- {ciel-2.0.1 → ciel-2.0.2}/ciel/build/gf180mcu.py +0 -0
- /ciel-2.0.1/ciel/build/ihp_sg13g2.py → /ciel-2.0.2/ciel/build/ihp-sg13g2.py +0 -0
- {ciel-2.0.1 → ciel-2.0.2}/ciel/build/sky130.py +0 -0
- {ciel-2.0.1 → ciel-2.0.2}/ciel/common.py +0 -0
- {ciel-2.0.1 → ciel-2.0.2}/ciel/families.py +0 -0
- {ciel-2.0.1 → ciel-2.0.2}/ciel/github.py +0 -0
- {ciel-2.0.1 → ciel-2.0.2}/ciel/py.typed +0 -0
- {ciel-2.0.1 → ciel-2.0.2}/ciel/source.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: ciel
|
|
3
|
-
Version: 2.0.
|
|
3
|
+
Version: 2.0.2
|
|
4
4
|
Summary: An PDK builder/version manager for PDKs in the open_pdks format
|
|
5
5
|
Home-page: https://github.com/fossi-foundation/ciel
|
|
6
6
|
License: Apache-2.0
|
|
@@ -31,7 +31,7 @@ Description-Content-Type: text/markdown
|
|
|
31
31
|
<p align="center">
|
|
32
32
|
<a href="https://opensource.org/licenses/Apache-2.0"><img src="https://img.shields.io/badge/License-Apache%202.0-blue.svg" alt="License: Apache 2.0"/></a>
|
|
33
33
|
<img src="https://github.com/fossi-foundation/ciel/actions/workflows/ci.yml/badge.svg?branch=main" alt="CI Status" />
|
|
34
|
-
<a href="https://fossi-chat.org"><img src="https://img.shields.io/badge/Community-FOSSi%20Chat-1bb378?logo=element" alt="Invite to
|
|
34
|
+
<a href="https://fossi-chat.org"><img src="https://img.shields.io/badge/Community-FOSSi%20Chat-1bb378?logo=element" alt="Invite to FOSSi Chat"/></a>
|
|
35
35
|
<a href="https://github.com/psf/black"><img src="https://img.shields.io/badge/code%20style-black-000000.svg" alt="Code Style: Black"/></a>
|
|
36
36
|
</p>
|
|
37
37
|
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
<p align="center">
|
|
3
3
|
<a href="https://opensource.org/licenses/Apache-2.0"><img src="https://img.shields.io/badge/License-Apache%202.0-blue.svg" alt="License: Apache 2.0"/></a>
|
|
4
4
|
<img src="https://github.com/fossi-foundation/ciel/actions/workflows/ci.yml/badge.svg?branch=main" alt="CI Status" />
|
|
5
|
-
<a href="https://fossi-chat.org"><img src="https://img.shields.io/badge/Community-FOSSi%20Chat-1bb378?logo=element" alt="Invite to
|
|
5
|
+
<a href="https://fossi-chat.org"><img src="https://img.shields.io/badge/Community-FOSSi%20Chat-1bb378?logo=element" alt="Invite to FOSSi Chat"/></a>
|
|
6
6
|
<a href="https://github.com/psf/black"><img src="https://img.shields.io/badge/code%20style-black-000000.svg" alt="Code Style: Black"/></a>
|
|
7
7
|
</p>
|
|
8
8
|
|
|
@@ -50,7 +50,7 @@ from ..families import Family
|
|
|
50
50
|
|
|
51
51
|
def build(
|
|
52
52
|
pdk_root: str,
|
|
53
|
-
|
|
53
|
+
pdk_family: str,
|
|
54
54
|
version: str,
|
|
55
55
|
jobs: int = 1,
|
|
56
56
|
sram: bool = True, # Deprecated
|
|
@@ -64,8 +64,8 @@ def build(
|
|
|
64
64
|
name, path = repo.split("=")
|
|
65
65
|
use_repos[name] = os.path.abspath(path)
|
|
66
66
|
|
|
67
|
-
if
|
|
68
|
-
raise Exception(f"Unsupported PDK family '{
|
|
67
|
+
if pdk_family not in Family.by_name:
|
|
68
|
+
raise Exception(f"Unsupported PDK family '{pdk_family}'.")
|
|
69
69
|
|
|
70
70
|
kwargs = {
|
|
71
71
|
"pdk_root": pdk_root,
|
|
@@ -76,7 +76,7 @@ def build(
|
|
|
76
76
|
"using_repos": use_repos,
|
|
77
77
|
}
|
|
78
78
|
|
|
79
|
-
build_module = importlib.import_module(f".{
|
|
79
|
+
build_module = importlib.import_module(f".{pdk_family}", package=__name__)
|
|
80
80
|
build_function = build_module.build
|
|
81
81
|
build_function(**kwargs)
|
|
82
82
|
|
|
@@ -97,7 +97,7 @@ def build_cmd(
|
|
|
97
97
|
include_libraries,
|
|
98
98
|
jobs,
|
|
99
99
|
pdk_root,
|
|
100
|
-
|
|
100
|
+
pdk_family,
|
|
101
101
|
clear_build_artifacts,
|
|
102
102
|
tool_metadata_file_path,
|
|
103
103
|
version,
|
|
@@ -124,7 +124,7 @@ def build_cmd(
|
|
|
124
124
|
|
|
125
125
|
build(
|
|
126
126
|
pdk_root=pdk_root,
|
|
127
|
-
|
|
127
|
+
pdk_family=pdk_family,
|
|
128
128
|
version=version,
|
|
129
129
|
jobs=jobs,
|
|
130
130
|
clear_build_artifacts=clear_build_artifacts,
|
|
@@ -135,7 +135,7 @@ def build_cmd(
|
|
|
135
135
|
|
|
136
136
|
def push(
|
|
137
137
|
pdk_root,
|
|
138
|
-
|
|
138
|
+
pdk_family,
|
|
139
139
|
version,
|
|
140
140
|
*,
|
|
141
141
|
owner,
|
|
@@ -143,7 +143,7 @@ def push(
|
|
|
143
143
|
pre=False,
|
|
144
144
|
push_libraries=None,
|
|
145
145
|
):
|
|
146
|
-
family = Family.by_name[
|
|
146
|
+
family = Family.by_name[pdk_family]
|
|
147
147
|
|
|
148
148
|
session = GitHubSession()
|
|
149
149
|
if session.github_token is None:
|
|
@@ -155,7 +155,7 @@ def push(
|
|
|
155
155
|
push_libraries = family.all_libraries
|
|
156
156
|
library_list = set(push_libraries)
|
|
157
157
|
|
|
158
|
-
version_object = Version(version,
|
|
158
|
+
version_object = Version(version, pdk_family)
|
|
159
159
|
version_directory = version_object.get_dir(pdk_root)
|
|
160
160
|
if not os.path.isdir(version_directory):
|
|
161
161
|
raise FileNotFoundError(f"Version {version} not found.")
|
|
@@ -196,15 +196,15 @@ def push(
|
|
|
196
196
|
progress.remove_task(task)
|
|
197
197
|
final_tarballs.append(tarball_path)
|
|
198
198
|
|
|
199
|
-
tag = f"{
|
|
199
|
+
tag = f"{pdk_family}-{version}"
|
|
200
200
|
|
|
201
201
|
# If someone wants to rewrite this to not use ghr, please, by all means.
|
|
202
202
|
console.log("Starting upload…")
|
|
203
203
|
|
|
204
|
-
body = f"{
|
|
204
|
+
body = f"{pdk_family} variants built using ciel"
|
|
205
205
|
date = get_commit_date(version, family.repo, session)
|
|
206
206
|
if date is not None:
|
|
207
|
-
body = f"{
|
|
207
|
+
body = f"{pdk_family} variants (released on {date_to_iso8601(date)})"
|
|
208
208
|
|
|
209
209
|
for tarball_path in final_tarballs:
|
|
210
210
|
subprocess.check_call(
|
|
@@ -221,9 +221,7 @@ def push(
|
|
|
221
221
|
"-commitish",
|
|
222
222
|
"releases",
|
|
223
223
|
"-replace",
|
|
224
|
-
|
|
225
|
-
+ (["-prerelease"] if pre else [])
|
|
226
|
-
+ [
|
|
224
|
+
*(["-prerelease"] * pre), # https://discuss.python.org/t/the-precedence-of-unpack-operators/25854/2
|
|
227
225
|
tag,
|
|
228
226
|
tarball_path,
|
|
229
227
|
]
|
|
@@ -241,7 +239,7 @@ def push_cmd(
|
|
|
241
239
|
repository,
|
|
242
240
|
pre,
|
|
243
241
|
pdk_root,
|
|
244
|
-
|
|
242
|
+
pdk_family,
|
|
245
243
|
version,
|
|
246
244
|
push_libraries,
|
|
247
245
|
):
|
|
@@ -256,7 +254,7 @@ def push_cmd(
|
|
|
256
254
|
try:
|
|
257
255
|
push(
|
|
258
256
|
pdk_root,
|
|
259
|
-
|
|
257
|
+
pdk_family,
|
|
260
258
|
version,
|
|
261
259
|
owner=owner,
|
|
262
260
|
repository=repository,
|
|
@@ -64,6 +64,7 @@ class Repository(object):
|
|
|
64
64
|
["git", "clone", "--progress", self.url, self.path],
|
|
65
65
|
stdout=subprocess.PIPE,
|
|
66
66
|
stderr=subprocess.PIPE,
|
|
67
|
+
text=True,
|
|
67
68
|
)
|
|
68
69
|
assert process.stderr is not None
|
|
69
70
|
|
|
@@ -72,10 +73,9 @@ class Repository(object):
|
|
|
72
73
|
# Python Moment
|
|
73
74
|
buffer = ""
|
|
74
75
|
while True:
|
|
75
|
-
|
|
76
|
-
if len(
|
|
76
|
+
char_read = process.stderr.read(1)
|
|
77
|
+
if len(char_read) == 0:
|
|
77
78
|
break
|
|
78
|
-
char_read = bytes_read.decode("utf8")
|
|
79
79
|
if char_read in ["\n", "\r"]:
|
|
80
80
|
match = ro_rx.search(buffer)
|
|
81
81
|
if match is not None:
|
|
@@ -107,6 +107,7 @@ class Repository(object):
|
|
|
107
107
|
cwd=self.path,
|
|
108
108
|
stdout=subprocess.PIPE,
|
|
109
109
|
stderr=subprocess.PIPE,
|
|
110
|
+
text=True,
|
|
110
111
|
)
|
|
111
112
|
assert process.stderr is not None
|
|
112
113
|
callback(0, f"Updating {self.name} at {self.path}…")
|
|
@@ -116,10 +117,9 @@ class Repository(object):
|
|
|
116
117
|
# Python Moment #2
|
|
117
118
|
buffer = ""
|
|
118
119
|
while True:
|
|
119
|
-
|
|
120
|
-
if len(
|
|
120
|
+
char_read = process.stderr.read(1)
|
|
121
|
+
if len(char_read) == 0:
|
|
121
122
|
break
|
|
122
|
-
char_read = bytes_read.decode("utf8")
|
|
123
123
|
if char_read in ["\n", "\r"]:
|
|
124
124
|
match = ro_rx.search(buffer)
|
|
125
125
|
if match is not None:
|
|
@@ -162,6 +162,7 @@ class Repository(object):
|
|
|
162
162
|
stdout=subprocess.PIPE,
|
|
163
163
|
stderr=subprocess.PIPE,
|
|
164
164
|
cwd=self.path,
|
|
165
|
+
text=True,
|
|
165
166
|
)
|
|
166
167
|
|
|
167
168
|
ro_rx = re.compile(r"Receiving objects:\s*(\d+)%")
|
|
@@ -171,10 +172,9 @@ class Repository(object):
|
|
|
171
172
|
# Python Moment #3
|
|
172
173
|
buffer = ""
|
|
173
174
|
while True:
|
|
174
|
-
|
|
175
|
-
if len(
|
|
175
|
+
char_read = process.stderr.read(1)
|
|
176
|
+
if len(char_read) == 0:
|
|
176
177
|
break
|
|
177
|
-
char_read = bytes_read.decode("utf8")
|
|
178
178
|
if char_read in ["\n", "\r"]:
|
|
179
179
|
match = ro_rx.search(buffer)
|
|
180
180
|
if match is not None:
|
|
@@ -100,10 +100,18 @@ def opt_build(function: Callable):
|
|
|
100
100
|
|
|
101
101
|
|
|
102
102
|
def opt_push(function: Callable):
|
|
103
|
-
function = opt(
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
103
|
+
function = opt(
|
|
104
|
+
"-o",
|
|
105
|
+
"--owner",
|
|
106
|
+
default="fossi-foundation",
|
|
107
|
+
help="Artifact Upload Repository Owner",
|
|
108
|
+
)(function)
|
|
109
|
+
function = opt(
|
|
110
|
+
"-r",
|
|
111
|
+
"--repository",
|
|
112
|
+
default="ciel-releases",
|
|
113
|
+
help="Artifact Upload Repository",
|
|
114
|
+
)(function)
|
|
107
115
|
function = opt(
|
|
108
116
|
"--pre/--prod", default=False, help="Push as pre-release or production"
|
|
109
117
|
)(function)
|
|
@@ -231,7 +231,7 @@ def fetch(
|
|
|
231
231
|
)
|
|
232
232
|
build(
|
|
233
233
|
pdk_root=pdk_root,
|
|
234
|
-
|
|
234
|
+
pdk_family=pdk,
|
|
235
235
|
version=version,
|
|
236
236
|
**build_kwargs,
|
|
237
237
|
)
|
|
@@ -242,7 +242,7 @@ def fetch(
|
|
|
242
242
|
].default_includes.copy()
|
|
243
243
|
push(
|
|
244
244
|
pdk_root=pdk_root,
|
|
245
|
-
|
|
245
|
+
pdk_family=pdk,
|
|
246
246
|
version=version,
|
|
247
247
|
**push_kwargs,
|
|
248
248
|
)
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|