[A-a-p-user] Quoting in attributes of :program targets
Brought to you by:
vimboss
From: Adriaan de G. <ad...@cs...> - 2003-07-29 10:25:07
|
Hi Bram et al., Thanks for all the answers yesterday. It makes quite a difference when someone demonstrates how to do something, as opposed to trying to figure it out from the manual and tutorial (which could certainly be expanded; it covers some very simple cases but not much more than that, and the overlap with the user manual is enormous -- I'll see what I can do.). Anyway, today's problem comes from the following "Hello World" recipe: LIBS=-L/usr/local/qt-3.1.1/lib :program t { add_LIBS = -pthread -lqt-mt } : t.c fairly straightforward, but the attribute add_LIBS (is it an attribute?) is handled wrongly, for when I execute AAP: eggs.ebn.kun.nl$aap Aap: cc -O2 -o t build-FreeBSD4_8_STABLE/t.o -L/usr/local/qt-3.1.1/lib "-pthread -lqt-mt" cc: unrecognized option `-pthread -lqt-mt' Naturally! Those quotes there are all wrong. Trying to work around this by assigning -pthread -lqt-mt to a variable, and using { add_LIBS = $t_LIBADD } yields the same result. What to do, what to do? This would be of importance in a recipe where multiple programs are built from a single recipe, and where you need to specify the libraries for each. (Incidentally, :program t { LIBS = -pthread -lqt-mt } : t.c doesn't do what I'd expect either, but that's because LIBS is a variable, and not an attribute (duh). Using var_LIBS = yields the same quoting problem as with add_LIBS) -- pub 1024D/FEA2A3FE 2002-06-18 Adriaan de Groot <gr...@kd...> Key fingerprint = 934E 31AA 80A7 723F 54F9 50ED 76AC EE01 FEA2 A3FE |