Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Qt for Python
  4. pyside6-deploy build error ...

pyside6-deploy build error ...

Scheduled Pinned Locked Moved Unsolved Qt for Python
5 Posts 5 Posters 1.5k Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • J Offline
    J Offline
    jaydub
    wrote on last edited by
    #1

    I am trying to create a deployable build of a Python/QML project. When I run pyside6-deploy on my project, I get the following error and I do not understand how to interpret/fix this issue:

    Has anyone run into this issue or can guide me on how to fix it? Thank you.

    (testenv) jwkelly@JKs-MacBook-Pro RPNDeploy % pyside6-deploy ../RPNCalculator/main.py 
    Nuitka will make use of ccache to speed up repeated compilation.                  
    
    Is it OK to download and put it in '/Users/jwkelly/Library/Caches/Nuitka/downloads/ccache/v4.2.1'.
    
    Fully automatic, cached. Proceed and download? [Yes]/No : y
    In file included from static_src/CompiledFunctionType.c:2673:
    In file included from /Users/jwkelly/testenv/lib/python3.10/site-packages/nuitka/build/static_src/CompiledCodeHelpers.c:2108:
    /Users/jwkelly/testenv/lib/python3.10/site-packages/nuitka/build/static_src/HelpersConstantsBlob.c:1199:12: error: call to undeclared function 'getsectdata'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
        return getsectdata("constants", "constants", &size) + (uintptr_t)header;
               ^                                   
    1 error generated.                             
    scons: *** [static_src/CompiledFunctionType.o] Error 1
    ERROR:root:[DEPLOY] Command /Users/jwkelly/testenv/bin/python3 -m nuitka /Users/jwkelly/Source/RPNDeploy/../RPNCalculator/main.py --follow-imports --onefile --enable-plugin=pyside6 --output-dir=/Users/jwkelly/Source/RPNDeploy/../RPNCalculator/deployment --quiet --noinclude-qt-translations=True --include-qt-plugins=all --include-data-files=/Users/jwkelly/Source/RPNDeploy/../RPNCalculator/main.qml=./main.qml --include-data-files=/Users/jwkelly/Source/RPNDeploy/../RPNCalculator/CalcButton.qml=./CalcButton.qml --noinclude-dlls=libQt6Charts* --noinclude-dlls=libQt6Quick3D* --noinclude-dlls=libQt6Sensors* --noinclude-dlls=libQt6Test* --noinclude-dlls=libQt6WebEngine* failed with error Command '['/Users/jwkelly/testenv/bin/python3', '-m', 'nuitka', '/Users/jwkelly/Source/RPNDeploy/../RPNCalculator/main.py', '--follow-imports', '--onefile', '--enable-plugin=pyside6', '--output-dir=/Users/jwkelly/Source/RPNDeploy/../RPNCalculator/deployment', '--quiet', '--noinclude-qt-translations=True', '--include-qt-plugins=all', '--include-data-files=/Users/jwkelly/Source/RPNDeploy/../RPNCalculator/main.qml=./main.qml', '--include-data-files=/Users/jwkelly/Source/RPNDeploy/../RPNCalculator/CalcButton.qml=./CalcButton.qml', '--noinclude-dlls=libQt6Charts*', '--noinclude-dlls=libQt6Quick3D*', '--noinclude-dlls=libQt6Sensors*', '--noinclude-dlls=libQt6Test*', '--noinclude-dlls=libQt6WebEngine*']' returned non-zero exit status 1. and return_code1
    Traceback (most recent call last):
      File "/Users/jwkelly/testenv/lib/python3.10/site-packages/PySide6/scripts/deploy_lib/commands.py", line 26, in run_command
        subprocess.check_call(command, shell=is_windows)
      File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/subprocess.py", line 369, in check_call
        raise CalledProcessError(retcode, cmd)
    subprocess.CalledProcessError: Command '['/Users/jwkelly/testenv/bin/python3', '-m', 'nuitka', '/Users/jwkelly/Source/RPNDeploy/../RPNCalculator/main.py', '--follow-imports', '--onefile', '--enable-plugin=pyside6', '--output-dir=/Users/jwkelly/Source/RPNDeploy/../RPNCalculator/deployment', '--quiet', '--noinclude-qt-translations=True', '--include-qt-plugins=all', '--include-data-files=/Users/jwkelly/Source/RPNDeploy/../RPNCalculator/main.qml=./main.qml', '--include-data-files=/Users/jwkelly/Source/RPNDeploy/../RPNCalculator/CalcButton.qml=./CalcButton.qml', '--noinclude-dlls=libQt6Charts*', '--noinclude-dlls=libQt6Quick3D*', '--noinclude-dlls=libQt6Sensors*', '--noinclude-dlls=libQt6Test*', '--noinclude-dlls=libQt6WebEngine*']' returned non-zero exit status 1.
    [DEPLOY] Exception occurred: Traceback (most recent call last):
      File "/Users/jwkelly/testenv/lib/python3.10/site-packages/PySide6/scripts/deploy.py", line 94, in main
        command_str = python.create_executable(
      File "/Users/jwkelly/testenv/lib/python3.10/site-packages/PySide6/scripts/deploy_lib/python_helper.py", line 80, in create_executable
        command_str = self.nuitka.create_executable(
      File "/Users/jwkelly/testenv/lib/python3.10/site-packages/PySide6/scripts/deploy_lib/nuitka_helper.py", line 58, in create_executable
        command_str, _ = run_command(command=command, dry_run=dry_run)
      File "/Users/jwkelly/testenv/lib/python3.10/site-packages/PySide6/scripts/deploy_lib/commands.py", line 26, in run_command
        subprocess.check_call(command, shell=is_windows)
      File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/subprocess.py", line 369, in check_call
        raise CalledProcessError(retcode, cmd)
    subprocess.CalledProcessError: Command '['/Users/jwkelly/testenv/bin/python3', '-m', 'nuitka', '/Users/jwkelly/Source/RPNDeploy/../RPNCalculator/main.py', '--follow-imports', '--onefile', '--enable-plugin=pyside6', '--output-dir=/Users/jwkelly/Source/RPNDeploy/../RPNCalculator/deployment', '--quiet', '--noinclude-qt-translations=True', '--include-qt-plugins=all', '--include-data-files=/Users/jwkelly/Source/RPNDeploy/../RPNCalculator/main.qml=./main.qml', '--include-data-files=/Users/jwkelly/Source/RPNDeploy/../RPNCalculator/CalcButton.qml=./CalcButton.qml', '--noinclude-dlls=libQt6Charts*', '--noinclude-dlls=libQt6Quick3D*', '--noinclude-dlls=libQt6Sensors*', '--noinclude-dlls=libQt6Test*', '--noinclude-dlls=libQt6WebEngine*']' returned non-zero exit status 1.
    
    
    JonBJ 1 Reply Last reply
    0
    • J jaydub referenced this topic on
    • J jaydub

      I am trying to create a deployable build of a Python/QML project. When I run pyside6-deploy on my project, I get the following error and I do not understand how to interpret/fix this issue:

      Has anyone run into this issue or can guide me on how to fix it? Thank you.

      (testenv) jwkelly@JKs-MacBook-Pro RPNDeploy % pyside6-deploy ../RPNCalculator/main.py 
      Nuitka will make use of ccache to speed up repeated compilation.                  
      
      Is it OK to download and put it in '/Users/jwkelly/Library/Caches/Nuitka/downloads/ccache/v4.2.1'.
      
      Fully automatic, cached. Proceed and download? [Yes]/No : y
      In file included from static_src/CompiledFunctionType.c:2673:
      In file included from /Users/jwkelly/testenv/lib/python3.10/site-packages/nuitka/build/static_src/CompiledCodeHelpers.c:2108:
      /Users/jwkelly/testenv/lib/python3.10/site-packages/nuitka/build/static_src/HelpersConstantsBlob.c:1199:12: error: call to undeclared function 'getsectdata'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
          return getsectdata("constants", "constants", &size) + (uintptr_t)header;
                 ^                                   
      1 error generated.                             
      scons: *** [static_src/CompiledFunctionType.o] Error 1
      ERROR:root:[DEPLOY] Command /Users/jwkelly/testenv/bin/python3 -m nuitka /Users/jwkelly/Source/RPNDeploy/../RPNCalculator/main.py --follow-imports --onefile --enable-plugin=pyside6 --output-dir=/Users/jwkelly/Source/RPNDeploy/../RPNCalculator/deployment --quiet --noinclude-qt-translations=True --include-qt-plugins=all --include-data-files=/Users/jwkelly/Source/RPNDeploy/../RPNCalculator/main.qml=./main.qml --include-data-files=/Users/jwkelly/Source/RPNDeploy/../RPNCalculator/CalcButton.qml=./CalcButton.qml --noinclude-dlls=libQt6Charts* --noinclude-dlls=libQt6Quick3D* --noinclude-dlls=libQt6Sensors* --noinclude-dlls=libQt6Test* --noinclude-dlls=libQt6WebEngine* failed with error Command '['/Users/jwkelly/testenv/bin/python3', '-m', 'nuitka', '/Users/jwkelly/Source/RPNDeploy/../RPNCalculator/main.py', '--follow-imports', '--onefile', '--enable-plugin=pyside6', '--output-dir=/Users/jwkelly/Source/RPNDeploy/../RPNCalculator/deployment', '--quiet', '--noinclude-qt-translations=True', '--include-qt-plugins=all', '--include-data-files=/Users/jwkelly/Source/RPNDeploy/../RPNCalculator/main.qml=./main.qml', '--include-data-files=/Users/jwkelly/Source/RPNDeploy/../RPNCalculator/CalcButton.qml=./CalcButton.qml', '--noinclude-dlls=libQt6Charts*', '--noinclude-dlls=libQt6Quick3D*', '--noinclude-dlls=libQt6Sensors*', '--noinclude-dlls=libQt6Test*', '--noinclude-dlls=libQt6WebEngine*']' returned non-zero exit status 1. and return_code1
      Traceback (most recent call last):
        File "/Users/jwkelly/testenv/lib/python3.10/site-packages/PySide6/scripts/deploy_lib/commands.py", line 26, in run_command
          subprocess.check_call(command, shell=is_windows)
        File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/subprocess.py", line 369, in check_call
          raise CalledProcessError(retcode, cmd)
      subprocess.CalledProcessError: Command '['/Users/jwkelly/testenv/bin/python3', '-m', 'nuitka', '/Users/jwkelly/Source/RPNDeploy/../RPNCalculator/main.py', '--follow-imports', '--onefile', '--enable-plugin=pyside6', '--output-dir=/Users/jwkelly/Source/RPNDeploy/../RPNCalculator/deployment', '--quiet', '--noinclude-qt-translations=True', '--include-qt-plugins=all', '--include-data-files=/Users/jwkelly/Source/RPNDeploy/../RPNCalculator/main.qml=./main.qml', '--include-data-files=/Users/jwkelly/Source/RPNDeploy/../RPNCalculator/CalcButton.qml=./CalcButton.qml', '--noinclude-dlls=libQt6Charts*', '--noinclude-dlls=libQt6Quick3D*', '--noinclude-dlls=libQt6Sensors*', '--noinclude-dlls=libQt6Test*', '--noinclude-dlls=libQt6WebEngine*']' returned non-zero exit status 1.
      [DEPLOY] Exception occurred: Traceback (most recent call last):
        File "/Users/jwkelly/testenv/lib/python3.10/site-packages/PySide6/scripts/deploy.py", line 94, in main
          command_str = python.create_executable(
        File "/Users/jwkelly/testenv/lib/python3.10/site-packages/PySide6/scripts/deploy_lib/python_helper.py", line 80, in create_executable
          command_str = self.nuitka.create_executable(
        File "/Users/jwkelly/testenv/lib/python3.10/site-packages/PySide6/scripts/deploy_lib/nuitka_helper.py", line 58, in create_executable
          command_str, _ = run_command(command=command, dry_run=dry_run)
        File "/Users/jwkelly/testenv/lib/python3.10/site-packages/PySide6/scripts/deploy_lib/commands.py", line 26, in run_command
          subprocess.check_call(command, shell=is_windows)
        File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/subprocess.py", line 369, in check_call
          raise CalledProcessError(retcode, cmd)
      subprocess.CalledProcessError: Command '['/Users/jwkelly/testenv/bin/python3', '-m', 'nuitka', '/Users/jwkelly/Source/RPNDeploy/../RPNCalculator/main.py', '--follow-imports', '--onefile', '--enable-plugin=pyside6', '--output-dir=/Users/jwkelly/Source/RPNDeploy/../RPNCalculator/deployment', '--quiet', '--noinclude-qt-translations=True', '--include-qt-plugins=all', '--include-data-files=/Users/jwkelly/Source/RPNDeploy/../RPNCalculator/main.qml=./main.qml', '--include-data-files=/Users/jwkelly/Source/RPNDeploy/../RPNCalculator/CalcButton.qml=./CalcButton.qml', '--noinclude-dlls=libQt6Charts*', '--noinclude-dlls=libQt6Quick3D*', '--noinclude-dlls=libQt6Sensors*', '--noinclude-dlls=libQt6Test*', '--noinclude-dlls=libQt6WebEngine*']' returned non-zero exit status 1.
      
      
      JonBJ Offline
      JonBJ Offline
      JonB
      wrote on last edited by
      #2

      @jaydub said in pyside6-deploy build error ...:

      getsectdata

      Are you under Anaconda on MacOS? See https://github.com/Nuitka/Nuitka/issues/2146. On recent April 2nd comment:

      Thanks for your report, this is fixed on the factory branch, which is a development version under rapid development. You can try it out by going here: https://nuitka.net/doc/factory.html

      1 Reply Last reply
      2
      • JonBJ JonB referenced this topic on
      • R Offline
        R Offline
        robliou
        wrote on last edited by
        #3

        Hi, I'm getting this exact same error. To attempt to solve it, I successfully installed the factory version of nuitka, however, the factory version of nuitka uses 'ccache' as the executable rather than 'nuitka'. Therefore, the bundling process doesn't work.

        Thus, when running pyside6-deploy, how do I change the underlying script so that 'ccache' is called rather than 'nuitka'?

        Thanks,

        S 1 Reply Last reply
        0
        • R robliou referenced this topic on
        • R robliou

          Hi, I'm getting this exact same error. To attempt to solve it, I successfully installed the factory version of nuitka, however, the factory version of nuitka uses 'ccache' as the executable rather than 'nuitka'. Therefore, the bundling process doesn't work.

          Thus, when running pyside6-deploy, how do I change the underlying script so that 'ccache' is called rather than 'nuitka'?

          Thanks,

          S Offline
          S Offline
          Shyamnath
          wrote on last edited by
          #4

          @robliou not sure i understand what you mean by it using ccache as an executable rather than nuitka. Do you have any logs?

          you can also disable ccache by adding the option '--disable-ccache' to extra_args key in the generated pysidedeploy.spec file

          1 Reply Last reply
          0
          • Malvin LokM Offline
            Malvin LokM Offline
            Malvin Lok
            wrote on last edited by
            #5

            I am not using pyside6-deploy and just using the raw nuitka command, had built an executable file successfully.

            here is my commands:

            python -m nuitka \
                      --standalone \
                      --enable-plugin=pyside6\
                      --macos-create-app-bundle\
                      --macos-app-icon=./resource/icons/icons.icns\
                      --output-dir=$BUILD_PATH\
                      --assume-yes-for-download\
                      --macos-app-name=$APP_NAME\
                      --disable-console \
                      main.py
            

            but I don't use QML.

            1 Reply Last reply
            0

            • Login

            • Login or register to search.
            • First post
              Last post
            0
            • Categories
            • Recent
            • Tags
            • Popular
            • Users
            • Groups
            • Search
            • Get Qt Extensions
            • Unsolved