- removed comment
Formaline doesn't understand CACTUS_CONFIGS_DIR
When building with Formaline and CACTUS_CONFIGS_DIR one sees error messages of the form seen below. It is easily fixed though. See patch.
COMPILING /home/sbrandt/workspace/funwave2/Cactus/src/main/Parameters.c
Updating /home/sbrandt/.mojaveconfig/funwave2/Cfg1/lib/libthorn_Cactus.a
Checking status of thorn CactusBindings
find: configs/Cfg1/ThornList': No such file or directory
find:
configs/Cfg1/config-data': No such file or directory
find: `configs/Cfg1/config-info': No such file or directory
Keyword: Formaline
Comments (23)
-
-
reporter - changed status to open
- removed comment
-
- removed comment
As hinted earlier, this will only work if CACTUS_CONFIGS_DIR is a relative path (i.e. does not start with a slash) that points to a subdirectory (i.e. does not use ".." to escape to a different location). Is that the case here? (Probably not.)
These conditions should also be tested, with errors if they are violated.
The best solution is probably to create a directory "configs" somewhere, copy the files there, and then run the tar/git commands there, and then remove this new "configs" directory again.
On a different note: It is also debatable that this information should be combined with the flesh. Probably, a new tarball named "config" should be created for this.
-
reporter - removed comment
I'm a little confused. I do use an absolute path to build, and everything works fine (or seems to, Formaline tarballs get built in the right place). I notice, however, that if I don't use an absolute path then hwloc won't build. Is CACTUS_CONFIGS_DIR meant to accept only an absolute path or is hwloc broken?
-
- removed comment
If you use an absolute path: Do the Formaline tarballs contain the thorn list? If so, in what subdirectory of the tarball is it?
I do not know why hwloc won't build. What is the error message?
-
reporter - removed comment
The ThornList is in flesh-Cactus.tar.gz. It's location is showing up as
home/sbrandt/.mojaveconfig/funwave2/Cfg1/ThornList
About hwloc: On line 113 of configure.sh in hwloc is the command "cd ${SCRATCH_BUILD}". At the time this commmand is invoked, the current directory isn't Cactus root but the config-data directory, so it fails. It is the first of about a half dozen or so commands where an absolute path is required. Maybe this should be it's own ticket?
-
reporter - changed status to resolved
- removed comment
-
- removed comment
The tarball flesh-Cactus.tar.gz should contain the thorn list and related files directly in a directory "configs"; if it is hidden in a subdirectory called "home/...", it will be difficult to find. Note that the leading slash of "/home/sbrandt" has been removed by tar, so that untarring the tarball will create a directory hierarchy that originally didn't even exist...
This is not specific to hwloc; many other thorns do the same. You probably only see the error in hwloc since you either don't build the other thorns, or would build them after hwloc. I assume that CACTUS_CONFIGS_DIR needs to be an absolute path.
Why did you just close this ticket?
-
reporter - removed comment
I didn't close the ticket.
-
reporter - changed status to open
- removed comment
-
reporter - changed status to open
- removed comment
-
reporter - removed comment
I'm not sure what happened with the ticket closing.
-
reporter - removed comment
My latest effort at fixing the problem uses tar's --transform option. Please take a look.
-
- removed comment
On my system:
$ tar --transform tar: Option --transform is not supported Usage: List: tar -tf <archive-filename> Extract: tar -xf <archive-filename> Create: tar -cf <archive-filename> [filenames...] Help: tar --help
It seems this is not a standard option.
Also, I notice that you replace >$@ by >>$@; is this intentional?
-
reporter - removed comment
An uglier less efficient solution that works with older versions of tar. Sigh.
-
- removed comment
I think the best way to proceed is to put configuration settings into a tarball of their own. That would clean up the code, since nothing has to be copied, and would also advertise these settings more, as they are not really part of the flesh anyway.
-
- removed comment
Please try the attached patch.
-
- removed milestone
- removed comment
-
reporter - changed status to open
- removed comment
-
- removed comment
- changed watchers to sbrandt@cct.lsu.edu
Hasn't this been applied, Steve? Didn't you mention today, that an update of Formaline should understand this now?
-
reporter - removed comment
It has not yet been applied.
-
- removed comment
Can you please apply it?
-
reporter - changed status to resolved
- removed comment
I have applied Erik's patch.
- Log in to comment
Is CACTUS_CONFIGS_DIR an absolute or a relative path? Could it be a symbolic link? tar and git behave differently (and possibly strangely) in these cases. It may be necessary copy the relevant files from the configuration to a separate place before tarring/gitting them.