File tree Expand file tree Collapse file tree 5 files changed +10
-18
lines changed Expand file tree Collapse file tree 5 files changed +10
-18
lines changed Original file line number Diff line number Diff line change 47
47
CFG_RUNTIME :=$(call CFG_LIB_NAME,rustrt)
48
48
CFG_RUSTLLVM :=$(call CFG_LIB_NAME,rustllvm)
49
49
CFG_STDLIB :=$(call CFG_LIB_NAME,std)
50
+ CFG_LIBRUSTC :=$(call CFG_LIB_NAME,rustc)
50
51
51
52
# version-string calculation
52
53
CFG_GIT_DIR := $(CFG_SRC_DIR ) .git
Original file line number Diff line number Diff line change 1
- # At the moment the fuzzer only exists in stage2. That's the first
2
- # stage built by the non-snapshot compiler so it seems a convenient
3
- # stage to work at.
1
+ # At the moment the fuzzer only exists in stage1.
4
2
5
3
FUZZER_CRATE := $(S ) src/fuzzer/fuzzer.rc
6
4
FUZZER_INPUTS := $(wildcard $(addprefix $(S ) src/fuzzer/, * .rs) )
7
5
8
- stage2/fuzzer.o : $(FUZZER_CRATE ) $(FUZZER_INPUTS ) $(SREQ1 )
9
- @$(call E, compile: $@ )
10
- $(STAGE1 ) -c -o $@ $<
11
-
12
- stage2/fuzzer$(X ) : stage2/fuzzer.o $(SREQ1 )
13
- @$(call E, link [gcc]: $@ )
14
- $(Q ) gcc $(CFG_GCCISH_CFLAGS ) rt/main.o stage2/glue.o -o $@ $< \
15
- -Lstage2 -Lrustllvm -Lrt -lrustrt -lrustllvm -lstd -lm -lrustc
16
- @# dsymutil sometimes fails or prints a warning, but the
17
- @# program still runs. Since it simplifies debugging other
18
- @# programs, I\'ll live with the noise.
19
- -$(Q)$(CFG_DSYMUTIL) $@
6
+ stage1/fuzzer$(X ) : $(FUZZER_CRATE ) $(FUZZER_INPUTS ) $(SREQ1 )
7
+ @$(call E, compile_and_link: $@ )
8
+ $(STAGE1 ) -o $@ $<
Original file line number Diff line number Diff line change @@ -29,3 +29,8 @@ stage1/%.o: stage1/%.s
29
29
stage1/% $(X ) : $(COMPILER_CRATE ) $(COMPILER_INPUTS ) $(SREQ0 ) stage0/intrinsics.bc
30
30
@$(call E, compile_and_link: $@ )
31
31
$(STAGE0 ) -o $@ $<
32
+
33
+ stage1/lib/$(CFG_LIBRUSTC ) : $(COMPILER_CRATE ) $(COMPILER_INPUTS ) $(SREQ1 ) \
34
+ stage1/intrinsics.bc
35
+ @$(call E, compile_and_link: $@)
36
+ $(STAGE1) --shared -o $@ $<
Original file line number Diff line number Diff line change 1
1
// -*- rust -*-
2
2
3
3
use std;
4
- use rustc;
5
4
6
5
mod fuzzer;
7
6
Original file line number Diff line number Diff line change @@ -6,8 +6,6 @@ import std::getopts::opt_str;
6
6
import std:: io;
7
7
import std:: vec;
8
8
9
- import rustc:: front:: ast;
10
-
11
9
type src_gen = iter ( ) -> str ;
12
10
13
11
iter dir_src_gen ( str dir) -> str {
You can’t perform that action at this time.
0 commit comments