On 13.01.2016 15:06, Martin Kletzander wrote: > When building with gcc-5 (particularly gcc-5.3.0 now) and having pdwtags > installed (package dwarves) make check fails with the following error: > > $ make lock_protocol-struct > GEN lock_protocol-struct > --- lock_protocol-structs 2016-01-13 15:04:59.318809607 +0100 > +++ lock_protocol-struct-t3 2016-01-13 15:05:17.703501234 +0100 > @@ -26,10 +26,6 @@ > virLockSpaceProtocolNonNullString name; > u_int flags; > }; > -enum virLockSpaceProtocolAcquireResourceFlags { > - VIR_LOCK_SPACE_PROTOCOL_ACQUIRE_RESOURCE_SHARED = 1, > - VIR_LOCK_SPACE_PROTOCOL_ACQUIRE_RESOURCE_AUTOCREATE = 2, > -}; > struct virLockSpaceProtocolAcquireResourceArgs { > virLockSpaceProtocolNonNullString path; > virLockSpaceProtocolNonNullString name; > Makefile:10415: recipe for target 'lock_protocol-struct' failed > make: *** [lock_protocol-struct] Error 1 > > That happens because without any specific options gcc doesn't keep enum > information in the resulting binary object. I managed to isolate the > parameters of gcc that caused this issue to disappear, however I > remember that they influenced the resulting binaries quite a bit and > were definitely not something we would want to add as mandatory to the > build process. > > So to deal with this cleanly, let's take that enum and separate it out > to its own header file. Since it is only used in the lockd driver and > the protocol, lock_driver_lockd.h feels like a suitable name. > > Signed-off-by: Martin Kletzander <mkletzan@xxxxxxxxxx> > --- > src/Makefile.am | 1 + > src/lock_protocol-structs | 4 ---- > src/locking/lock_driver_lockd.c | 2 ++ > src/locking/lock_driver_lockd.h | 30 ++++++++++++++++++++++++++++++ > src/locking/lock_protocol.x | 6 +----- > 5 files changed, 34 insertions(+), 9 deletions(-) > create mode 100644 src/locking/lock_driver_lockd.h > ACK, but I'd rather wait until after the release. Michal -- libvir-list mailing list libvir-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/libvir-list