dankamongmen / growlight

notcurses block device manager / system installation tool
https://nick-black.com/dankwiki/index.php/Growlight
GNU General Public License v3.0
84 stars 12 forks source link

GPT test fails to compile on openSUSE Tumbleweed #141

Open mnhauke opened 3 years ago

mnhauke commented 3 years ago

GTP test fails to build on recent openSUSE Tumbleweed versions

[   18s] /usr/bin/c++ -DFORTIFY_SOURCE=2 -D_DEFAULT_SOURCE -D_GNU_SOURCE -D_XOPEN_SOURCE=600 -I/home/abuild/rpmbuild/BUILD/growlight-1.2.31/src -I/home/abuild/rpmbuild/BUILD/growlight-1.2.31/build/include -I/home/abuild/rpmbuild/BUILD/growlight-1.2.31 -I/usr/include/blkid -O2 -Wall -D_FORTIFY_SOURCE=2 -fstack-protector-strong -funwind-tables -fasynchronous-unwind-tables -fstack-clash-protection -Werror=return-type -flto=auto -g -DNDEBUG -O2 -g -DNDEBUG -fvisibility=hidden -Wall -Wextra -W -Wshadow -Wformat -fexceptions -std=c++17 -o CMakeFiles/growlight-tester.dir/tests/gpt.cpp.o -c /home/abuild/rpmbuild/BUILD/growlight-1.2.31/tests/gpt.cpp
[   18s] In file included from /home/abuild/rpmbuild/BUILD/growlight-1.2.31/tests/main.h:4,
[   18s]                  from /home/abuild/rpmbuild/BUILD/growlight-1.2.31/tests/gpt.cpp:1:
[   18s] /home/abuild/rpmbuild/BUILD/growlight-1.2.31/tests/gpt.cpp: In function 'void _DOCTEST_ANON_FUNC_2()':
[   18s] /home/abuild/rpmbuild/BUILD/growlight-1.2.31/tests/gpt.cpp:22:30: error: cannot bind packed field 'head.gpt_header::revision' to 'unsigned int&'
[   18s]    22 |     CHECK(0x00010000 == head.revision);
[   18s]       |                         ~~~~~^~~~~~~~
[   18s] /home/abuild/rpmbuild/BUILD/growlight-1.2.31/tests/gpt.cpp:29:22: error: cannot bind packed field 'head.gpt_header::headsize' to 'unsigned int&'
[   18s]    29 |     CHECK(92 == head.headsize);
[   18s]       |                 ~~~~~^~~~~~~~
[   18s] /home/abuild/rpmbuild/BUILD/growlight-1.2.31/tests/gpt.cpp:37:21: error: cannot bind packed field 'head.gpt_header::lba' to 'long unsigned int&'
[   18s]    37 |     CHECK(1 == head.lba);
[   18s]       |                ~~~~~^~~
[   18s] /home/abuild/rpmbuild/BUILD/growlight-1.2.31/tests/gpt.cpp:38:26: error: cannot bind packed field 'head.gpt_header::backuplba' to 'long unsigned int&'
[   18s]    38 |     CHECK(100000 == head.backuplba);
[   18s]       |                     ~~~~~^~~~~~~~~
[   18s] /home/abuild/rpmbuild/BUILD/growlight-1.2.31/tests/gpt.cpp:64:20: error: cannot bind packed field 'head.gpt_header::partsize' to 'unsigned int&'
[   18s]    64 |     CHECK(0 < head.partsize);
[   18s]       |               ~~~~~^~~~~~~~
[   18s] /home/abuild/rpmbuild/BUILD/growlight-1.2.31/tests/gpt.cpp:67:23: error: cannot bind packed field 'head.gpt_header::partcount' to 'unsigned int&'
[   18s]    67 |     CHECK(128 <= head.partcount);
[   18s]       |                  ~~~~~^~~~~~~~~
[   18s] /home/abuild/rpmbuild/BUILD/growlight-1.2.31/tests/gpt.cpp:72:29: error: cannot bind packed field 'head.gpt_header::crc' to 'unsigned int&'
[   18s]    72 |     WARN(2006165414 == head.crc);
[   18s]       |                        ~~~~~^~~
[   18s] /home/abuild/rpmbuild/BUILD/growlight-1.2.31/tests/gpt.cpp:73:21: error: cannot bind packed field 'head.gpt_header::reserved' to 'unsigned int&'
[   18s]    73 |     CHECK(0 == head.reserved);
[   18s]       |                ~~~~~^~~~~~~~
[   18s] /home/abuild/rpmbuild/BUILD/growlight-1.2.31/tests/gpt.cpp:74:30: error: cannot bind packed field 'head.gpt_header::partcrc' to 'unsigned int&'
[   18s]    74 |     CHECK(2874462854 == head.partcrc);
[   18s]       |                         ~~~~~^~~~~~~
[   18s] /home/abuild/rpmbuild/BUILD/growlight-1.2.31/tests/gpt.cpp:88:23: error: cannot bind packed field 'head->gpt_header::headsize' to 'unsigned int&'
[   18s]    88 |     CHECK(92 == head->headsize);
[   18s]       |                 ~~~~~~^~~~~~~~
[   18s] make[2]: *** [CMakeFiles/growlight-tester.dir/build.make:488: CMakeFiles/growlight-tester.dir/tests/gpt.cpp.o] Error 1
[   18s] make[2]: Leaving directory '/home/abuild/rpmbuild/BUILD/growlight-1.2.31/build'

growlight-openSUSE-Tumbleweed-failure-full-buildlog.txt

dankamongmen commented 3 years ago

Thanks for the report! Do you happen to know what architecture this is? Actually it doesn't matter, this isn't even compiling. I'll look into this ASAP.

mnhauke commented 3 years ago

All architectures seem to be affected ... https://build.opensuse.org/package/show/filesystems/growlight

dankamongmen commented 3 years ago

i'm about to head to the airport, but i'll try to get to this tonight after i land.

dankamongmen commented 3 years ago

hrmm. i don't see much that can fix this other than...ok i think i see a fix. @mnhauke will you be able to test a fix? if so, and you confirm a good fix, i'll cut a release.

dankamongmen commented 3 years ago

OK, hopefully this fixes the issue.

mnhauke commented 3 years ago

Thanks for fix. It's working fine here: https://build.opensuse.org/package/show/home:mnhauke/growlight

dankamongmen commented 3 years ago

Thanks for fix. It's working fine here: https://build.opensuse.org/package/show/home:mnhauke/growlight

awesome, thanks a lot. i've cut 1.2.32.