[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Using Makefile for copy files into a package



On to, 2007-01-11 at 10:45 +0000, Rodrigo Tavares wrote:
> I set in my makefile:
> package = mypackage
> install -m 755 debian/scripts-bd/script.sh
> $$packagename/opt/

If those are two successive lines of commands for a target in a
Makefile, then it won't work like that. Every line is executed as a
separate process, and any environment variables you set in the first
line will disappear before the second line is executed. You need to
combine them into a single shell command line for it to work. Or you can
use make variable. Alternatively, the problem may be that you set the
variable "package", but refer to "packagename". As a third option, it
might be that you set the variable as a make variable (the spaces around
the equals sign indicate that), but refer to it as an environment
variable (the double dollar sign); the correct way to refer to a make
variable is $(package).

-- 
I am an artist. Source code is my canvas, a programming language is my
paint.



Reply to: