cons-discuss
[Top][All Lists]
Advanced

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

RE: Dependencies between "build" and "dist"


From: Kumar, Arun (PIT)
Subject: RE: Dependencies between "build" and "dist"
Date: Mon, 6 Aug 2001 11:50:11 -0400

Hi,
  Thanks for your reply. Here are my details:
1. The "cons build" works fine with all dependencies well defined.
2. The "cons build dist" which makes "src/dist/Conscript" in addition to the
build/Conscript, is the issue:
I have the following in my src/dist/Conscript:
    Command $env
        "$DIST/$PKG/pkgmap",
        "$prototype",
        "pkgmk -o -d $dest_dir -f %1 -p $version -v $product_info " . 
            "INSTALL_DIR=$BUILD_ROOT $PKG";

The build/Conscript makes the build and puts the files in certain
directories (indicated by $BUILD_ROOT in the above command). Now the
src/dist/Conscript uses that directory and searches for the files defined in
the prototype. And then the pkgmk is run. It runs fine and the distribution
is made.

What I want to do is that if everything is up-to-date in the build area, the
src/dist/Conscript should not try to execute pkgmk at all. Currently it is
*always* executing it whether the build area has been modified or not.

The target specified in the above pkgmk command ($DIST/$PKG/pkgmap), is
actually indeed the target which is created as a result of pkgmk command. I
have tried specifying dependencies, but nothing worked.

Thanks
Arun 

-----Original Message-----
From: Steven Knight [mailto:address@hidden
Sent: Monday, August 06, 2001 11:30 AM
To: Kumar, Arun (PIT)
Cc: 'address@hidden'
Subject: Re: Dependencies between "build" and "dist"


On Mon, 6 Aug 2001, Kumar, Arun (PIT) wrote:
>   I have a question for Cons experts. This is specifically related to
> Solaris build. How can one specify in src/dist/Conscript (the dist
Conscript
> file), a dependency such that the "pkgmk" only is done when something in
> build area is built. In other words, pkgmk in the dist area always happens
> whether it is needed or not. Let me know if any specific details of the
> command is needed.

If Cons is executing a command every time you run it, and that's not
what you want, the most likely cause is that the executed command does
not create the target file specified.  As a trivial example:

        $env->Command('.always', 'input', "cat input > output");

Will *always* run the "cat input > outfile" command because the .always
file is never created by it.  Take a look at the target file specified
for your "pkgmk" call.

Beyond that general advice, additional details would help.

        --SK


_______________________________________________
address@hidden
http://mail.gnu.org/mailman/listinfo/cons-discuss
Cons URL: http://www.dsmit.com/cons/



reply via email to

[Prev in Thread] Current Thread [Next in Thread]