Re: How to deal with spaces within target path?

"Paul D. Smith" <[email protected]>
Newsgroups gmane.comp.gnu.utils
Organization GNU's Not Unix!
Message-ID <[email protected]>
%% [email protected] writes:

  a> This is GNU Make 3.80 on Mac OSX. I'm running into a problem where
  a> spaces in a target name within the makefile are causing it to be
  a> interpreted as separate targets. Using the typical solution of
  a> putting quotes around the path doesn't seem to work within the
  a> makefile. Does anyone know of a way to specify that spaces should
  a> be treated as part of the path name? Here is the offending line in
  a> the makefile: ${ObjD}%.N.cln : %.asm ${ExtraDeps}; ${GenAsmRule}

In general there's really no completely bullet-proof way to use
pathnames with whitespace in them.  Your best bet is to avoid them
altogether.


However, in some situations you can escape whitespace with a backslash.

-- 
-------------------------------------------------------------------------------
 Paul D. Smith <[email protected]>          Find some GNU make tips at:
 http://www.gnu.org                      http://make.paulandlesley.org
 "Please remain calm...I may be mad, but I am a professional." --Mad Scientist
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.