mk: allow renaming of build directories
When building using make, the Makefile in the build directory contained the name of the build directory to be passed as an "O=" parameter to the DPDK SDK makefiles. Unfortunately, this meant that the compilation would always fail if the build directory was renamed. To remove this limitation, we can use $(CURDIR) instead of the directory name. Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
This commit is contained in:
parent
f98a95102d
commit
6927f8dbf3
@ -5,7 +5,6 @@
|
|||||||
# Auto-generate a Makefile in build directory
|
# Auto-generate a Makefile in build directory
|
||||||
# Args:
|
# Args:
|
||||||
# $1: path of project src root
|
# $1: path of project src root
|
||||||
# $2: path of build dir (can be relative to $1)
|
|
||||||
|
|
||||||
echo "# Automatically generated by gen-build-mk.sh"
|
echo "# Automatically generated by gen-build-mk.sh"
|
||||||
echo
|
echo
|
||||||
@ -18,7 +17,7 @@ echo
|
|||||||
echo "MAKEFLAGS += --no-print-directory"
|
echo "MAKEFLAGS += --no-print-directory"
|
||||||
echo
|
echo
|
||||||
echo "all:"
|
echo "all:"
|
||||||
echo " @\$(MAKE) -C $1 O=$2"
|
echo " @\$(MAKE) -C $1 O=\$(CURDIR)"
|
||||||
echo
|
echo
|
||||||
echo "%::"
|
echo "%::"
|
||||||
echo " @\$(MAKE) -C $1 O=$2 \$@"
|
echo " @\$(MAKE) -C $1 O=\$(CURDIR) \$@"
|
||||||
|
@ -114,8 +114,7 @@ SDK_RELPATH=$(shell $(RTE_SDK)/buildtools/relpath.sh $(abspath $(RTE_SRCDIR)) \
|
|||||||
OUTPUT_RELPATH=$(shell $(RTE_SDK)/buildtools/relpath.sh $(abspath $(RTE_OUTPUT)) \
|
OUTPUT_RELPATH=$(shell $(RTE_SDK)/buildtools/relpath.sh $(abspath $(RTE_OUTPUT)) \
|
||||||
$(abspath $(RTE_SRCDIR)))
|
$(abspath $(RTE_SRCDIR)))
|
||||||
$(RTE_OUTPUT)/Makefile: | $(RTE_OUTPUT)
|
$(RTE_OUTPUT)/Makefile: | $(RTE_OUTPUT)
|
||||||
$(Q)$(RTE_SDK)/buildtools/gen-build-mk.sh $(SDK_RELPATH) $(OUTPUT_RELPATH) \
|
$(Q)$(RTE_SDK)/buildtools/gen-build-mk.sh $(SDK_RELPATH) > $@
|
||||||
> $(RTE_OUTPUT)/Makefile
|
|
||||||
|
|
||||||
# clean installed files, and generate a new config header file
|
# clean installed files, and generate a new config header file
|
||||||
# if NODOTCONF variable is defined, don't try to rebuild .config
|
# if NODOTCONF variable is defined, don't try to rebuild .config
|
||||||
|
Loading…
Reference in New Issue
Block a user