Closed Deema35 closed 2 years ago
What I cannot see is if libtorrent actually built successfully so do this using these commands
boost_version='77'
build_dir="$HOME/lt-build"
mkdir "$HOME/lt-build" && cd "${build_dir}"
Download boost
curl -sNLk https://boostorg.jfrog.io/artifactory/main/release/1.${boost_version}.0/source/boost_1_${boost_version}_0.tar.gz --create-dirs -o "${build_dir}/boost_1_${boost_version}_0.tar.gz"
tar xf "${build_dir}/boost_1_${boost_version}_0.tar.gz" -C "${build_dir}"
pushd "${build_dir}/boost_1_${boost_version}_0/" || exit
"${build_dir}/boost_1_${boost_version}_0/bootstrap.sh"
Build libtorrent
export BOOST_BUILD_PATH="${build_dir}/boost_1_${boost_version}_0"
git clone --single-branch --branch RC_2_0 --shallow-submodules --recurse-submodules --depth 1 https://github.com/arvidn/libtorrent "${build_dir}/libtorrent"
pushd "${build_dir}/libtorrent" || exit
"${build_dir}/boost_1_${boost_version}_0/b2" -j"$(nproc)" optimization=speed crypto=openssl cxxstd=17 variant=release threading=multi link=static boost-link=static install --prefix="${build_dir}/libs"
Are there any errors in the build at that end? You want to see something like this
gcc.archive bin/gcc-8/release/crypto-openssl/cxxstd-17-iso/link-static/threading-multi/visibility-hidden/libtorrent-rasterbar.a
common.copy /home/username/lt-build/libs/lib/libtorrent-rasterbar.a
...updated 480 targets...
Not you don't understen me. Libtorrent build is right. But it generate file torrent-rasterbar-pkgconfig/compile-settings-expanded.cmake with symbols @ and errors appears durring Qbittorrent building. If I remove symbols @ building Qbittorrent prossed too.
I compile Qbittorrent for OpenWRT and it compile with OpenWRT SDK, because of this I can't change building procedure.
I really don't understand. There is a hard language barrier here.
Taking into account this https://github.com/qbittorrent/qBittorrent/issues/15425 and that you want to use cmake instead of b2
Here is a guide i made for Alpine using cmake and it might help
https://github.com/qbittorrent/qBittorrent/wiki/Compilation:-Alpine-Linux
OpenWRT this is not Alpine Linux, this is OS for routers. It have different build system when you build your software with router's firmware together. You can read there https://openwrt.org/docs/guide-developer/package-policies
Yes qbittorrent 4.4.0beta3 not run after compilation, but this is beta release.
I can build Qbittorrent, but every time I need remove symbols @ from file: torrent-rasterbar-pkgconfig/compile-settings-expanded.cmake.
I think you are not understanding since Alpine linux uses musl and busybox. The working method i gave you for Alpine might help you on this platform.
https://en.wikipedia.org/wiki/OpenWrt > The main components are Linux, util-linux, musl,[4] and BusyBox.
I want the file torrent-rasterbar-pkgconfig/compile-settings-expanded.cmake to be generated without simbols @, because it breake qbittorrent building. How this is tutorial can help me?
This is make file for Libtorrent in OpenWRT https://github.com/openwrt/packages/blob/master/libs/libtorrent-rasterbar/Makefile.
Here is a build made on alpine. The matching aarch should work on your OS.
https://github.com/userdocs/test/releases/tag/release-4.4.0beta3_RC_2_0
You need to show exactly what are you are doing and how. What steps to build , what commands.
Please, show all the commands and steps you use to build otherwise this is very difficult to understand, for me anyway.
Yes it's work in spite of my router haven't boost, libtorrent and qt.
What I am doing: 1)git clone https://github.com/openwrt/openwrt 1a) cd openwrt 1b)./scripts/feeds update -a 1c)./scripts/feeds install -a 2) cd package 3)git clone https://github.com/Deema35/qBittorrent-openwrt-package.
Only change version to 4.4.0beta3 and hash in makefile for qbittorrent. And replace depends +rblibtorrent to +libtorrent-rasterbar, because libtorrent 2.0.4 already present in Openwrt. (I am add this file to comment Makefile.zip)
4)make menuconfig - set architecture and board(I use meiateck arm mt7622 banan pi R64) and pick qbittorrent (network/torrent/qbittorrent). 5)make tools/install 6)make toolchain/install 7)make package/qBittorrent/compile
If you want build OpenWRT entirely enter only make.
8)make package/index - create signature (key-build need put in openwrt folder)
Generate keys for signature:
1)git clone https://git.openwrt.org/project/usign.git
2)cd usign
3)cmake .
4)make
5)usign -G -c 'openwrt test repo' -s key-build -p key-build.pub
6)ln -s which usign
staging_dir/host/bin/usign
Execute in router: 1)Copy .pub key to /etc/opkg/keys/ key need rename to signature ID in file Packages.sig 2)file:///opt >> /etc/opkg/customfeeds.conf - Add local repository in folder /opt 3) Move file from folder bin/packages/archetecture to folder opt on router 4)opkg update 5)opkg install qbittorrent
I found out why Qbittoren don't work https://github.com/qbittorrent/qBittorrent/issues/15425 in short this becose of mismathing my OpenWRT version and version OpenWRT on whitch I compile Qbittorrent.
so, this is not related to libtorrent, then?
Not last post answer to userdocs. Issue described in first post with torrent-rasterbar-pkgconfig/compile-settings-expanded.cmake file.
If your issue is solved you can close the issue?
Not solved.
@Deema35 as far as I can tell from your description, QT is including a linux header file, and your app includes a musl header file, and they conflict. I don't see how this has anything to do with libtorrent.
I don't know cause of trubble. But Qbittorrent had began building only after I have edited file torrent-rasterbar-pkgconfig/compile-settings-expanded.cmake. Early I use libtorrent 1.2.14 and it building good (make file 1.2.14 but when I build Qbittorrent with libtorrent 2.0.4(make file 2.0.4) I have got this trubble.
In log you can see that during building system address to /usr/include dir. But It must addres to /toolchain/include dir. This is happen during Qbittorrent compile not Libtorrent but it depends from file torrent-rasterbar-pkgconfig/compile-settings-expanded.cmake witch generate libtorrent.
Is libtorrent adding this include path to the system includes, and that causes problems?
Yes after I had edited torrent-rasterbar-pkgconfig/compile-settings-expanded.cmake this problem disappeared.
Hi I have avoid this trouble by moving to Cmake from Autotools for Qbittorrent https://github.com/Deema35/qBittorrent-openwrt-package
libtorrent version (or branch):2.0.4
platform/architecture: OpenWRT crosplatform compail
compiler and compiler version: gcc
Hi. I try compile libtorrent 2.0.4 with qbittorrent for OpenWRT. And when I do it I have got errors such:
And also I have got this warning from cmake:
This is file torrent-rasterbar-pkgconfig/compile-settings-expanded.cmake:
I have removed symbol @ from line:
set(_TARGET_INTERFACE_INCLUDE_DIRS ";@CMAKE_INSTALL_PREFIX@/include")
And It has been compiled right.