- Package:
- libdpkg-perl
- Source:
- libdpkg-perl
- Submitter:
- VSYakovetsky
- Date:
- 2023-07-04 07:15:03 UTC
- Severity:
- normal
Dear Maintainer,
*** Reporter, please consider answering these questions, where appropriate ***
* What led up to the situation?
- building deb package with dpkg-buildpackage and clang
- hardcoded -ffat-lto-objects cc flag in scripts/Dpkg/Vendor/Debian.pm
https://git.dpkg.org/git/dpkg/dpkg.git/tree/scripts/Dpkg/Vendor/Debian.pm#n451
* What exactly did you do (or not do) that was effective (or ineffective)?
CC=clang dpkg-buildpackage ...
* What was the outcome of this action?
clang: warning: optimization flag '-ffat-lto-objects' is not supported [-Wignored-optimization-argument]
* What outcome did you expect instead?
not sorting out rare flags specific to one compiler
(a possible workaround was manually set DEB_CFLAGS_STRIP=-ffat-lto-objects in environment)
*** End of the template - remove these template lines ***
Hi! This has come up in the past, and while it would be nice to be able to support multiple compilers in general for a specific vendor the build flags default and are adapted just to the default compiler for that distribution. Here's mail covering what autodetection would involve if this was to be supported: https://lists.debian.org/debian-dpkg/2014/06/msg00050.html Yes, in this case if you change the compiler, then you need to adapt any such build flags that might not play well with it. So, I'm afraid there's not much that can be done here. Perhaps this could be documented somewhere more prominently, but I'm not sure where, perhaps the dpkg-buildpackage or dpkg-buildflags man pages or similar, not sure if that would have helped in your case? Otherwise, I'm inclined to probably be closing this in a bit. Thanks, Guillem
Hi! I got a reply off-BTS where VSYakovetsky mentioned it would be fine to close. I still think this could do with some documentation somewhere so I'll ponder about this, and otherwise either will improve some docs… …or if I don't come up with anything will be closing it. Thanks, Guillem