Skip to content

samplerate cannot be installed in OpenSuse Tumbleweed #17

@truquete

Description

@truquete

Problem:
samplerate cannot be installed in OpenSuse Tumbleweed

Platform:
OpenSuse Tumbleweed with all packages up-to-date
Python 3.11
virtual environment

Steps to reproduce:
python3 -m venv led
source led/bin/activate
python3 -m pip install samplerate

Trace:

Collecting samplerate
  Using cached samplerate-0.2.1.tar.gz (21 kB)
  Installing build dependencies ... done
  Getting requirements to build wheel ... done
  Installing backend dependencies ... done
  Preparing metadata (pyproject.toml) ... done
Collecting numpy (from samplerate)
  Using cached numpy-1.26.4-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.metadata (61 kB)
Using cached numpy-1.26.4-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (18.3 MB)
Building wheels for collected packages: samplerate
  Building wheel for samplerate (pyproject.toml) ... error
  error: subprocess-exited-with-error
  
  × Building wheel for samplerate (pyproject.toml) did not run successfully.
  │ exit code: 1
  ╰─> [149 lines of output]
      running bdist_wheel
      running build
      running build_ext
      -- Found Python prefix
      -- The C compiler identification is GNU 13.2.1
      -- The CXX compiler identification is GNU 13.2.1
      -- Detecting C compiler ABI info
      -- Detecting C compiler ABI info - done
      -- Check for working C compiler: /usr/bin/cc - skipped
      -- Detecting C compile features
      -- Detecting C compile features - done
      -- Detecting CXX compiler ABI info
      -- Detecting CXX compiler ABI info - done
      -- Check for working CXX compiler: /usr/bin/c++ - skipped
      -- Detecting CXX compile features
      -- Detecting CXX compile features - done
      CMake Deprecation Warning at build/temp.linux-x86_64-cpython-311/samplerate/_deps/pybind11-src/CMakeLists.txt:8 (cmake_minimum_required):
        Compatibility with CMake < 3.5 will be removed from a future version of
        CMake.
      
        Update the VERSION argument <min> value or use a ...<max> suffix to tell
        CMake that the project does not need compatibility with older versions.
      
      
      -- pybind11 v2.10.4
      CMake Warning (dev) at build/temp.linux-x86_64-cpython-311/samplerate/_deps/pybind11-src/tools/FindPythonLibsNew.cmake:98 (find_package):
        Policy CMP0148 is not set: The FindPythonInterp and FindPythonLibs modules
        are removed.  Run "cmake --help-policy CMP0148" for policy details.  Use
        the cmake_policy command to set the policy and suppress this warning.
      
      Call Stack (most recent call first):
        build/temp.linux-x86_64-cpython-311/samplerate/_deps/pybind11-src/tools/pybind11Tools.cmake:50 (find_package)
        build/temp.linux-x86_64-cpython-311/samplerate/_deps/pybind11-src/tools/pybind11Common.cmake:180 (include)
        build/temp.linux-x86_64-cpython-311/samplerate/_deps/pybind11-src/CMakeLists.txt:208 (include)
      This warning is for project developers.  Use -Wno-dev to suppress it.
      
      -- Found PythonInterp: /home/julian/led/bin/python3 (found suitable version "3.11.8", minimum required is "3.6")
      -- Found PythonLibs: /usr/lib64/libpython3.11.so
      -- Performing Test HAS_FLTO
      -- Performing Test HAS_FLTO - Success
      CMake Deprecation Warning at build/temp.linux-x86_64-cpython-311/samplerate/_deps/libsamplerate-src/CMakeLists.txt:1 (cmake_minimum_required):
        Compatibility with CMake < 3.5 will be removed from a future version of
        CMake.
      
        Update the VERSION argument <min> value or use a ...<max> suffix to tell
        CMake that the project does not need compatibility with older versions.
      
      
      CMake Deprecation Warning at build/temp.linux-x86_64-cpython-311/samplerate/_deps/libsamplerate-src/CMakeLists.txt:16 (cmake_policy):
        The OLD behavior for policy CMP0091 will be removed from a future version
        of CMake.
      
        The cmake-policies(7) manual explains that the OLD behaviors of all
        policies are deprecated and that a policy should be set to OLD only under
        specific short-term circumstances.  Projects should be ported to the NEW
        behavior and not rely on setting a policy to OLD.
      
      
      -- Looking for stdbool.h
      -- Looking for stdbool.h - found
      -- Looking for unistd.h
      -- Looking for unistd.h - found
      -- Found PkgConfig: /usr/bin/pkg-config (found version "2.1.1")
      -- Checking processor clipping capabilities...
      -- Performing Test CPU_CLIPS_POSITIVE
      -- Performing Test CPU_CLIPS_POSITIVE - Failed
      -- Performing Test CPU_CLIPS_NEGATIVE
      -- Performing Test CPU_CLIPS_NEGATIVE - Failed
      -- Checking processor clipping capabilities... none
      -- Performing Test HAVE_VISIBILITY
      -- Performing Test HAVE_VISIBILITY - Success
      -- Configuring done (24.9s)
      -- Generating done (0.0s)
      -- Build files have been written to: /tmp/pip-install-11ji9nc2/samplerate_223f7f72bd134c9fbab22e639081d602/build/temp.linux-x86_64-cpython-311/samplerate
      [ 14%] Building C object _deps/libsamplerate-build/src/CMakeFiles/samplerate.dir/samplerate.c.o
      [ 28%] Building C object _deps/libsamplerate-build/src/CMakeFiles/samplerate.dir/src_linear.c.o
      [ 42%] Building C object _deps/libsamplerate-build/src/CMakeFiles/samplerate.dir/src_sinc.c.o
      [ 57%] Building C object _deps/libsamplerate-build/src/CMakeFiles/samplerate.dir/src_zoh.c.o
      [ 71%] Linking C static library libsamplerate.a
      [ 71%] Built target samplerate
      [ 85%] Building CXX object CMakeFiles/python-samplerate.dir/src/samplerate.cpp.o
      [100%] Linking C shared module /tmp/pip-install-11ji9nc2/samplerate_223f7f72bd134c9fbab22e639081d602/build/lib.linux-x86_64-cpython-311/samplerate.cpython-311-x86_64-linux-gnu.so
      lto-wrapper: warning: using serial compilation of 4 LTRANS jobs
      lto-wrapper: note: see the ‘-flto’ option documentation for more information
      /usr/lib64/gcc/x86_64-suse-linux/13/../../../../x86_64-suse-linux/bin/ld: _deps/libsamplerate-build/src/libsamplerate.a(samplerate.c.o): relocation R_X86_64_32S against `.rodata' can not be used when making a shared object; recompile with -fPIC
      /usr/lib64/gcc/x86_64-suse-linux/13/../../../../x86_64-suse-linux/bin/ld: failed to set dynamic section sizes: bad value
      collect2: error: ld returned 1 exit status
      gmake[2]: *** [CMakeFiles/python-samplerate.dir/build.make:99: /tmp/pip-install-11ji9nc2/samplerate_223f7f72bd134c9fbab22e639081d602/build/lib.linux-x86_64-cpython-311/samplerate.cpython-311-x86_64-linux-gnu.so] Error 1
      gmake[1]: *** [CMakeFiles/Makefile2:148: CMakeFiles/python-samplerate.dir/all] Error 2
      gmake: *** [Makefile:111: all] Error 2
      Traceback (most recent call last):
        File "/home/julian/led/lib64/python3.11/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 353, in <module>
          main()
        File "/home/julian/led/lib64/python3.11/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 335, in main
          json_out['return_val'] = hook(**hook_input['kwargs'])
                                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
        File "/home/julian/led/lib64/python3.11/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 251, in build_wheel
          return _build_backend().build_wheel(wheel_directory, config_settings,
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
        File "/tmp/pip-build-env-kvs7ltuy/overlay/lib/python3.11/site-packages/setuptools/build_meta.py", line 410, in build_wheel
          return self._build_with_temp_dir(
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^
        File "/tmp/pip-build-env-kvs7ltuy/overlay/lib/python3.11/site-packages/setuptools/build_meta.py", line 395, in _build_with_temp_dir
          self.run_setup()
        File "/tmp/pip-build-env-kvs7ltuy/overlay/lib/python3.11/site-packages/setuptools/build_meta.py", line 311, in run_setup
          exec(code, locals())
        File "<string>", line 129, in <module>
        File "/tmp/pip-build-env-kvs7ltuy/overlay/lib/python3.11/site-packages/setuptools/__init__.py", line 103, in setup
          return distutils.core.setup(**attrs)
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
        File "/tmp/pip-build-env-kvs7ltuy/overlay/lib/python3.11/site-packages/setuptools/_distutils/core.py", line 185, in setup
          return run_commands(dist)
                 ^^^^^^^^^^^^^^^^^^
        File "/tmp/pip-build-env-kvs7ltuy/overlay/lib/python3.11/site-packages/setuptools/_distutils/core.py", line 201, in run_commands
          dist.run_commands()
        File "/tmp/pip-build-env-kvs7ltuy/overlay/lib/python3.11/site-packages/setuptools/_distutils/dist.py", line 969, in run_commands
          self.run_command(cmd)
        File "/tmp/pip-build-env-kvs7ltuy/overlay/lib/python3.11/site-packages/setuptools/dist.py", line 963, in run_command
          super().run_command(command)
        File "/tmp/pip-build-env-kvs7ltuy/overlay/lib/python3.11/site-packages/setuptools/_distutils/dist.py", line 988, in run_command
          cmd_obj.run()
        File "/tmp/pip-build-env-kvs7ltuy/normal/lib/python3.11/site-packages/wheel/bdist_wheel.py", line 368, in run
          self.run_command("build")
        File "/tmp/pip-build-env-kvs7ltuy/overlay/lib/python3.11/site-packages/setuptools/_distutils/cmd.py", line 318, in run_command
          self.distribution.run_command(command)
        File "/tmp/pip-build-env-kvs7ltuy/overlay/lib/python3.11/site-packages/setuptools/dist.py", line 963, in run_command
          super().run_command(command)
        File "/tmp/pip-build-env-kvs7ltuy/overlay/lib/python3.11/site-packages/setuptools/_distutils/dist.py", line 988, in run_command
          cmd_obj.run()
        File "/tmp/pip-build-env-kvs7ltuy/overlay/lib/python3.11/site-packages/setuptools/_distutils/command/build.py", line 131, in run
          self.run_command(cmd_name)
        File "/tmp/pip-build-env-kvs7ltuy/overlay/lib/python3.11/site-packages/setuptools/_distutils/cmd.py", line 318, in run_command
          self.distribution.run_command(command)
        File "/tmp/pip-build-env-kvs7ltuy/overlay/lib/python3.11/site-packages/setuptools/dist.py", line 963, in run_command
          super().run_command(command)
        File "/tmp/pip-build-env-kvs7ltuy/overlay/lib/python3.11/site-packages/setuptools/_distutils/dist.py", line 988, in run_command
          cmd_obj.run()
        File "/tmp/pip-build-env-kvs7ltuy/overlay/lib/python3.11/site-packages/setuptools/command/build_ext.py", line 89, in run
          _build_ext.run(self)
        File "/tmp/pip-build-env-kvs7ltuy/overlay/lib/python3.11/site-packages/setuptools/_distutils/command/build_ext.py", line 345, in run
          self.build_extensions()
        File "/tmp/pip-build-env-kvs7ltuy/overlay/lib/python3.11/site-packages/setuptools/_distutils/command/build_ext.py", line 467, in build_extensions
          self._build_extensions_serial()
        File "/tmp/pip-build-env-kvs7ltuy/overlay/lib/python3.11/site-packages/setuptools/_distutils/command/build_ext.py", line 493, in _build_extensions_serial
          self.build_extension(ext)
        File "<string>", line 124, in build_extension
        File "/usr/lib64/python3.11/subprocess.py", line 571, in run
          raise CalledProcessError(retcode, process.args,
      subprocess.CalledProcessError: Command '['cmake', '--build', '.']' returned non-zero exit status 2.
      [end of output]

Also tried clearing cache with same results.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions