splat64 0.35.0__py3-none-any.whl → 0.35.2__py3-none-any.whl
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.
- splat/__init__.py +1 -1
- splat/util/file_presets.py +35 -12
- {splat64-0.35.0.dist-info → splat64-0.35.2.dist-info}/METADATA +4 -4
- {splat64-0.35.0.dist-info → splat64-0.35.2.dist-info}/RECORD +7 -7
- {splat64-0.35.0.dist-info → splat64-0.35.2.dist-info}/WHEEL +0 -0
- {splat64-0.35.0.dist-info → splat64-0.35.2.dist-info}/entry_points.txt +0 -0
- {splat64-0.35.0.dist-info → splat64-0.35.2.dist-info}/licenses/LICENSE +0 -0
splat/__init__.py
CHANGED
splat/util/file_presets.py
CHANGED
|
@@ -14,6 +14,9 @@ from . import options, log
|
|
|
14
14
|
|
|
15
15
|
|
|
16
16
|
def write_all_files():
|
|
17
|
+
if not options.opts.generate_asm_macros_files:
|
|
18
|
+
return
|
|
19
|
+
|
|
17
20
|
write_include_asm_h()
|
|
18
21
|
write_assembly_inc_files()
|
|
19
22
|
|
|
@@ -122,20 +125,26 @@ def write_assembly_inc_files():
|
|
|
122
125
|
options.opts.asm_jtbl_label_macro != ""
|
|
123
126
|
and options.opts.asm_jtbl_label_macro != options.opts.asm_function_macro
|
|
124
127
|
):
|
|
125
|
-
|
|
128
|
+
jlabel_macro_macroinc = f"""
|
|
126
129
|
# A label referenced by a jumptable.
|
|
127
130
|
.macro {options.opts.asm_jtbl_label_macro} label, visibility=global
|
|
131
|
+
.\\visibility \\label
|
|
128
132
|
\\label:
|
|
129
133
|
.endm
|
|
130
134
|
"""
|
|
131
|
-
|
|
135
|
+
if options.opts.migrate_rodata_to_functions:
|
|
136
|
+
jlabel_macro_labelsinc = f"""
|
|
132
137
|
# A label referenced by a jumptable.
|
|
133
|
-
.macro {options.opts.asm_jtbl_label_macro} label, visibility=
|
|
138
|
+
.macro {options.opts.asm_jtbl_label_macro} label, visibility=local
|
|
134
139
|
.\\visibility \\label
|
|
135
|
-
.type \\label, @function
|
|
136
140
|
\\label:
|
|
137
141
|
.endm
|
|
138
142
|
"""
|
|
143
|
+
else:
|
|
144
|
+
# If the user doesn't migrate rodata, like jumptables, to functions
|
|
145
|
+
# then the user will need jlabels to be global instead of local,
|
|
146
|
+
# so we just reuse the definition from macro.inc
|
|
147
|
+
jlabel_macro_labelsinc = jlabel_macro_macroinc
|
|
139
148
|
|
|
140
149
|
data_macros = ""
|
|
141
150
|
if (
|
|
@@ -170,12 +179,6 @@ def write_assembly_inc_files():
|
|
|
170
179
|
.endm
|
|
171
180
|
"""
|
|
172
181
|
|
|
173
|
-
labels_inc = f"""\
|
|
174
|
-
{func_macros}
|
|
175
|
-
{jlabel_macro_labelsinc}
|
|
176
|
-
{data_macros}
|
|
177
|
-
{nm_macros}\
|
|
178
|
-
"""
|
|
179
182
|
macros_inc = f"""\
|
|
180
183
|
{func_macros}
|
|
181
184
|
{jlabel_macro_macroinc}
|
|
@@ -186,7 +189,18 @@ def write_assembly_inc_files():
|
|
|
186
189
|
if options.opts.compiler.uses_include_asm:
|
|
187
190
|
# File used by original assembler
|
|
188
191
|
preamble = "# This file is used by the original compiler/assembler.\n# Defines the expected assembly macros.\n"
|
|
189
|
-
|
|
192
|
+
|
|
193
|
+
if options.opts.platform == "psx":
|
|
194
|
+
preamble += '\n.include "gte_macros.inc"\n'
|
|
195
|
+
|
|
196
|
+
labels_inc = f"""\
|
|
197
|
+
{preamble}
|
|
198
|
+
{func_macros}
|
|
199
|
+
{jlabel_macro_labelsinc}
|
|
200
|
+
{data_macros}
|
|
201
|
+
{nm_macros}\
|
|
202
|
+
"""
|
|
203
|
+
_write("include/labels.inc", labels_inc)
|
|
190
204
|
|
|
191
205
|
if options.opts.platform in {"n64", "psx"}:
|
|
192
206
|
gas = macros_inc
|
|
@@ -275,7 +289,7 @@ def write_assembly_inc_files():
|
|
|
275
289
|
.set $fs5f, $f31
|
|
276
290
|
"""
|
|
277
291
|
elif options.opts.platform == "psx":
|
|
278
|
-
gas += '\
|
|
292
|
+
gas += '\n.include "gte_macros.inc"\n'
|
|
279
293
|
write_gte_macros()
|
|
280
294
|
|
|
281
295
|
if options.opts.generated_macro_inc_content is not None:
|
|
@@ -285,6 +299,15 @@ def write_assembly_inc_files():
|
|
|
285
299
|
preamble = (
|
|
286
300
|
"# This file is used by modern gas.\n# Defines the expected assembly macros\n"
|
|
287
301
|
)
|
|
302
|
+
gas = f"""\
|
|
303
|
+
# Evaluate this file only once in case it's included more than once
|
|
304
|
+
.ifndef _MACRO_INC_GUARD
|
|
305
|
+
.internal _MACRO_INC_GUARD
|
|
306
|
+
.set _MACRO_INC_GUARD, 1
|
|
307
|
+
|
|
308
|
+
{gas}
|
|
309
|
+
.endif
|
|
310
|
+
"""
|
|
288
311
|
_write("include/macro.inc", f"{preamble}\n{gas}")
|
|
289
312
|
|
|
290
313
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: splat64
|
|
3
|
-
Version: 0.35.
|
|
3
|
+
Version: 0.35.2
|
|
4
4
|
Summary: A binary splitting tool to assist with decompilation and modding projects
|
|
5
5
|
Project-URL: Repository, https://github.com/ethteck/splat
|
|
6
6
|
Project-URL: Issues, https://github.com/ethteck/splat/issues
|
|
@@ -42,7 +42,7 @@ Requires-Dist: mypy; extra == 'dev'
|
|
|
42
42
|
Requires-Dist: n64img>=0.3.3; extra == 'dev'
|
|
43
43
|
Requires-Dist: pygfxd; extra == 'dev'
|
|
44
44
|
Requires-Dist: rabbitizer<2.0.0,>=1.12.0; extra == 'dev'
|
|
45
|
-
Requires-Dist: spimdisasm<2.0.0,>=1.
|
|
45
|
+
Requires-Dist: spimdisasm<2.0.0,>=1.36.0; extra == 'dev'
|
|
46
46
|
Requires-Dist: types-colorama; extra == 'dev'
|
|
47
47
|
Requires-Dist: types-pyyaml; extra == 'dev'
|
|
48
48
|
Provides-Extra: mips
|
|
@@ -50,7 +50,7 @@ Requires-Dist: crunch64<1.0.0,>=0.5.1; extra == 'mips'
|
|
|
50
50
|
Requires-Dist: n64img>=0.3.3; extra == 'mips'
|
|
51
51
|
Requires-Dist: pygfxd; extra == 'mips'
|
|
52
52
|
Requires-Dist: rabbitizer<2.0.0,>=1.12.0; extra == 'mips'
|
|
53
|
-
Requires-Dist: spimdisasm<2.0.0,>=1.
|
|
53
|
+
Requires-Dist: spimdisasm<2.0.0,>=1.36.0; extra == 'mips'
|
|
54
54
|
Description-Content-Type: text/markdown
|
|
55
55
|
|
|
56
56
|
# splat
|
|
@@ -76,7 +76,7 @@ The brackets corresponds to the optional dependencies to install while installin
|
|
|
76
76
|
If you use a `requirements.txt` file in your repository, then you can add this library with the following line:
|
|
77
77
|
|
|
78
78
|
```txt
|
|
79
|
-
splat64[mips]>=0.35.
|
|
79
|
+
splat64[mips]>=0.35.2,<1.0.0
|
|
80
80
|
```
|
|
81
81
|
|
|
82
82
|
### Optional dependencies
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
splat/__init__.py,sha256=
|
|
1
|
+
splat/__init__.py,sha256=plXxTGxbR0ohNAzhonKhmbJtAvjkwe9BvuQc78b0vbI,291
|
|
2
2
|
splat/__main__.py,sha256=T333dHDgr-2HYYhtARnYMEjdECnYiNIKfcXDD99o22A,732
|
|
3
3
|
splat/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
4
4
|
splat/disassembler/__init__.py,sha256=IubLMnm_F5cZ7WUPBfk1VJ7vdj6i1if5GG6RBvEoBEA,226
|
|
@@ -80,7 +80,7 @@ splat/util/cache_handler.py,sha256=N0SggmvYwh0k-0fngHXoHG1CosC2rCsnlCTDsG8z5aE,1
|
|
|
80
80
|
splat/util/color.py,sha256=FSmy0dAQJ9FzRBc99Yt4kBEyB62MC_YiVkqoWgPMsRU,371
|
|
81
81
|
splat/util/compiler.py,sha256=uXShMm49380ENecSFlsi75LWI45yakWkExZX8NT5pOU,1778
|
|
82
82
|
splat/util/conf.py,sha256=aM6O2QikosjL95pCxI2FcCxrwDsLP8T8sRf2Uev_Pac,3236
|
|
83
|
-
splat/util/file_presets.py,sha256=
|
|
83
|
+
splat/util/file_presets.py,sha256=i7kqRCNJ_LjIY1xnc9pyAh690SAA4-cZPotJL_LnpvM,17425
|
|
84
84
|
splat/util/log.py,sha256=aJA1rg8IirJu1wGzjNuATHvepYvD3k5CtEyMasyJWxI,1193
|
|
85
85
|
splat/util/options.py,sha256=KqNjeB2mSwuB09H3uylfZ9PU7GlCZDYhkhfCLAGYSQE,30005
|
|
86
86
|
splat/util/palettes.py,sha256=d3KoZnwt-zunI9eNwb3txysXg4DY3xnF0O5aQRxM4so,2920
|
|
@@ -95,8 +95,8 @@ splat/util/n64/find_code_length.py,sha256=uUoPoUORAjsAvH8oGqwnGvw6j8I_NnSrZtA-x9
|
|
|
95
95
|
splat/util/n64/rominfo.py,sha256=s13r4pDPH9Mc43ZGpomPnLZPWchhbv0kIjDoM0B3Ong,16963
|
|
96
96
|
splat/util/psx/__init__.py,sha256=kCCaR-KB1mNlIcXB4OuuSQ2zVLbWg_SnIZIUeyjeBBI,39
|
|
97
97
|
splat/util/psx/psxexeinfo.py,sha256=MrxY28nes0uzpFmCz0o9JFbF8s1eQRQNOpC_82wsMVI,5725
|
|
98
|
-
splat64-0.35.
|
|
99
|
-
splat64-0.35.
|
|
100
|
-
splat64-0.35.
|
|
101
|
-
splat64-0.35.
|
|
102
|
-
splat64-0.35.
|
|
98
|
+
splat64-0.35.2.dist-info/METADATA,sha256=lsfohLB5MYUUzM3LB-hLB06byuE64aJkO1hCIJ6snw4,3830
|
|
99
|
+
splat64-0.35.2.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
|
|
100
|
+
splat64-0.35.2.dist-info/entry_points.txt,sha256=O7Xy-qNOHcI87-OQrWJ-OhRDws74SuwVb_4rtnp0eLo,52
|
|
101
|
+
splat64-0.35.2.dist-info/licenses/LICENSE,sha256=97VMVzjG8yQvsf8NG2M9IFSbh7R8cifJnc6QK1cZqj8,1070
|
|
102
|
+
splat64-0.35.2.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|