telldus-core 2.1.1 running on OpenWRT

Moderator: Telldus

taliz
Posts: 9
Joined: Fri Mar 17, 2023 9:45 am

Re: telldus-core 2.1.1 running on OpenWRT

Post by taliz »

I downloaded the files from Lauri's post and attempted to compile it within the openwrt buildroot. But I seem to be getting iconv issues:


Code: Select all

  Scanning dependencies of target TelldusCommon
    make[5]: Leaving directory `/home/mw/openwrt/openwrt/build_dir/target-mips_34kc_uClibc-0.9.33.2/telldus-core-2.1.1'
    make[5]: Entering directory `/home/mw/openwrt/openwrt/build_dir/target-mips_34kc_uClibc-0.9.33.2/telldus-core-2.1.1'
    [  2%] Building CXX object common/CMakeFiles/TelldusCommon.dir/Event.cpp.o
    [  4%] Building CXX object common/CMakeFiles/TelldusCommon.dir/Message.cpp.o
    [  6%] Building CXX object common/CMakeFiles/TelldusCommon.dir/Mutex.cpp.o
    [  8%] Building CXX object common/CMakeFiles/TelldusCommon.dir/Strings.cpp.o
    /home/mw/openwrt/openwrt/build_dir/target-mips_34kc_uClibc-0.9.33.2/telldus-core-2.1.1/common/Strings.cpp: In function 'std::wstring TelldusCore::charToWstring(const char*)':
    /home/mw/openwrt/openwrt/build_dir/target-mips_34kc_uClibc-0.9.33.2/telldus-core-2.1.1/common/Strings.cpp:57:84: error: invalid conversion from 'const char**' to 'char**' [-fpermissive]
    /home/mw/openwrt/openwrt/staging_dir/target-mips_34kc_uClibc-0.9.33.2/usr/lib/libiconv-full/include/iconv.h:83:15: error:   initializing argument 2 of 'size_t libiconv(libiconv_t, char**, size_t*, char**, size_t*)' [-fpermissive]
    /home/mw/openwrt/openwrt/build_dir/target-mips_34kc_uClibc-0.9.33.2/telldus-core-2.1.1/common/Strings.cpp: In function 'std::string TelldusCore::wideToString(const wstring&)':
    /home/mw/openwrt/openwrt/build_dir/target-mips_34kc_uClibc-0.9.33.2/telldus-core-2.1.1/common/Strings.cpp:201:82: error: invalid conversion from 'const char**' to 'char**' [-fpermissive]
    /home/mw/openwrt/openwrt/staging_dir/target-mips_34kc_uClibc-0.9.33.2/usr/lib/libiconv-full/include/iconv.h:83:15: error:   initializing argument 2 of 'size_t libiconv(libiconv_t, char**, size_t*, char**, size_t*)' [-fpermissive]
    make[5]: *** [common/CMakeFiles/TelldusCommon.dir/Strings.cpp.o] Error 1
    make[5]: Leaving directory `/home/mw/openwrt/openwrt/build_dir/target-mips_34kc_uClibc-0.9.33.2/telldus-core-2.1.1'
    make[4]: *** [common/CMakeFiles/TelldusCommon.dir/all] Error 2
    make[4]: Leaving directory `/home/mw/openwrt/openwrt/build_dir/target-mips_34kc_uClibc-0.9.33.2/telldus-core-2.1.1'
    make[3]: *** [all] Error 2
    make[3]: Leaving directory `/home/mw/openwrt/openwrt/build_dir/target-mips_34kc_uClibc-0.9.33.2/telldus-core-2.1.1'
    make[2]: *** [/home/mw/openwrt/openwrt/build_dir/target-mips_34kc_uClibc-0.9.33.2/telldus-core-2.1.1/.built] Error 2
    make[2]: Leaving directory `/home/mw/openwrt/openwrt/package/utils/telldus-core'
    make[1]: *** [package/utils/telldus-core/compile] Error 2
    make[1]: Leaving directory `/home/mw/openwrt/openwrt'
    make: *** [package/utils/telldus-core/compile] Error 2


Any idea how to solve this?

EDIT: I see that I should have read the posts more carefully. The issue was the patched Strings.cpp.
I still have a problem with make menuconfig not finding the telldus-core package though. Eventhough I've put it under packages, also tried in the utils subdir which the makefile describes. If I force it in, by putting "CONFIG_PACKAGE_telldus-core=y" in .config I can then compile the package. But it then complains about dependencies, like this:

Code: Select all

-2.1.1/ipkg-ar71xx/telldus-core/usr/share/telldus-core/helpers/udev.sh
make[3]: Leaving directory `/home/mw/openwrt/openwrt/build_dir/target-mips_34kc_uClibc-0.9.33.2/telldus-core-2.1.1'
find /home/mw/openwrt/openwrt/build_dir/target-mips_34kc_uClibc-0.9.33.2/telldus-core-2.1.1/ipkg-ar71xx/telldus-core -name 'CVS' -o -name '.svn' -o -name '.#*' -o -name '*~'| xargs -r rm -rf
Package telldus-core is missing dependencies for the following libraries:
libftdi.so.1
libiconv.so.2
libpthread.so.0
libstdc++.so.6
make[2]: *** [/home/mw/openwrt/openwrt/bin/ar71xx/packages/telldus-core_2.1.1-1_ar71xx.ipk] Error 1
make[2]: Leaving directory `/home/mw/openwrt/openwrt/package/telldus-core'
make[1]: *** [package/telldus-core/compile] Error 2
make[1]: Leaving directory `/home/mw/openwrt/openwrt'
make: *** [package/telldus-core/compile] Error 2
EDIT2: Don't ask me how but I managed to compile it now. I moved the package into utils again. Then changed the depends in the makefile to " DEPENDS:=+confuse +libiconv-full +libftdi +libstdcpp". Then tried to compile again, it complained and said it was out of sync so I ran make menuconfig. Then telldus-core was suddenly there. So I tried to compile the package again and this time it worked!


I've detailed the steps I had to do to make telldus-core and remotestick-server run on my router here:
http://blog.stfu.se/?p=319
Post Reply