[Scons-users] Storing object files in different directory

Christopher Dimech dimech.christopher at gmail.com
Sun Oct 12 13:24:33 EDT 2014


Right now I am trying various possible ways to
do things, helps getting to know the necessary
details. I plan to use SConscipt next.



On 12 October 2014 18:18, Gary Oberbrunner <garyo at oberbrunner.com> wrote:

> It might work if you split up the SConstruct and SConscript.
> VariantDir isn't perfect when used the way you're using it.
>
> At the very least, since you're resistant to putting SConscripts in
> each subdir, you could have one at top level:
>
> SConstruct:
> SConscript('botoh.sc', variant_dir='build')
>
> then it should put _everything_ in build.  You'll have to use Install
> to install the final thing into '#' which means top-level.
>
> But as I said, I don't know much about Fortran so I can't say for sure.
>
>
> On Sun, Oct 12, 2014 at 1:05 PM, Christopher Dimech
> <dimech.christopher at gmail.com> wrote:
> > Yes, it picks up the .mod file, however it is  not created
> > in /build/lib as defined in the VariantDir. Have also used
> > the compiler option -Ibuild/lib
> >
> > However the change did not work. The file still being
> > created as ./endian.mod
> >
> > On 12 October 2014 17:58, Gary Oberbrunner <garyo at oberbrunner.com>
> wrote:
> >>
> >> I'm not a Fortran expert, but I believe SCons can automatically find
> >> required modules by scanning the main Fortran code, and build them and
> >> link with them automatically.  Have you looked at
> >> http://www.scons.org/wiki/llarsen/FortranTutorial?
> >>
> >> As for spacing, you're right -- SCons files are python, and as such
> >> has the same whitespace considerations as any other python source
> >> file.
> >>
> >> On Sun, Oct 12, 2014 at 12:35 PM, Christopher Dimech
> >> <dimech.christopher at gmail.com> wrote:
> >> > There is one thing remaining on this, the .mod file is being created
> >> > at the location of the SConstruct file, i.e. in vik/endian.mod. I want
> >> > to have it created in vik/build/lib. Any way to do this this with .mod
> >> > files. The .mod files is what differs when using fortran, as modules
> >> > create both a .o file as well as a .mod file.
> >>
> >>
> >> --
> >> Gary
> >> _______________________________________________
> >> Scons-users mailing list
> >> Scons-users at scons.org
> >> https://pairlist4.pair.net/mailman/listinfo/scons-users
> >
> >
> >
> >
> > --
> > Christopher Dimech
> >
> > _______________________________________________
> > Scons-users mailing list
> > Scons-users at scons.org
> > https://pairlist4.pair.net/mailman/listinfo/scons-users
> >
>
>
>
> --
> Gary
> _______________________________________________
> Scons-users mailing list
> Scons-users at scons.org
> https://pairlist4.pair.net/mailman/listinfo/scons-users
>



-- 
Christopher Dimech
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://pairlist4.pair.net/pipermail/scons-users/attachments/20141012/b16de7df/attachment.html>


More information about the Scons-users mailing list