Serranya / deadbeef-mpris2-plugin

A rewrite of the seemingly orphaned deadbeef-mpris-plugin originally written by HuangCongyu
GNU General Public License v2.0
65 stars 8 forks source link

Failed to build #37

Closed kevin335200 closed 6 years ago

kevin335200 commented 6 years ago

For developers:

kevin335200@kevin335200:~/tmp/deadbeef-mpris2-plugin$ autoreconf --install aclocal: warning: couldn't open directory 'm4': No such file or directory configure.ac:18: error: possibly undefined macro: AC_PROG_LIBTOOL If this token and others are legitimate, please use m4_pattern_allow. See the Autoconf documentation. autoreconf: /usr/bin/autoconf failed with exit status: 1

kevin335200@kevin335200:~/tmp/deadbeef-mpris2-plugin$ ./configure checking for a BSD-compatible install... /usr/bin/install -c checking whether build environment is sane... yes checking for a thread-safe mkdir -p... /bin/mkdir -p checking for gawk... no checking for mawk... mawk checking whether make sets $(MAKE)... yes checking whether make supports nested variables... yes checking whether make supports nested variables... (cached) yes checking for style of include used by make... GNU checking for gcc... gcc checking whether the C compiler works... yes checking for C compiler default output file name... a.out checking for suffix of executables... checking whether we are cross compiling... no checking for suffix of object files... o checking whether we are using the GNU C compiler... yes checking whether gcc accepts -g... yes checking for gcc option to accept ISO C89... none needed checking whether gcc understands -c and -o together... yes checking dependency style of gcc... gcc3 checking for gcc option to accept ISO C99... none needed checking for ar... ar checking the archiver (ar) interface... ar ./configure: line 3890: AC_PROG_LIBTOOL: command not found checking for pkg-config... /usr/bin/pkg-config checking pkg-config is at least version 0.9.0... yes ./configure: line 4012: LT_INIT: command not found checking for GLIB_DEPS... yes checking for GIO_DEPS... yes checking for GIOUNIX_DEPS... yes checking for GTHREAD_DEPS... yes checking that generated files are newer than configure... done configure: creating ./config.status config.status: error: cannot find input file: `Makefile.in' make: No rule to make target 'install'. Stop.

For Users: checking for a BSD-compatible install... /usr/bin/install -c checking whether build environment is sane... yes checking for a thread-safe mkdir -p... /bin/mkdir -p checking for gawk... no checking for mawk... mawk checking whether make sets $(MAKE)... yes checking whether make supports nested variables... yes checking whether make supports nested variables... (cached) yes checking for style of include used by make... GNU checking for gcc... gcc checking whether the C compiler works... yes checking for C compiler default output file name... a.out checking for suffix of executables... checking whether we are cross compiling... no checking for suffix of object files... o checking whether we are using the GNU C compiler... yes checking whether gcc accepts -g... yes checking for gcc option to accept ISO C89... none needed checking whether gcc understands -c and -o together... yes checking dependency style of gcc... gcc3 checking for gcc option to accept ISO C99... none needed checking for ar... ar checking the archiver (ar) interface... ar checking build system type... x86_64-pc-linux-gnu checking host system type... x86_64-pc-linux-gnu checking how to print strings... printf checking for a sed that does not truncate output... /bin/sed checking for grep that handles long lines and -e... /bin/grep checking for egrep... /bin/grep -E checking for fgrep... /bin/grep -F checking for ld used by gcc... /usr/bin/x86_64-linux-gnu-ld checking if the linker (/usr/bin/x86_64-linux-gnu-ld) is GNU ld... yes checking for BSD- or MS-compatible name lister (nm)... /usr/bin/nm -B checking the name lister (/usr/bin/nm -B) interface... BSD nm checking whether ln -s works... yes checking the maximum length of command line arguments... 1572864 checking how to convert x86_64-pc-linux-gnu file names to x86_64-pc-linux-gnu format... func_convert_file_noop checking how to convert x86_64-pc-linux-gnu file names to toolchain format... func_convert_file_noop checking for /usr/bin/x86_64-linux-gnu-ld option to reload object files... -r checking for objdump... objdump checking how to recognize dependent libraries... pass_all checking for dlltool... no checking how to associate runtime and link libraries... printf %s\n checking for archiver @FILE support... @ checking for strip... strip checking for ranlib... ranlib checking command to parse /usr/bin/nm -B output from gcc object... ok checking for sysroot... no checking for a working dd... /bin/dd checking how to truncate binary pipes... /bin/dd bs=4096 count=1 checking for mt... mt checking if mt is a manifest tool... no checking how to run the C preprocessor... gcc -E checking for ANSI C header files... yes checking for sys/types.h... yes checking for sys/stat.h... yes checking for stdlib.h... yes checking for string.h... yes checking for memory.h... yes checking for strings.h... yes checking for inttypes.h... yes checking for stdint.h... yes checking for unistd.h... yes checking for dlfcn.h... yes checking for objdir... .libs checking if gcc supports -fno-rtti -fno-exceptions... no checking for gcc option to produce PIC... -fPIC -DPIC checking if gcc PIC flag -fPIC -DPIC works... yes checking if gcc static flag -static works... yes checking if gcc supports -c -o file.o... yes checking if gcc supports -c -o file.o... (cached) yes checking whether the gcc linker (/usr/bin/x86_64-linux-gnu-ld -m elf_x86_64) supports shared libraries... yes checking whether -lc should be explicitly linked in... no checking dynamic linker characteristics... GNU/Linux ld.so checking how to hardcode library paths into programs... immediate checking whether stripping libraries is possible... yes checking if libtool supports shared libraries... yes checking whether to build shared libraries... yes checking whether to build static libraries... yes checking for pkg-config... /usr/bin/pkg-config checking pkg-config is at least version 0.9.0... yes checking for GLIB_DEPS... yes checking for GIO_DEPS... yes checking for GIOUNIX_DEPS... yes checking for GTHREAD_DEPS... yes checking that generated files are newer than configure... done configure: creating ./config.status config.status: creating Makefile config.status: executing depfiles commands config.status: executing libtool commands kevin335200@kevin335200:~/tmp/deadbeef-1.11$ make install CC src/mpris_la-mpris.lo In file included from src/mpris.c:3:0: src/mprisServer.h:9:10: fatal error: deadbeef/deadbeef.h: No such file or directory

include <deadbeef/deadbeef.h>

      ^~~~~~~~~~~~~~~~~~~~~

compilation terminated. Makefile:497: recipe for target 'src/mpris_la-mpris.lo' failed make: *** [src/mpris_la-mpris.lo] Error 1

Serranya commented 6 years ago

If you are using an debian based distro like Ubuntu you need libtool installed Maybe this Thread can help you: https://superuser.com/questions/565988/autoconf-libtool-and-an-undefined-ac-prog-libtool

Maybe you need to reinstall libtool, or install libtool-dev. Im not sure how the autotools are packaged on your distro. Maybe it would be best to ask in the support channels of your distro.

Which distro are you using?

kevin335200 commented 6 years ago

Ubuntu 18.04 Yes i need to install libtool. But it seems like deadbeef.h is still not to be found:

kevin335200@kevin335200: /tmp/deadbeef-mpris2-plugin$ autoreconf --install aclocal: warning: couldn't open directory 'm4': No such file or directory libtoolize: putting auxiliary files in AC_CONFIG_AUX_DIR, 'build-aux'. libtoolize: copying file 'build-aux/ltmain.sh' libtoolize: putting macros in AC_CONFIG_MACRO_DIRS, 'm4'. libtoolize: copying file 'm4/libtool.m4' libtoolize: copying file 'm4/ltoptions.m4' libtoolize: copying file 'm4/ltsugar.m4' libtoolize: copying file 'm4/ltversion.m4' libtoolize: copying file 'm4/lt~obsolete.m4' configure.ac:18: installing 'build-aux/config.guess' configure.ac:18: installing 'build-aux/config.sub'

kevin335200@kevin335200:~/tmp/deadbeef-mpris2-plugin$ ./configure checking for a BSD-compatible install... /usr/bin/install -c checking whether build environment is sane... yes checking for a thread-safe mkdir -p... /bin/mkdir -p checking for gawk... no checking for mawk... mawk checking whether make sets $(MAKE)... yes checking whether make supports nested variables... yes checking whether make supports nested variables... (cached) yes checking for style of include used by make... GNU checking for gcc... gcc checking whether the C compiler works... yes checking for C compiler default output file name... a.out checking for suffix of executables... checking whether we are cross compiling... no checking for suffix of object files... o checking whether we are using the GNU C compiler... yes checking whether gcc accepts -g... yes checking for gcc option to accept ISO C89... none needed checking whether gcc understands -c and -o together... yes checking dependency style of gcc... gcc3 checking for gcc option to accept ISO C99... none needed checking for ar... ar checking the archiver (ar) interface... ar checking build system type... x86_64-pc-linux-gnu checking host system type... x86_64-pc-linux-gnu checking how to print strings... printf checking for a sed that does not truncate output... /bin/sed checking for grep that handles long lines and -e... /bin/grep checking for egrep... /bin/grep -E checking for fgrep... /bin/grep -F checking for ld used by gcc... /usr/bin/x86_64-linux-gnu-ld checking if the linker (/usr/bin/x86_64-linux-gnu-ld) is GNU ld... yes checking for BSD- or MS-compatible name lister (nm)... /usr/bin/nm -B checking the name lister (/usr/bin/nm -B) interface... BSD nm checking whether ln -s works... yes checking the maximum length of command line arguments... 1572864 checking how to convert x86_64-pc-linux-gnu file names to x86_64-pc-linux-gnu format... func_convert_file_noop checking how to convert x86_64-pc-linux-gnu file names to toolchain format... func_convert_file_noop checking for /usr/bin/x86_64-linux-gnu-ld option to reload object files... -r checking for objdump... objdump checking how to recognize dependent libraries... pass_all checking for dlltool... no checking how to associate runtime and link libraries... printf %s\n checking for archiver @FILE support... @ checking for strip... strip checking for ranlib... ranlib checking command to parse /usr/bin/nm -B output from gcc object... ok checking for sysroot... no checking for a working dd... /bin/dd checking how to truncate binary pipes... /bin/dd bs=4096 count=1 checking for mt... mt checking if mt is a manifest tool... no checking how to run the C preprocessor... gcc -E checking for ANSI C header files... yes checking for sys/types.h... yes checking for sys/stat.h... yes checking for stdlib.h... yes checking for string.h... yes checking for memory.h... yes checking for strings.h... yes checking for inttypes.h... yes checking for stdint.h... yes checking for unistd.h... yes checking for dlfcn.h... yes checking for objdir... .libs checking if gcc supports -fno-rtti -fno-exceptions... no checking for gcc option to produce PIC... -fPIC -DPIC checking if gcc PIC flag -fPIC -DPIC works... yes checking if gcc static flag -static works... yes checking if gcc supports -c -o file.o... yes checking if gcc supports -c -o file.o... (cached) yes checking whether the gcc linker (/usr/bin/x86_64-linux-gnu-ld -m elf_x86_64) supports shared libraries... yes checking whether -lc should be explicitly linked in... no checking dynamic linker characteristics... GNU/Linux ld.so checking how to hardcode library paths into programs... immediate checking whether stripping libraries is possible... yes checking if libtool supports shared libraries... yes checking whether to build shared libraries... yes checking whether to build static libraries... yes checking for pkg-config... /usr/bin/pkg-config checking pkg-config is at least version 0.9.0... yes checking for GLIB_DEPS... yes checking for GIO_DEPS... yes checking for GIOUNIX_DEPS... yes checking for GTHREAD_DEPS... yes checking that generated files are newer than configure... done configure: creating ./config.status config.status: creating Makefile config.status: executing depfiles commands config.status: executing libtool commands

kevin335200@kevin335200:~/tmp/deadbeef-mpris2-plugin$ make install CC src/mpris_la-mpris.lo In file included from src/mpris.c:3:0: src/mprisServer.h:9:10: fatal error: deadbeef/deadbeef.h: No such file or directory

include <deadbeef/deadbeef.h>

      ^~~~~~~~~~~~~~~~~~~~~

compilation terminated. Makefile:497: recipe for target 'src/mpris_la-mpris.lo' failed make: *** [src/mpris_la-mpris.lo] Error 1

Serranya commented 6 years ago

Try to run configure like this CPPFLAGS=-I/opt/deadbeef/include ./configure --prefix=/opt/deadbeef

kevin335200 commented 6 years ago

It seems like opt folder isn't installed from starws-box's ppa(deadbeef also doesn't load these files anymore). so

  1. download deadbeef-static deb and extract it (dpkg -x), copy the extracted folder /opt/deadbeef/ to /opt/ (or simply reinstall deadbeef using deb)
  2. CPPFLAGS=-I/opt/deadbeef/include ./configure --prefix=/opt/deadbeef
  3. sudo make install, otherwise will get the error "cannot create regular file '/opt/deadbeef/lib/deadbeef/mpris.so': Permission denied"
  4. copy /opt/deadbeef/lib/deadbeef/mpris.so to /home/your_user_name/.local/lib/deadbeef

Thanks for your help!