build: remove lib/.gitignore
This isn't required - we already have the whole build/ directory in the top level .gitignore. When we remove build/lib/.gitignore, it means build/lib directory must be created somewhere before we try to place a library there. Top-level builds get this directory created automatically, but building directly from a sub-directory's Makefile means we need to explicitly create build/lib. So add a mkdir -p to the LIB_C macro to do exactly that to cover these cases. Also simplify 'make clean' at the top level Makefile. A lot of work went in there to work around this .gitignore file that's not needed now that we've fixed the underlying problem by getting rid of it. Suggested-by: John Levon <john.levon@nutanix.com> Signed-off-by: Jim Harris <james.r.harris@intel.com> Change-Id: Ibb92ff84d8c2a9bbe3e193c84f15ef3866f07b1f Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/9169 Reviewed-by: Nick Connolly <nick.connolly@mayadata.io> Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com> Reviewed-by: Changpeng Liu <changpeng.liu@intel.com> Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com> Community-CI: Broadcom CI <spdk-ci.pdl@broadcom.com> Community-CI: Mellanox Build Bot Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
This commit is contained in:
parent
9ef1a55d0a
commit
92e75dfc28
7
Makefile
7
Makefile
@ -97,12 +97,7 @@ endif
|
||||
all: mk/cc.mk $(DIRS-y)
|
||||
clean: $(DIRS-y)
|
||||
$(Q)rm -f include/spdk/config.h
|
||||
$(Q)rm -rf build/bin
|
||||
$(Q)rm -rf build/fio
|
||||
$(Q)rm -rf build/examples
|
||||
$(Q)rm -rf build/include
|
||||
$(Q)rm -rf build/lib/pkgconfig
|
||||
$(Q)find build/lib ! -name .gitignore -type f -delete
|
||||
$(Q)rm -rf build
|
||||
|
||||
install: all
|
||||
$(Q)echo "Installed to $(DESTDIR)$(CONFIG_PREFIX)"
|
||||
|
1
build/lib/.gitignore
vendored
1
build/lib/.gitignore
vendored
@ -1 +0,0 @@
|
||||
# Placeholder
|
@ -358,6 +358,7 @@ BUILD_LINKERNAME_LIB=\
|
||||
LIB_C=\
|
||||
$(Q)echo " LIB $(notdir $@)"; \
|
||||
rm -f $@; \
|
||||
mkdir -p $(dir $@); \
|
||||
$(CCAR) crDs $@ $(OBJS)
|
||||
|
||||
# Clean up generated files listed as arguments plus a default list
|
||||
|
Loading…
Reference in New Issue
Block a user