How to write/append the compiler output to a logfile
"Arndt Pauschardt" <[email protected]>
| Newsgroups | gmane.comp.programming.tools.scons.user |
|---|---|
| Message-ID | <trinity-b7387120-a5aa-4532-beb6-0858aafb3435-1576066247364@3c-app-webde-bs31> |
Hi, everyone I would need a little advice ... I would like to write/append the compiler command line and the actual compiler output (its warnings, errors, ...) into a logfile. At the same time, I would like to keep the *COMSTR functionality of SCons so that the console output is showing what e.g CCCOMSTR is set to and the logfile has the output of CCCOM. I guess a possible solution is to tweak CCCOM from 'CCCOM': '$CC -o $TARGET -c $CFLAGS $CCFLAGS $_CCCOMCOM $SOURCES', to sth like 'CCCOM': '$CC -o $TARGET -c $CFLAGS $CCFLAGS $_CCCOMCOM $SOURCES > $CCLOGFILE' but I'm not sure whether this is good solution: - to me, CCCOM is "owned" by the builder, in this case it would tbe gcc builder. So tweaking it is like reaching out into someone else's pocket. - I would like to use logfile as a source for a post-compile/link step, so it is not only a logfile, but also a target of the compile step and a source of a post-compile step. Therefore, CCCOM should look more like 'CCCOM': '$CC -o $TARGET[0] -c $CFLAGS $CCFLAGS $_CCCOMCOM $SOURCES' > $TARGET[1]' but that's really changing CCCOM, so the (gcc) builder will not be happy. So, all in all: How would/are you doing this? I googled it and searched the mailing list, but nothing substantial turned up so far. Thx Arndt _______________________________________________ Scons-users mailing list [email protected] https://pairlist4.pair.net/mailman/listinfo/scons-users