File tree Expand file tree Collapse file tree 1 file changed +11
-1
lines changed
tests/run-make/libs-through-symlinks Expand file tree Collapse file tree 1 file changed +11
-1
lines changed Original file line number Diff line number Diff line change @@ -3,10 +3,20 @@ include ../tools.mk
3
3
4
4
# ignore-windows
5
5
6
+ # The option -n for the AIX ln command has a different purpose than it does
7
+ # on Linux. On Linux, the -n option is used to treat the destination path as
8
+ # normal file if it is a symbolic link to a directory, which is the default
9
+ # behavior of the AIX ln command.
10
+ ifeq ($(UNAME ) ,AIX)
11
+ LN_FLAGS := -sf
12
+ else
13
+ LN_FLAGS := -nsf
14
+ endif
15
+
6
16
NAME := $(shell $(RUSTC ) --print file-names foo.rs)
7
17
8
18
all :
9
19
mkdir -p $(TMPDIR ) /outdir
10
20
$(RUSTC ) foo.rs -o $(TMPDIR ) /outdir/$(NAME )
11
- ln -nsf outdir/$(NAME ) $(TMPDIR )
21
+ ln $( LN_FLAGS ) outdir/$(NAME ) $(TMPDIR )
12
22
RUSTC_LOG=rustc_metadata::loader $(RUSTC ) bar.rs
You can’t perform that action at this time.
0 commit comments