Procházet zdrojové kódy

buildsystem: deal with spaces in path to source

Git-Dch: Ignore
David Kalnischkies před 10 roky
rodič
revize
85a67355c0

+ 3 - 3
buildlib/configure.mak

@@ -55,8 +55,8 @@ aclocal.m4: $(wildcard buildlib/*.m4)
 	aclocal -I buildlib
 
 $(BUILDDIR)/configure-stamp: configure buildlib/config.guess buildlib/config.sub
-	/usr/bin/test -e $(BUILDDIR) || mkdir $(BUILDDIR)
-	(HERE=`pwd`; cd $(BUILDDIR) && $$HERE/configure)
-	touch $(BUILDDIR)/configure-stamp
+	/usr/bin/test -e '$(BUILDDIR)' || mkdir '$(BUILDDIR)'
+	(HERE="`pwd`"; cd '$(BUILDDIR)' && "$$HERE/configure")
+	touch '$(BUILDDIR)/configure-stamp'
 
 $(addprefix $(BUILDDIR)/,$(CONVERTED)): $(BUILDDIR)/configure-stamp

+ 1 - 1
buildlib/library.mak

@@ -67,7 +67,7 @@ $(LIB)/lib$(LIBRARY).so.$(MAJOR).$(MINOR): $($(LOCAL)-HEADERS) $($(LOCAL)-OBJS)
 vpath %.cc $(SUBDIRS)
 $(OBJ)/%.opic: %.cc $(LIBRARYDEPENDS)
 	echo Compiling $< to $@
-	$(CXX) -c $(INLINEDEPFLAG) $(CPPFLAGS) $(CXXSTD) $(CXXFLAGS) $(PICFLAGS) -o $@ $(abspath $<)
+	$(CXX) -c $(INLINEDEPFLAG) $(CPPFLAGS) $(CXXSTD) $(CXXFLAGS) $(PICFLAGS) -o $@ '$(abspath $<)'
 	$(DoDep)
 
 # Include the dependencies that are available

+ 1 - 1
buildlib/po4a_manpage.mak

@@ -51,7 +51,7 @@ clean/$(LOCAL):
 	rm -f $($(@F)-LIST) apt.ent apt-verbatim.ent
 veryclean/$(LOCAL):
 	# we are nuking the directory we are working in as it is auto-generated
-	rm -rf $(shell readlink -f .)
+	rm -rf '$(abspath .)'
 
 HAVE_PO4A=yes
 endif

+ 1 - 1
buildlib/program.mak

@@ -50,7 +50,7 @@ $($(LOCAL)-BIN): $($(LOCAL)-OBJS) $($(LOCAL)-MKS)
 vpath %.cc $(SUBDIRS)
 $(OBJ)/%.o: %.cc
 	echo Compiling $< to $@
-	$(CXX) -c $(INLINEDEPFLAG) $(CPPFLAGS) $(CXXSTD) $(CXXFLAGS) -o $@ $(abspath $<)
+	$(CXX) -c $(INLINEDEPFLAG) $(CPPFLAGS) $(CXXSTD) $(CXXFLAGS) -o $@ '$(abspath $<)'
 	$(DoDep)
 
 # Include the dependencies that are available

+ 1 - 1
buildlib/python.mak

@@ -58,7 +58,7 @@ endif  # ifdef PYTHONLIB
 vpath %.cc $(SUBDIRS)
 $(OBJ)/%.opic: %.cc
 	echo Compiling $< to $@
-	$(CXX) -c $(INLINEDEPFLAG) $(CPPFLAGS) $(CXXSTD) $(CXXFLAGS) $(PICFLAGS) -o $@ $(abspath $<)
+	$(CXX) -c $(INLINEDEPFLAG) $(CPPFLAGS) $(CXXSTD) $(CXXFLAGS) $(PICFLAGS) -o $@ '$(abspath $<)'
 	$(DoDep)
 
 # Include the dependencies that are available

+ 1 - 1
buildlib/staticlibrary.mak

@@ -50,7 +50,7 @@ endif
 vpath %.cc $(SUBDIRS)
 $(OBJ)/%.o: %.cc
 	echo Compiling $< to $@
-	$(CXX) -c $(INLINEDEPFLAG) $(CPPFLAGS) $(CXXSTD) $(CXXFLAGS) -o $@ $(abspath $<)
+	$(CXX) -c $(INLINEDEPFLAG) $(CPPFLAGS) $(CXXSTD) $(CXXFLAGS) -o $@ '$(abspath $<)'
 	$(DoDep)
 
 # Include the dependencies that are available

+ 1 - 1
doc/en/makefile

@@ -16,7 +16,7 @@ LOCAL := manpage-$(firstword $(SOURCE))
 $(LOCAL)-LIST := $(SOURCE)
 
 apt-vendor.ent: ../../vendor/current/apt-vendor.ent
-	ln -sf $(shell readlink -f $^) $@
+	ln -sf '$(abspath $^)' $@
 
 # Install generation hooks
 manpages: $($(LOCAL)-LIST)

+ 2 - 2
doc/makefile

@@ -13,10 +13,10 @@ include $(DOCBOOK_H)
 doc: manpages docbook
 
 examples/sources.list: ../vendor/current/sources.list
-	ln -sf $(shell readlink -f $^) $@
+	ln -sf '$(abspath $^)' $@
 
 apt-vendor.ent: ../vendor/current/apt-vendor.ent
-	ln -sf $(shell readlink -f $^) $@
+	ln -sf '$(abspath $^)' $@
 
 # Examples
 SOURCE = examples/apt.conf examples/sources.list examples/configure-index examples/apt-https-method-example.conf