File tree Expand file tree Collapse file tree 4 files changed +40
-0
lines changed
src/test/run-make/include_bytes_deps Expand file tree Collapse file tree 4 files changed +40
-0
lines changed Original file line number Diff line number Diff line change
1
+ -include ../tools.mk
2
+
3
+ # FIXME: ignore freebsd/windows
4
+ # on windows `rustc --dep-info` produces Makefile dependency with
5
+ # windows native paths (e.g. `c:\path\to\libfoo.a`)
6
+ # but msys make seems to fail to recognize such paths, so test fails.
7
+ ifneq ($(shell uname) ,FreeBSD)
8
+ ifndef IS_WINDOWS
9
+ all :
10
+ $(RUSTC ) --emit dep-info main.rs
11
+ grep " input.txt" $(TMPDIR ) /main.d
12
+ grep " input.bin" $(TMPDIR ) /main.d
13
+ else
14
+ all :
15
+
16
+ endif
17
+
18
+ else
19
+ all :
20
+
21
+ endif
Original file line number Diff line number Diff line change
1
+ Hello world!
Original file line number Diff line number Diff line change
1
+ Hello world!
Original file line number Diff line number Diff line change
1
+ // Copyright 2014 The Rust Project Developers. See the COPYRIGHT
2
+ // file at the top-level directory of this distribution and at
3
+ // http://rust-lang.org/COPYRIGHT.
4
+ //
5
+ // Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
6
+ // http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
7
+ // <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
8
+ // option. This file may not be copied, modified, or distributed
9
+ // except according to those terms.
10
+
11
+ pub fn main ( ) {
12
+ const INPUT_TXT : & ' static str = include_str ! ( "input.txt" ) ;
13
+ const INPUT_BIN : & ' static [ u8 ] = include_bytes ! ( "input.bin" ) ;
14
+
15
+ println ! ( "{}" , INPUT_TXT ) ;
16
+ println ! ( "{:?}" , INPUT_BIN ) ;
17
+ }
You can’t perform that action at this time.
0 commit comments