Skip to content

make setup.py supporting also Windows #11

@gui36

Description

@gui36

Directions

I try to install ssh2-python3 using pip on Windows and bumped into the following error:

Bug reports

Steps to reproduce:

  1. Stack trace or error messages.

    File "", line 2, in
    File "", line 34, in
    File "C:\Windows\Temp\pip-install-ux1l1dl3\ssh2-python3_238dbd1ca91e42c68658af3296450245\setup.py", line 12, in
    LIBC = os.confstr('CS_GNU_LIBC_VERSION').replace(" ", "")
    AttributeError: module 'os' has no attribute 'confstr'

according to https://docs.python.org/3.10/library/os.html, confstr is only available on unix.
and of course libc is from unix architecture too.

Expected behaviour: [What was expected to happen.]

Able to install ssh2-python3 on windows using pip

Actual behaviour: [What actually happened.]

NOT able to install ssh2-python3 on windows using pip

Additional info: [Include version of libssh2 and any other relevant information.]

It used to be supported nicely in the previous version:
https://github.com/ParallelSSH/ssh2-python/blob/master/setup.py

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions