notaz.gp2x.de
/
ginge.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
wiz blitters, fb restore, tweaks
[ginge.git]
/
prep
/
main.c
diff --git
a/prep/main.c
b/prep/main.c
index
8acbef7
..
a03bc38
100644
(file)
--- a/
prep/main.c
+++ b/
prep/main.c
@@
-258,6
+258,13
@@
int main(int argc, char *argv[])
return 1;
}
return 1;
}
+ if (strcmp(argv[1], "--cleanup") == 0) {
+ // as loader may crash eny time, restore screen for them menu
+ host_video_init(NULL, 0);
+ host_video_finish();
+ return 0;
+ }
+
if (getcwd(cwd, sizeof(cwd)) == NULL) {
err(PFX "failed to get cwd\n");
return 1;
if (getcwd(cwd, sizeof(cwd)) == NULL) {
err(PFX "failed to get cwd\n");
return 1;
@@
-414,6
+421,10
@@
pass:
fclose(fin);
no_in_script:
fclose(fin);
no_in_script:
+#ifdef WIZ
+ fprintf(fout, "sync\n");
+ fprintf(fout, "%sginge_prep --cleanup\n", root_path);
+#endif
if (rerun_gp2xmenu) {
fprintf(fout, "cd %s\n", root_path);
fprintf(fout, "exec %s%s\n", root_path, LAUNCHER);
if (rerun_gp2xmenu) {
fprintf(fout, "cd %s\n", root_path);
fprintf(fout, "exec %s%s\n", root_path, LAUNCHER);