]>
git.proxmox.com Git - rustc.git/blob - tests/run-make/cdylib-dylib-linkage/Makefile
4 TARGET_SYSROOT
:= $(shell $(RUSTC
) --print sysroot
)/lib
/rustlib
/$(TARGET
)/lib
7 LIBSTD
:= $(wildcard $(TARGET_SYSROOT
)/libstd-
*.dll.lib
)
9 LIBSTD
:= $(wildcard $(TARGET_SYSROOT
)/$(call DYLIB_GLOB
,std
))
10 STD
:= $(basename $(patsubst lib
%,%, $(notdir $(LIBSTD
))))
13 all: $(call RUN_BINFILE
,foo
)
17 CLIBS
:= $(TMPDIR
)/foo.dll.lib
$(TMPDIR
)/bar.dll.lib
$(LIBSTD
)
18 $(call RUN_BINFILE
,foo
): $(call DYLIB
,foo
)
19 $(CC
) $(CFLAGS
) foo.c
$(CLIBS
) $(call OUT_EXE
,foo
)
21 CLIBS
:= -lfoo
-lbar
-l
$(STD
) -L
$(TMPDIR
) -L
$(TARGET_SYSROOT
)
22 $(call RUN_BINFILE
,foo
): $(call DYLIB
,foo
)
23 $(CC
) $(CFLAGS
) foo.c
$(CLIBS
) -o
$(call RUN_BINFILE
,foo
)
27 $(RUSTC
) -C prefer-dynamic bar.rs