Skip to content

Commit

Permalink
Merge branch 'L1'
Browse files Browse the repository at this point in the history
  • Loading branch information
manojampalam committed Feb 25, 2016
2 parents 3a18080 + 1f825c7 commit 03ade97
Show file tree
Hide file tree
Showing 4 changed files with 66 additions and 3 deletions.
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,3 +8,6 @@ See the [wiki](https://github.com/PowerShell/Win32-OpenSSH/wiki) for installatio
[First release announcement](http://blogs.msdn.com/b/powershell/archive/2015/10/19/openssh-for-windows-update.aspx
)

### Chocolatey

[![](http://img.shields.io/chocolatey/dt/win32-openssh.svg)](https://chocolatey.org/packages/win32-openssh) [![](http://img.shields.io/chocolatey/v/win32-openssh.svg)](https://chocolatey.org/packages/win32-openssh)
45 changes: 45 additions & 0 deletions contrib/win32/openssh/OpenSSL-1.0.2d_build.cmd
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
set OPENSSL_VERSION=1.0.2d
set PerlPath=c:\perl\bin
set NASMPath=c:\nasm

set VS2013="C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\bin\vcvars32.bat"
set VS2013_AMD64="C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\bin\amd64\vcvars64.bat"
set VS2015="C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\bin\vcvars32.bat"
set VS2015_AMD64="C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\bin\amd64\vcvars64.bat"

set path=%NASMPath%;%PerlPath%;%path%


CALL %VS2015%

cd \Dev\OpenSSL\openssl-%OPENSSL_VERSION%-src-x86
perl Configure VC-WIN32 --prefix=C:\dev\OpenSSL\%OPENSSL_VERSION%\VS2015\Win32\Release
call ms\do_ms.bat
call ms\do_nasm.bat
nmake -f ms\nt.mak clean
nmake -f ms\nt.mak
nmake -f ms\nt.mak install

cd \Dev\OpenSSL\openssl-%OPENSSL_VERSION%-src-x86
perl Configure debug-VC-WIN32 --prefix=C:\dev\OpenSSL\%OPENSSL_VERSION%\VS2015\Win32\Debug
call ms\do_ms.bat
call ms\do_nasm.bat
nmake -f ms\nt.mak clean
nmake -f ms\nt.mak
nmake -f ms\nt.mak install

CALL %VS2015_AMD64%

cd \Dev\OpenSSL\openssl-%OPENSSL_VERSION%-src-x64
perl Configure VC-WIN64A --prefix=C:\dev\OpenSSL\%OPENSSL_VERSION%\VS2015\x64\Release
call ms\do_win64a.bat
nmake -f ms\nt.mak clean
nmake -f ms\nt.mak
nmake -f ms\nt.mak install

cd \Dev\OpenSSL\openssl-%OPENSSL_VERSION%-src-x64
perl Configure debug-VC-WIN64A --prefix=C:\dev\OpenSSL\%OPENSSL_VERSION%\VS2015\x64\Debug
call ms\do_win64a.bat
nmake -f ms\nt.mak clean
nmake -f ms\nt.mak
nmake -f ms\nt.mak install
17 changes: 14 additions & 3 deletions session.c
Original file line number Diff line number Diff line change
Expand Up @@ -117,6 +117,9 @@ FIXME: GFPZR: Function stat() may be undeclared.
#include <Userenv.h>
#include <shlobj.h>

#ifdef WIN32_PRAGMA_REMCON
#include <shlwapi.h>
#endif
extern char HomeDirLsaW[MAX_PATH];

#endif
Expand Down Expand Up @@ -599,9 +602,17 @@ do_exec_no_pty(Session *s, const char *command)
#ifndef WIN32_PRAGMA_REMCON
exec_command = s->pw->pw_shell;
#else
snprintf(exec_command_str, sizeof(exec_command_str),
"\\program files\\pragma\\shared files\\cmdserver.exe SSHD %d %d",
s->row, s->col );
if ( PathFileExists("\\program files\\pragma\\shared files\\cmdserver.exe") )
snprintf(exec_command_str, sizeof(exec_command_str),
"\\program files\\pragma\\shared files\\cmdserver.exe SSHD %d %d", s->row, s->col );
else {
// find base path of our executable
char basepath[MAX_PATH];
strcpy_s(basepath, MAX_PATH, __progname);
PathRemoveFileSpec(basepath); // get the full dir part of the name
snprintf(exec_command_str, sizeof(exec_command_str),
"%s\\cmdserver.exe SSHD %d %d", basepath,s->row, s->col);
}
exec_command = exec_command_str;
#endif
}
Expand Down
4 changes: 4 additions & 0 deletions sftp.c
Original file line number Diff line number Diff line change
Expand Up @@ -346,6 +346,10 @@ local_do_shell(const char *args)
static void
local_do_ls(const char *args)
{
#ifdef WIN32_FIXME
#undef _PATH_LS
#define _PATH_LS "dir"
#endif
if (!args || !*args)
local_do_shell(_PATH_LS);
else {
Expand Down

0 comments on commit 03ade97

Please sign in to comment.