Skip to content
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

libupm does not compile with GCC11 #16060

Closed
neheb opened this issue Jul 7, 2021 · 3 comments
Closed

libupm does not compile with GCC11 #16060

neheb opened this issue Jul 7, 2021 · 3 comments

Comments

@neheb
Copy link
Contributor

neheb commented Jul 7, 2021

Maintainer: @nxhack
Environment: GCC11

FAILED: src/nrf8001/CMakeFiles/nrf8001.dir/aci_setup.cpp.o
/home/mangix/devstuff/openwrt/staging_dir/host/bin/ccache /home/mangix/devstuff/openwrt/staging_dir/toolchain-mips64el_mips64r2_64_gcc-11.1.0_musl/bin/mips64el-openwrt-linux-musl-g++ -Dnrf8001_EXPORTS -I../include -I../src/nrf8001 -Isrc/nrf8001/.. -Os -pipe -mno-branch-likely -mips64r2 -mtune=mips64r2 -mabi=64 -fno-caller-saves -fno-plt -fhonour-copts -Wno-error=unused-but-set-variable -Wno-error=unused-result -msoft-float -fmacro-prefix-map=/home/mangix/devstuff/openwrt/build_dir/target-mips64el_mips64r2_64_musl/upm-2.0.0=upm-2.0.0 -Wformat -Werror=format-security -DPIC -fpic -fstack-protector-strong -D_FORTIFY_SOURCE=2 -Wl,-z,now -Wl,-z,relro  -Wall -Wno-strict-aliasing -Wno-deprecated-declarations -Wno-misleading-indentation -Werror -Wnon-virtual-dtor -Woverloaded-virtual -Wsign-compare -Wreorder -DNDEBUG -fPIC -std=gnu++11 -MD -MT src/nrf8001/CMakeFiles/nrf8001.dir/aci_setup.cpp.o -MF src/nrf8001/CMakeFiles/nrf8001.dir/aci_setup.cpp.o.d -o src/nrf8001/CMakeFiles/nrf8001.dir/aci_setup.cpp.o -c ../src/nrf8001/aci_setup.cpp
../src/nrf8001/aci_setup.cpp: In function 'uint8_t do_aci_setup(aci_state_t*)':
../src/nrf8001/aci_setup.cpp:144:64: error: array subscript 'aci_evt_t[0]' is partly outside array bounds of 'hal_aci_data_t [1]' [-Werror=array-bounds]
  144 |       cmd_status = (aci_status_code_t) aci_evt->params.cmd_rsp.cmd_status;
      |                                        ~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~
../src/nrf8001/aci_setup.cpp:42:23: note: while referencing 'msg_to_send'
   42 | extern hal_aci_data_t msg_to_send;
      |                       ^~~~~~~~~~~
cc1plus: all warnings being treated as errors
@nxhack
Copy link
Contributor

nxhack commented Jul 7, 2021

I cannot prepare an environment to test with gcc-11. I'll do it later.

@neheb
Copy link
Contributor Author

neheb commented Jul 7, 2021

My test was with openwrt/openwrt#4343

nxhack added a commit to nxhack/packages that referenced this issue Jul 7, 2021
openwrt#16060

Signed-off-by: Hirokazu MORIKAWA <morikw2@gmail.com>
1715173329 pushed a commit to immortalwrt/packages that referenced this issue Jul 13, 2021
openwrt/packages#16060

Signed-off-by: Hirokazu MORIKAWA <morikw2@gmail.com>
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
@neheb
Copy link
Contributor Author

neheb commented Jul 15, 2021

This was sort of fixed. At least it compiles now.

@neheb neheb closed this as completed Jul 15, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants