Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issue while installing wolfssl in windows #52

Open
Souravkumar2434 opened this issue Jun 6, 2024 · 2 comments
Open

Issue while installing wolfssl in windows #52

Souravkumar2434 opened this issue Jun 6, 2024 · 2 comments
Assignees

Comments

@Souravkumar2434
Copy link

Hi,

i am trying to install wolfssl library in windows. i have python 3.10.11 version.
when i am giving pip install wolfssl comamnd, it is exiting the process with error
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command './autogen.sh' returned non-zero exit status 1.

can anybody please help me with this issue as it is a top priority for me.

@kareem-wolfssl kareem-wolfssl self-assigned this Jun 10, 2024
@kareem-wolfssl
Copy link

Hi @Souravkumar2434 ,

What environment are you using pip in on Windows? For example Cygwin, MSYS2, WSL, Powershell...
Do you have autotools installed in your environment? Can you attach a full error log?

@LieutenantEva
Copy link

LieutenantEva commented Nov 25, 2024

EDIT: Issue solved by using WSL Debian.

sudo apt update
sudo apt upgrade
sudo apt-get install build-essential autoconf libtool make python3 python3-pip python3-cffi
python3 -m pip install wolfssl

Hello,

I recently have same issue as above.

Powershel Output:

PS D:\Projects\Python\cso-client> & d:/Projects/Python/cso-client/.venv/Scripts/Activate.ps1
(.venv) PS D:\Projects\Python\cso-client> python --version
Python 3.13.0
(.venv) PS D:\Projects\Python\cso-client> gcc --version
gcc.exe (GCC) 13.2.0
Copyright (C) 2023 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

(.venv) PS D:\Projects\Python\cso-client> pip install wolfssl 
Collecting wolfssl
  Using cached wolfssl-5.7.4.post0.tar.gz (47 kB)
  Installing build dependencies ... done
  Getting requirements to build wheel ... done
  Installing backend dependencies ... done
  Preparing metadata (pyproject.toml) ... error
  error: subprocess-exited-with-error
  
  × Preparing metadata (pyproject.toml) did not run successfully.
  │ exit code: 1
  ╰─> [125 lines of output]
      C:\Users\STRONGHOLD\AppData\Local\Temp\pip-build-env-5_q2c2ue\overlay\Lib\site-packages\setuptools\_distutils\dist.py:261: UserWarning: Unknown distribution option: 'test_suite'
        warnings.warn(msg)
      C:\Users\STRONGHOLD\AppData\Local\Temp\pip-build-env-5_q2c2ue\overlay\Lib\site-packages\setuptools\_distutils\dist.py:261: UserWarning: Unknown distribution option: 'tests_require'
        warnings.warn(msg)

      DEBUG: Skipping native feature detection, build not using USE_LOCAL_WOLFSSL
      Cloning into 'wolfssl'...
      Updating files:  87% (2560/2913)
      Updating files:  88% (2564/2913)
      Updating files:  89% (2593/2913)
      Updating files:  90% (2622/2913)
      Updating files:  91% (2651/2913)
      Updating files:  92% (2680/2913)
      Updating files:  93% (2710/2913)
      Updating files:  94% (2739/2913)
      Updating files:  95% (2768/2913)
      Updating files:  96% (2797/2913)
      Updating files:  97% (2826/2913)
      Updating files:  98% (2855/2913)
      Updating files:  99% (2884/2913)
      Updating files: 100% (2913/2913)
      Updating files: 100% (2913/2913), done.
      From https://github.com/wolfssl/wolfssl
       * [new tag]         v5.7.4-stable -> v5.7.4-stable
      Note: switching to 'v5.7.4-stable'.

      You are in 'detached HEAD' state. You can look around, make experimental
      changes and commit them, and you can discard any commits you make in this
      state without impacting any branches by switching back to a branch.

      If you want to create a new branch to retain commits you create, you may
      do so (now or later) by using -c with the switch command. Example:

        git switch -c <new-branch-name>

      Or undo this operation with:

        git switch -

      Turn off this advice by setting config variable advice.detachedHead to false

      HEAD is now at bdd6231 Merge pull request #8111 from JacobBarthelmeh/release
      '.' is not recognized as an internal or external command,
      operable program or batch file.
      'libtoolize' is not recognized as an internal or external command,
      operable program or batch file.
      Calling: 'git fetch --depth=1 origin tag v5.7.4-stable' from working directory C:\Users\STRONGHOLD\AppData\Local\Temp\pip-install-u94ddcih\wolfssl_72ed7e3dba0e4a37ab4a376b259d3161\lib\wolfssl
      Calling: 'git checkout --force v5.7.4-stable' from working directory C:\Users\STRONGHOLD\AppData\Local\Temp\pip-install-u94ddcih\wolfssl_72ed7e3dba0e4a37ab4a376b259d3161\lib\wolfssl
      Calling: 'git clean -fdX' from working directory C:\Users\STRONGHOLD\AppData\Local\Temp\pip-install-u94ddcih\wolfssl_72ed7e3dba0e4a37ab4a376b259d3161\lib\wolfssl
      Calling: './autogen.sh' from working directory C:\Users\STRONGHOLD\AppData\Local\Temp\pip-install-u94ddcih\wolfssl_72ed7e3dba0e4a37ab4a376b259d3161\lib\wolfssl
      Calling: 'libtoolize' from working directory C:\Users\STRONGHOLD\AppData\Local\Temp\pip-install-u94ddcih\wolfssl_72ed7e3dba0e4a37ab4a376b259d3161\lib\wolfssl
      Traceback (most recent call last):
        File "./wolfssl/_build_ffi.py", line 204, in make
          call("./autogen.sh")
          ~~~~^^^^^^^^^^^^^^^^
        File "./wolfssl/_build_ffi.py", line 79, in call
          subprocess.check_call(cmd, shell=True, env=os.environ)
          ~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
        File "D:\.scoop\_global\apps\python\current\Lib\subprocess.py", line 419, in check_call
          raise CalledProcessError(retcode, cmd)
      subprocess.CalledProcessError: Command './autogen.sh' returned non-zero exit status 1.

      During handling of the above exception, another exception occurred:

      Traceback (most recent call last):
        File "D:\Projects\Python\cso-client\.venv\Lib\site-packages\pip\_vendor\pyproject_hooks\_in_process\_in_process.py", line 353, in <module>
          main()
          ~~~~^^
        File "D:\Projects\Python\cso-client\.venv\Lib\site-packages\pip\_vendor\pyproject_hooks\_in_process\_in_process.py", line 335, in main
          json_out['return_val'] = hook(**hook_input['kwargs'])
                                   ~~~~^^^^^^^^^^^^^^^^^^^^^^^^
        File "D:\Projects\Python\cso-client\.venv\Lib\site-packages\pip\_vendor\pyproject_hooks\_in_process\_in_process.py", line 149, in prepare_metadata_for_build_wheel
          return hook(metadata_directory, config_settings)
        File "C:\Users\STRONGHOLD\AppData\Local\Temp\pip-build-env-5_q2c2ue\overlay\Lib\site-packages\setuptools\build_meta.py", line 377, in prepare_metadata_for_build_wheel
          self.run_setup()
          ~~~~~~~~~~~~~~^^
        File "C:\Users\STRONGHOLD\AppData\Local\Temp\pip-build-env-5_q2c2ue\overlay\Lib\site-packages\setuptools\build_meta.py", line 522, in run_setup
          super().run_setup(setup_script=setup_script)
          ~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^
        File "C:\Users\STRONGHOLD\AppData\Local\Temp\pip-build-env-5_q2c2ue\overlay\Lib\site-packages\setuptools\build_meta.py", line 320, in run_setup
          exec(code, locals())
          ~~~~^^^^^^^^^^^^^^^^
        File "<string>", line 53, in <module>
        File "C:\Users\STRONGHOLD\AppData\Local\Temp\pip-build-env-5_q2c2ue\overlay\Lib\site-packages\setuptools\__init__.py", line 117, in setup
          return distutils.core.setup(**attrs)
                 ~~~~~~~~~~~~~~~~~~~~^^^^^^^^^
        File "C:\Users\STRONGHOLD\AppData\Local\Temp\pip-build-env-5_q2c2ue\overlay\Lib\site-packages\setuptools\_distutils\core.py", line 145, in setup
          _setup_distribution = dist = klass(attrs)
                                       ~~~~~^^^^^^^
        File "C:\Users\STRONGHOLD\AppData\Local\Temp\pip-build-env-5_q2c2ue\overlay\Lib\site-packages\setuptools\dist.py", line 319, in __init__
          _Distribution.__init__(self, dist_attrs)
          ~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^
        File "C:\Users\STRONGHOLD\AppData\Local\Temp\pip-build-env-5_q2c2ue\overlay\Lib\site-packages\setuptools\_distutils\dist.py", line 279, in __init__
          self.finalize_options()
          ~~~~~~~~~~~~~~~~~~~~~^^
        File "C:\Users\STRONGHOLD\AppData\Local\Temp\pip-build-env-5_q2c2ue\overlay\Lib\site-packages\setuptools\dist.py", line 677, in finalize_options
          ep(self)
          ~~^^^^^^
        File "C:\Users\STRONGHOLD\AppData\Local\Temp\pip-build-env-5_q2c2ue\overlay\Lib\site-packages\setuptools\dist.py", line 697, in _finalize_setup_keywords
          ep.load()(self, ep.name, value)
          ~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^
        File "C:\Users\STRONGHOLD\AppData\Local\Temp\pip-build-env-5_q2c2ue\normal\Lib\site-packages\cffi\setuptools_ext.py", line 216, in cffi_modules
          add_cffi_module(dist, cffi_module)
          ~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^
        File "C:\Users\STRONGHOLD\AppData\Local\Temp\pip-build-env-5_q2c2ue\normal\Lib\site-packages\cffi\setuptools_ext.py", line 49, in add_cffi_module
          execfile(build_file_name, mod_vars)
          ~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^
        File "C:\Users\STRONGHOLD\AppData\Local\Temp\pip-build-env-5_q2c2ue\normal\Lib\site-packages\cffi\setuptools_ext.py", line 25, in execfile
          exec(code, glob, glob)
          ~~~~^^^^^^^^^^^^^^^^^^
        File "./wolfssl/_build_ffi.py", line 294, in <module>
          generate_libwolfssl()
          ~~~~~~~~~~~~~~~~~~~^^
        File "./wolfssl/_build_ffi.py", line 263, in generate_libwolfssl
          make(make_flags(prefix, False))
          ~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^
        File "./wolfssl/_build_ffi.py", line 206, in make
          call("libtoolize")
          ~~~~^^^^^^^^^^^^^^
        File "./wolfssl/_build_ffi.py", line 79, in call
          subprocess.check_call(cmd, shell=True, env=os.environ)
          ~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
        File "D:\.scoop\_global\apps\python\current\Lib\subprocess.py", line 419, in check_call
          raise CalledProcessError(retcode, cmd)
      subprocess.CalledProcessError: Command 'libtoolize' returned non-zero exit status 1.
      [end of output]

  note: This error originates from a subprocess, and is likely not a problem with pip.
error: metadata-generation-failed

× Encountered error while generating package metadata.
╰─> See above for output.

note: This is an issue with the package mentioned above, not pip.
hint: See above for details.
(.venv) PS D:\Projects\Python\cso-client>

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants