Open ghost opened 2 years ago
I'm trying to build the Nexus version. I changed my PKGBUILD to download the Nexus version of ffmpegdirect and kodi.
Can you explain the steps you went through to get to this error?
try following this closed issue thread: https://github.com/xbmc/inputstream.ffmpegdirect/issues/89
Thanks for the help. I modified the PKGBUILD to grab the Nexus version of each. I then did a makepkg command. I tied both with the option of lto and makeflags. I also tried without the options line in the PKGBUILD. I also tried adding the -fpic flag to the cmake command in the /etc/makepkg.conf.
In the closed thread, he said he used lto. I tried this by adding the options(lto) but it did not compile. I could try adding it to make cmake command in the /etc/makepkg.conf.
# Maintainer: ivanich
pkgname=kodi-addon-inputstream-ffmpegdirect
pkgver=20.0.1
pkgrel=1
pkgdesc="Inputstream ffmpegdirect kodi plugin"
_koditarget=Nexus
_gitname=inputstream.ffmpegdirect
_kodiver=master
arch=('armv6h' 'armv7h' 'aarch64' 'i686' 'x86_64')
url="https://github.com/xbmc/${_gitname}"
license=('GPL')
groups=('kodi')
makedepends=('cmake' 'git' 'autoconf' 'automake' 'patch' 'nasm')
provides=('kodi-addon-inputstream-ffmpegdirect')
depends=('kodi')
options=(lto) # also tried makeflags with it set to -fpic
source=("https://github.com/xbmc/inputstream.ffmpegdirect/archive/refs/heads/Nexus.zip"
"https://github.com/xbmc/xbmc/archive/refs/heads/master.zip"
)
sha256sums=('15735e176c547b9f82a79011e59a292f7ca1aba1976e988bcd2bff59b30cfd93'
'SKIP')
prepare() {
cd xbmc-${_kodiver}
}
build() {
mkdir -p "${_gitname}-${pkgver}-${_koditarget}/build"
cd "${_gitname}-${pkgver}-${_koditarget}/build"
cmake \
-DCMAKE_INSTALL_PREFIX=/usr \
-DCMAKE_INSTALL_LIBDIR=/usr/lib/kodi \
-DCMAKE_BUILD_TYPE=Release \
-DBUILD_SHARED_LIBS=1 \
-DADDONS_TO_BUILD=${_gitname} \
-DADDONS_SRC_PREFIX=../.. \
../../xbmc-${_kodiver}/cmake/addons
make
}
package() {
cd "${_gitname}-${pkgver}-${_koditarget}/build"
install -d "${pkgdir}/usr"
mv .install/lib "${pkgdir}/usr/"
mv .install/share "${pkgdir}/usr/"
}
Maybe ask the person who solved it for advice on this thread?
@stuckinthe I managed to get it compile on rpi Aarch43 thanks to your comment above.
Installed on manjaro arm with the followinf command
yay kodi-addon-inputstream-ff --editmenu
then added options
before sources=...
options=("lto")
source=("https://github.com/xbmc/inputstream.ffmpegdirect/archive/refs/heads/Nexus.zip"
"https://github.com/xbmc/xbmc/archive/refs/heads/master.zip"
)
Your snoppet was close, just missing the double quotes for me.
Indeed using lto with aarch64 is solving this issue.
I am not sure if this is an issue with arch, my setup or ffmpegdirect. I am trying to build but I get an -fpic error. I noticed someone else had the same issue and they compiled with -flto. In my PKGBUILD, I added the option of lto but it gave me a different error. I tried to add -fpic to my flags through /etc/makepkg.conf but it didn't work
without lto /home/alarm/packages/ffmpeg/src/inputstream.ffmpegdirect-19.0.1-Nexus/build/build/depends/lib/libhogweed.a(bignum.o): in function
nettle_mpz_sizeinbase_256_s': /home/alarm/packages/ffmpeg/src/inputstream.ffmpegdirect-19.0.1-Nexus/build/build/nettle/src/nettle/bignum.c:61:(.text+0xd8): relocation truncated to fit: R_AARCH64_LD64_GOTPAGE_LO15 against symbol
__gmpz_sizeinbase' defined in .text section in /home/alarm/packages/ffmpeg/src/inputstream.ffmpegdirect-19.0.1-Nexus/build/build/depends/lib/libgmp.a(sizeinbase.o) /usr/bin/ld: /home/alarm/packages/ffmpeg/src/inputstream.ffmpegdirect-19.0.1-Nexus/build/build/nettle/src/nettle/bignum.c:61: warning: too many GOT entries for -fpic, please recompile with -fPIC collect2: error: ld returned 1 exit status make[5]: [CMakeFiles/inputstream.ffmpegdirect.dir/build.make:330: inputstream.ffmpegdirect.so.20.1.0] Error 1 make[4]: [CMakeFiles/Makefile2:110: CMakeFiles/inputstream.ffmpegdirect.dir/all] Error 2 make[3]: [Makefile:156: all] Error 2 make[2]: [CMakeFiles/inputstream.ffmpegdirect.dir/build.make:88: inputstream.ffmpegdirect-prefix/src/inputstream.ffmpegdirect-stamp/inputstream.ffmpegdirect-build] Error 2 make[1]: [CMakeFiles/Makefile2:163: CMakeFiles/inputstream.ffmpegdirect.dir/all] Error 2 make: [Makefile:91: all] Error 2 ==> ERROR: A failure occurred in build().With lto: make[5]: [CMakeFiles/inputstream.ffmpegdirect.dir/build.make:330: inputstream.ffmpegdirect.so.20.1.0] Error 1 make[5]: Deleting file 'inputstream.ffmpegdirect.so.20.1.0' make[4]: [CMakeFiles/Makefile2:110: CMakeFiles/inputstream.ffmpegdirect.dir/all] Error 2 make[3]: [Makefile:156: all] Error 2 make[2]: [CMakeFiles/inputstream.ffmpegdirect.dir/build.make:88: inputstream.ffmpegdirect-prefix/src/inputstream.ffmpegdirect-stamp/inputstream.ffmpegdirect-build] Error 2 make[1]: [CMakeFiles/Makefile2:163: CMakeFiles/inputstream.ffmpegdirect.dir/all] Error 2 make: *** [Makefile:91: all] Error 2 ==> ERROR: A failure occurred in build().
Can someone point me in the right direction?