From 3f09b90d211a86c1d002a786a5ffc34b72fba780 Mon Sep 17 00:00:00 2001 From: Akim Demaille Date: Fri, 14 Dec 2012 17:18:03 +0100 Subject: build: fix VPATH builds * configure (fn_dirname): New. Use it to ensure the creation of proper symlinks to Makefiles. (config.mak): Define top_builddir and top_srcdir. (CPPFLAGS): Be sure to find the headers. * Makefile, lib/Makefile, tests/Makefile, tests2/Makefile: Adjust to set VPATH properly. Fix confusion between top_builddir and top_srcdir. --- lib/Makefile | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'lib/Makefile') diff --git a/lib/Makefile b/lib/Makefile index 6813052..a3e2cd1 100644 --- a/lib/Makefile +++ b/lib/Makefile @@ -4,6 +4,7 @@ TOP = .. include $(TOP)/config.mak +VPATH = $(top_srcdir)/lib $(top_srcdir)/win32/lib ifndef TARGET ifdef CONFIG_WIN64 @@ -42,8 +43,6 @@ X86_64_O = libtcc1.o alloca86_64.o WIN32_O = $(I386_O) crt1.o wincrt1.o dllcrt1.o dllmain.o chkstk.o bcheck.o WIN64_O = $(X86_64_O) crt1.o wincrt1.o dllcrt1.o dllmain.o chkstk.o -VPATH = $(TOP)/lib $(TOP)/win32/lib - ifeq "$(TARGET)" "i386-win32" OBJ = $(addprefix $(DIR)/,$(WIN32_O)) TGT = -DTCC_TARGET_I386 -DTCC_TARGET_PE -- cgit v1.3.1