Giter VIP home page Giter VIP logo

issh2's People

Contributors

frugghi avatar jan-e avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

issh2's Issues

Compile fail on SDK 12.2

We have tried to build a script in macOS 10.14.4 and xcode 10.2.1

`MAC29:iSSH2-master mtp$ ./iSSH2.sh
Initializing...

Libssh2 version: 1.8.2 (Automatically detected)
OpenSSL version: 1.1.1b (Automatically detected)
SDK version: 12.2 (Automatically detected)
Architectures: armv7 armv7s arm64 x86_64
OS min version: 8.0

openssl-1.1.1b.tar.gz already exists
MD5: 4532712e7bcc9414f5bce995e4e13930
Extracting openssl-1.1.1b.tar.gz
Building OpenSSL 1.1.1b, please wait...
libssl.a and libcrypto.a for armv7 already exist.
libssl.a and libcrypto.a for armv7s already exist.
libssl.a and libcrypto.a for arm64 already exist.
libssl.a and libcrypto.a for x86_64 already exist.
Building libssl.a fat library...
Building libcrypto.a fat library...
Copying headers...
Building done.
libssh2-1.8.2.tar.gz already exists
MD5: 616efd99af3d9ef731a26bed6cee9593
Extracting libssh2-1.8.2.tar.gz
Building Libssh2 1.8.2:
Build failed, cleaning up temporary files...
MAC29:iSSH2-master mtp$ `

Error on each build of Libssh2, seems to be a non-issue

Whenever I run iSSH2.sh, OpenSSL builds just fine but I keep getting errors when building Libssh2.

Initializing...

Libssh2 version: 1.8.0 (Automatically detected)
OpenSSL version: 1.1.0g (Automatically detected)
SDK version: 11.2 (Automatically detected)
Architectures: armv7 armv7s arm64 x86_64
OS min version: 8.0

Downloading openssl-1.1.0g.tar.gz
######################################################################## 100.0%
MD5: ba5f1b8b835b88cadbce9b35ed9531a6
Extracting openssl-1.1.0g.tar.gz
Building OpenSSL 1.1.0g, please wait...
- iPhoneOS armv7 done!
- iPhoneOS armv7s done!
- iPhoneOS arm64 done!
- iPhoneSimulator x86_64 done!
Building libssl.a fat library...
Building libcrypto.a fat library...
Copying headers...
Building done.
Downloading libssh2-1.8.0.tar.gz
######################################################################## 100.0%
MD5: 3d1147cae66e2959ea5441b183de1b1c
Extracting libssh2-1.8.0.tar.gz
Building Libssh2 1.8.0:
Build failed, cleaning up temporary files...

However, it appears that the libssha2.a file is actually compiled successfully, as the next pass of iSSH2.sh shows the following output:

...
Copying headers...
Building done.
libssh2-1.8.0.tar.gz already exists
MD5: 3d1147cae66e2959ea5441b183de1b1c
Extracting libssh2-1.8.0.tar.gz
Building Libssh2 1.8.0:
libssh2.a for armv7 already exists.
Build failed, cleaning up temporary files...

The next run yields:

...
Copying headers...
Building done.
libssh2-1.8.0.tar.gz already exists
MD5: 3d1147cae66e2959ea5441b183de1b1c
Extracting libssh2-1.8.0.tar.gz
Building Libssh2 1.8.0:
libssh2.a for armv7 already exists.
libssh2.a for armv7s already exists.
Build failed, cleaning up temporary files...

This goes on until all of the libraries seemingly compile correctly:

Copying headers...
Building done.
libssh2-1.8.0.tar.gz already exists
MD5: 3d1147cae66e2959ea5441b183de1b1c
Extracting libssh2-1.8.0.tar.gz
Building Libssh2 1.8.0:
libssh2.a for armv7 already exists.
libssh2.a for armv7s already exists.
libssh2.a for arm64 already exists.
libssh2.a for x86_64 already exists.
Building libssh2.a fat library...
Copying headers...
Building done.
Cleaning up temporary files...

This is the end of the compile log of a failure:

make[2]: Nothing to be done for `install-exec-am'.
 /usr/local/bin/gmkdir -p '/var/folders/bk/d1v9y42n50q1m_bqwrjm5cjm0000gq/T/iSSH2/libssh2-1.8.0/iPhoneSimulator11.2-x86_64/lib/pkgconfig'
 /usr/local/bin/gmkdir -p '/var/folders/bk/d1v9y42n50q1m_bqwrjm5cjm0000gq/T/iSSH2/libssh2-1.8.0/iPhoneSimulator11.2-x86_64/include'
 /usr/local/bin/ginstall -c -m 644 include/libssh2.h include/libssh2_publickey.h include/libssh2_sftp.h '/var/folders/bk/d1v9y42n50q1m_bqwrjm5cjm0000gq/T/iSSH2/libssh2-1.8.0/iPhoneSimulator11.2-x86_64/include'
 /usr/local/bin/ginstall -c -m 644 libssh2.pc '/var/folders/bk/d1v9y42n50q1m_bqwrjm5cjm0000gq/T/iSSH2/libssh2-1.8.0/iPhoneSimulator11.2-x86_64/lib/pkgconfig'
ginstall: 'include/libssh2.h' and '/var/folders/bk/d1v9y42n50q1m_bqwrjm5cjm0000gq/T/iSSH2/libssh2-1.8.0/iPhoneSimulator11.2-x86_64/include/libssh2.h' are the same file
ginstall: 'include/libssh2_publickey.h' and '/var/folders/bk/d1v9y42n50q1m_bqwrjm5cjm0000gq/T/iSSH2/libssh2-1.8.0/iPhoneSimulator11.2-x86_64/include/libssh2_publickey.h' are the same file
ginstall: 'include/libssh2_sftp.h' and '/var/folders/bk/d1v9y42n50q1m_bqwrjm5cjm0000gq/T/iSSH2/libssh2-1.8.0/iPhoneSimulator11.2-x86_64/include/libssh2_sftp.h' are the same file
make[2]: *** [install-includeHEADERS] Error 1
make[2]: *** Waiting for unfinished jobs....
make[1]: *** [install-am] Error 2
make: *** [install-recursive] Error 1

I haven't actually tried using the compiled libraries yet.

issues when using on M1 laptop

I'm trying to test my app in the simulator, but I'm using a newer M1 laptop (arm64). Because Sim build is only executed if the arch is i386 or x86_64 when trying to link my app (sim) it complains about missing architecture of all the libraries.

The problem is that the platformName function in iSSH-commons is assuming iPhoneSimulator for non-arm archs. This was true before Apple introduced the M1 platform.

Build Failed - Libssh2 1.9.0

I get an error while compiling for iphoneos.
I saw an similar issue #5.

Maybe its something similar.

Thanks.


./iSSH2.sh --platform=iphoneos --xcodeproj=../ssh/ --min-version=13.2 
Initializing...

Libssh2 version: 1.9.0 (Automatically detected)
OpenSSL version: 1.1.1h (Automatically detected)
SDK version: 14.0 (Automatically detected)
Xcode version: 12.0.1 (Automatically detected)
Architectures: arm64 arm64e x86_64
Platform: iphoneos
Platform min version: 13.2

Downloading openssl-1.1.1h.tar.gz
################################################################################################################# 100,0%
MD5: 53840c70434793127a3574433494e8d3
Extracting openssl-1.1.1h.tar.gz
Building OpenSSL 1.1.1h, please wait...
- iPhoneOS arm64 done!
- iPhoneOS arm64e done!
- iPhoneSimulator x86_64 done!
Building libssl.a fat library...
Building libcrypto.a fat library...
Copying headers...
Building done.
Downloading libssh2-1.9.0.tar.gz
################################################################################################################# 100,0%################################################################################################################# 100,0%
MD5: 1beefafe8963982adc84b408b2959927
Extracting libssh2-1.9.0.tar.gz
Building Libssh2 1.9.0:
Build failed, cleaning up temporary files...

Missing `iSSH2-commons`

./iSSH2-libssh2.sh: line 26: /iSSH2-commons: No such file or directory
mkdir: : No such file or directory

macOS 14 (Sonoma) and Xcode 15 support

I know this is an early call, but at the moment this script fails on macOS 14 beta (Sonoma) with Xcode 15 beta:

xcode-select: error: tool 'xcodebuild' requires Xcode, but active developer directory '/Library/Developer/CommandLineTools' is a command line tools instance

Build with Xcode 8

Any ideas ? Using Xcode Version 8

Building libssl.a fat library...
fatal error: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/lipo: can't open input file: /var/folders/_1/z61z4f1d3xn4xq7wzd2w5w_w0000gp/T//iSSH2/openssl-1.1.0/iPhoneOS10.0-armv7/libssl.a (No such file or directory)
Build failed, cleaning up temporary files...

Compiling for Catalyst

Hi,
I'm trying to compile for Catalyst, and the way I try doing that is through making an .xcframework. So I tried the following:

sh iSSH2.sh --platform=macosx --archs="x86_64" # i386 no longer supported on 10.15
sh iSSH2.sh --platform=iphoneos --min-version=13.0

xcodebuild -create-xcframework \
-library libssh2_macosx/lib/libssh2.a -headers libssh2_macosx/include \
-library libssh2_iphoneos/lib/libssh2.a -headers libssh2_iphoneos/include \
-output libssh2.xcframework

But that gave me:
"error: binaries with multiple platforms are not supported 'libssh2_iphoneos/lib/libssh2.a'"

So I compiled x86_64 and arm64+arm64e separately

sh iSSH2.sh --platform=macosx --archs="x86_64"
sh iSSH2.sh --platform=iphoneos --min-version=13.0 --archs="arm64 arm64e"
mv libssh2_iphoneos libssh2_iphoneos_arm64_arm64e
sh iSSH2.sh --platform=iphoneos --min-version=13.0 --archs="x86_64"
mv libssh2_iphoneos libssh2_iphoneos_x86_64

xcodebuild -create-xcframework \
-library libssh2_macosx/lib/libssh2.a -headers libssh2_macosx/include \
-library libssh2_iphoneos_x86_64/lib/libssh2.a -headers libssh2_iphoneos_x86_64/include \
-library libssh2_iphoneos_arm64_arm64e/lib/libssh2.a -headers libssh2_iphoneos_arm64_arm64e/include \
-output libssh2.xcframework 

but that gave me a new error:
"error: unable to find any architecture information in the binary at 'libssh2_iphoneos_arm64_arm64e/lib/libssh2.a'"

Even splitting arm64 and arm64e into binaries for just them, or only include arm64 or arm64e themselves, gave me the same error. Why won't it find architecture information?

Not including arm64 and arm64e at all, however, gave me success:
"xcframework successfully written out to: libssh2.xcframework"

But obviously, I'd like a framework with arm64 and arm64e support. :-)

Any input on how to proceed from here? Would be really good to be able to build this for Mac Catalyst

OpenSSL 1.1.1

I have issues compiling libssh for arm64, while armv7 is ok.

global.c:48:9: error: implicit declaration of function 'ENGINE_load_builtin_engines' is invalid in C99 [-Werror,-Wimplicit-function-declaration]
        libssh2_crypto_init();
        ^
../src/openssl.h:231:3: note: expanded from macro 'libssh2_crypto_init'

configuration:
Libssh2 version: 1.8.0 (Automatically detected)
OpenSSL version: 1.1.1 (Automatically detected)
SDK version: 11.4 (Automatically detected)

All right with OpenSSL 1.1.0i.
Any ideas ?

Libssh2 1.9.0 building failed when trying to build OpenSSL 3.0.1

I tried to run the below command ./iSSH2.sh --platform=iphoneos --min-version=8.0 --openssl=3.0.1 to build specifically for OpenSSL 3.0.1 version as ./iSSH2.sh --platform=iphoneos --min-version=8.0 builds for OpenSSL version: 1.1.1m which is not required.

But it gives me the error like as shown below. Any resolution for this error? @Frugghi @Jan-E
Screenshot 2022-02-16 at 2 45 40 PM

build failed for macosx

When I ran the script I am getting the following error

`Initializing...

Libssh2 version: 1.9.0 (Automatically detected)
OpenSSL version: 1.1.1r (Automatically detected)
SDK version: 16.0 (Automatically detected)
Xcode version: 14.0.1 (Automatically detected)
Architectures: arm64 arm64e armv7 armv7s i386 x86_64
Platform: iphoneos
Platform min version: 8.0

openssl-1.1.1r.tar.gz already exists
MD5: bb8a5c2eff5c060e1701541ab2a02b88
Extracting openssl-1.1.1r.tar.gz
Building OpenSSL 1.1.1r, please wait...
Build failed, cleaning up temporary files...`

here is the command I am running

./iSSH2.sh --platform=iphoneos --min-version=8.0

I am running this on macosx monterey

Any help would be greatly appreciated. Thanks

Build with Xcode 7.3

I wonder if I do something wrong ...

MacBook-Pro:iSSH2 $ pwd
/Users/cl/Documents/Development/GitHub/iSSH2
MacBook-Pro:iSSH2 $ ./iSSH2.sh
Initializing...

Libssh2 version: 1.7.0 (Automatically detected)
OpenSSL version: 1.0.2g (Automatically detected)
SDK version: 9.3 (Automatically detected)
Architectures: armv7 armv7s arm64 i386 x86_64
OS min version: 8.0

openssl-1.0.2g.tar.gz already exists
MD5: f3c710c045cdee5fd114feb69feba7aa
Extracting openssl-1.0.2g.tar.gz
Building OpenSSL 1.0.2g, please wait...
Building libssl.a fat library...
fatal error: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/lipo: can't open input file: /var/folders/2q/v9d6rfmx6wdf6n9bhb5gqtr00000gn/T//iSSH2/openssl-1.0.2g/iPhoneOS9.3-armv7/libssl.a (No such file or directory)
Build failed, cleaning up temporary files...
MacBook-Pro:iSSH2 $

Any ideas ? Using Xcode Version 7.3 (7D175)

Libssh2 version fetched 1.9.0 instead of 1.10.0

Libssh2 version fetched 1.9.0 instead of 1.10.0

echo git ls-remote --tags https://github.com/libssh2/libssh2.git | egrep "libssh2-[0-9]+(\.[0-9])*[a-zA-Z]?$" | cut -f 2 -d - | sort -t . -r | head -n 1
1.9.0

Libssh2 no longer compiling on latest MacOS 10.14.6 with Xcode 10.3

MacOS 10.14.6
Xcode 10.3 (10G8)

Command used: ./iSSH2.sh --platform=macosx --min-version=10.14

The script automatically downloads openssl-1.1.1c and libssh2 1.9.0
Openssl compiles just fine but libssh2 fails with this error:

Extracting libssh2-1.9.0.tar.gz
Building Libssh2 1.9.0:
Build failed, cleaning up temporary files...

build-libssh2.log contains this:

Configure: WARNING: unrecognized options: --with-openssl
checking whether to enable maintainer-specific portions of Makefiles... no
checking whether make supports nested variables... yes
checking for sed... /usr/bin/sed
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for i386-apple-darwin-strip... no
checking for strip... strip
checking for a thread-safe mkdir -p... ./install-sh -c -d
checking for gawk... no
checking for mawk... no
checking for nawk... no
checking for awk... awk
checking whether make sets $(MAKE)... yes
checking libssh2 version... 1.9.0
checking build system type... x86_64-apple-darwin18.7.0
checking host system type... i386-apple-darwin
Configure: autobuild project... libssh2
Configure: autobuild revision... 1.9.0
Configure: autobuild hostname... AlexsMacMini
Configure: autobuild timestamp... 20190909-112840
checking whether make supports the include directive... yes (GNU style)
checking for i386-apple-darwin-gcc... /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang
checking whether the C compiler works... no
Configure: error: in `/var/folders/zr/ph6s5xdx0858lcm33599_l980000gn/T/iSSH2/libssh2-1.9.0/MacOSX_10.14-i386/src':
Configure: error: C compiler cannot create executables
See `config.log' for more detai

In config.log it seems to fail here:

clang: error: unsupported option '-V -Wno-atomic-implicit-seq-cst'
clang: error: no input files

clang: error: unknown argument '-qversion', did you mean '--version'?
clang: error: no input files

Here is the complete file:
config.log

Compiling for Apple Silicon

Hi,

./iSSH2.sh --platform=macosx --archs=arm64 --min-version=10.16

gives me a simple

Build failed, cleaning up temporary files...

Has anyone been able to modify the script to get a ARM build for macOS?

OpenSSL should build for ARM (openssl/openssl@61168b5) not so sure about libssh2

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.