-
Notifications
You must be signed in to change notification settings - Fork 990
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Capture build log in package #4689
Comments
Hi @rconde01! One of the main issues about including a log file into the package is that it will be considered part of the package and it will be taken into account to compute its hash. So, any change to this logfile will create a different package... I find it quite difficult to include this functionality into Conan. Nevertheless, some versions ago, we implemented hooks, they allow the user to plug-in some behavior at certain points. Using hooks, you can add a file (the trace file) to your package in the |
Hi! I'm trying to think this through a bit:
|
As Conan is implemented right now (taking into account compatibility with previous versions) that file should be inside the The problem with different hashes depends on who/where/how that log file is generated. If it is the Other approaches:
|
Won't that be true in general for any packages containing built binaries? I.e. the binaries contain meta data like the build time etc. which would cause a change? |
Yes, you are right, it is not an argument against it. Implementing something like this will require piping all the outputs related to one package (Conan output and subprocesses ones) to a common place and then write it down into a file that will be stored within the package. For sure the Nevertheless, if you want to track your tools versions, the best you can do is packaging those tools too. I know it is orthogonal answer related to the log file one, but it could give you fully reproducible packages. |
Ok - thanks for the thoughts! Yes, I agree if you very specifically want to get the tools versions then there are other reasonable/better ways to accomplish that. But I still think there's a general value to capturing that build log as well. |
This has been implemented already in Conan 2.0.7 in the "metadata" (still not documented) and will be finalized and released in 2.0.8 (#14152) |
I originally brought this up in #814 but now looking at the proposed solution #884 it is not what I expected. The idea was to automatically include the log in the package so that if you go to look at your package and something seems wrong (or you just want to confirm something), you can look at the log to get some insight. In other words, it gives you some traceability into how the package was created. Maybe the package build uses a tool (e.g. Cmake) and the log let's you know what version of cmake was used to build the package. Or a specific version of a compiler (where maybe the profile isn't as specific as you want to know).
The text was updated successfully, but these errors were encountered: