diff --git a/GNUmakefile b/GNUmakefile index 6b242cb93b..0abda59dc7 100644 --- a/GNUmakefile +++ b/GNUmakefile @@ -112,7 +112,7 @@ ifdef LEGACY endif $(CC) $(CFLAGS) -std=gnu99 -w -o v1.exe $(VC)/$(VCFILE) -lm -lpthread $(LDFLAGS) ./v1.exe -no-parallel -o v2.exe $(VFLAGS) cmd/v - ./v2.exe -o $(VEXE) $(VFLAGS) cmd/v + ./v2.exe -nocache -o $(VEXE) $(VFLAGS) cmd/v rm -rf v1.exe v2.exe endif @$(VEXE) run cmd/tools/detect_tcc.v diff --git a/vlib/v/pref/pref.v b/vlib/v/pref/pref.v index f90cb0b30f..645b2c201e 100644 --- a/vlib/v/pref/pref.v +++ b/vlib/v/pref/pref.v @@ -251,6 +251,14 @@ pub fn parse_args_and_show_errors(known_external_commands []string, args []strin res.run_only = os.getenv('VTEST_ONLY_FN').split_any(',') mut command := '' mut command_pos := -1 + + /* + $if macos || linux { + res.use_cache = true + res.skip_unused = true + } + */ + // for i, arg in args { for i := 0; i < args.len; i++ { arg := args[i] @@ -450,6 +458,9 @@ pub fn parse_args_and_show_errors(known_external_commands []string, args []strin '-skip-unused' { res.skip_unused = true } + '-no-skip-unused' { + res.skip_unused = false + } '-compress' { res.compress = true } @@ -796,7 +807,6 @@ pub fn parse_args_and_show_errors(known_external_commands []string, args []strin exit(1) } - // res.use_cache = true if command != 'doc' && res.out_name.ends_with('.v') { eprintln('Cannot save output binary in a .v file.') exit(1)