We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent bc145ce commit ab2ee7aCopy full SHA for ab2ee7a
tests/run-make/libs-through-symlinks/Makefile
@@ -3,10 +3,20 @@ include ../tools.mk
3
4
# ignore-windows
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
+
16
NAME := $(shell $(RUSTC) --print file-names foo.rs)
17
18
all:
19
mkdir -p $(TMPDIR)/outdir
20
$(RUSTC) foo.rs -o $(TMPDIR)/outdir/$(NAME)
- ln -nsf outdir/$(NAME) $(TMPDIR)
21
+ ln $(LN_FLAGS) outdir/$(NAME) $(TMPDIR)
22
RUSTC_LOG=rustc_metadata::loader $(RUSTC) bar.rs
0 commit comments