The _init() function collides with a _init() function in crti.o.
This results in the following error in OpenWrt:
arc-openwrt-linux-gnu/bin/ld: libxt_coova.o: in function `_init':
/lib/gcc/arc-openwrt-linux-gnu/11.3.0/crti.o:(.init+0x4): first defined here
collect2: error: ld returned 1 exit status
make[7]: *** [Makefile:22: libxt_coova.so] Error 1
Fix this by suing a constructor attribute instead. This function will
still be called after the shared library was loaded.
The _init() function collides with a _init() function in crti.o. This results in the following error in OpenWrt: arc-openwrt-linux-gnu/bin/ld: libxt_coova.o: in function `_init': /lib/gcc/arc-openwrt-linux-gnu/11.3.0/crti.o:(.init+0x4): first defined here collect2: error: ld returned 1 exit status make[7]: *** [Makefile:22: libxt_coova.so] Error 1
Fix this by suing a constructor attribute instead. This function will still be called after the shared library was loaded.
Fixes: #553 Signed-off-by: Hauke Mehrtens hauke@hauke-m.de