mirror of
https://gitee.com/Lyon1998/pikapython.git
synced 2025-01-15 17:02:53 +08:00
fix ./msc xxx -o yyy
This commit is contained in:
parent
3fbbd94e5a
commit
f507182d3f
@ -59,17 +59,19 @@ int main(int argc, char** argv) {
|
|||||||
|
|
||||||
/* example ./rust-msc-latest-linux main.py -o out.a */
|
/* example ./rust-msc-latest-linux main.py -o out.a */
|
||||||
if (3 == parc) {
|
if (3 == parc) {
|
||||||
PikaMaker* maker = New_PikaMaker();
|
if (0 == strcmp(argv[2], "-o")) {
|
||||||
char* module_entry = argv[1];
|
PikaMaker* maker = New_PikaMaker();
|
||||||
/* remove subfix */
|
char* module_entry = argv[1];
|
||||||
char* subfix = strrchr(module_entry, '.');
|
/* remove subfix */
|
||||||
if (subfix) {
|
char* subfix = strrchr(module_entry, '.');
|
||||||
*subfix = '\0';
|
if (subfix) {
|
||||||
|
*subfix = '\0';
|
||||||
|
}
|
||||||
|
pikaMaker_compileModuleWithDepends(maker, module_entry);
|
||||||
|
pikaMaker_linkCompiledModules(maker, argv[3]);
|
||||||
|
obj_deinit(maker);
|
||||||
|
return 0;
|
||||||
}
|
}
|
||||||
pikaMaker_compileModuleWithDepends(maker, module_entry);
|
|
||||||
pikaMaker_linkCompiledModules(maker, argv[2]);
|
|
||||||
obj_deinit(maker);
|
|
||||||
return 0;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/* example: ./rust-msc-latest-linux -c main.py */
|
/* example: ./rust-msc-latest-linux -c main.py */
|
||||||
|
Binary file not shown.
Loading…
x
Reference in New Issue
Block a user