Update to 7-Zip 17.00 Beta

This commit is contained in:
Tino Reichardt
2017-04-30 14:14:14 +02:00
parent 54389d6e2f
commit aa5ba75da0
451 changed files with 15746 additions and 8574 deletions

View File

@@ -410,6 +410,10 @@ SOURCE=..\..\..\Common\Wildcard.h
# End Source File
# Begin Source File
SOURCE=..\..\..\Common\XzCrc64Init.cpp
# End Source File
# Begin Source File
SOURCE=..\..\..\Common\XzCrc64Reg.cpp
# End Source File
# End Group
@@ -514,6 +518,14 @@ SOURCE=..\..\..\Windows\PropVariantConv.h
# End Source File
# Begin Source File
SOURCE=..\..\..\Windows\PropVariantUtils.cpp
# End Source File
# Begin Source File
SOURCE=..\..\..\Windows\PropVariantUtils.h
# End Source File
# Begin Source File
SOURCE=..\..\..\Windows\Synchronization.cpp
# End Source File
# Begin Source File
@@ -903,14 +915,6 @@ SOURCE=..\..\Compress\ImplodeDecoder.cpp
SOURCE=..\..\Compress\ImplodeDecoder.h
# End Source File
# Begin Source File
SOURCE=..\..\Compress\ImplodeHuffmanDecoder.cpp
# End Source File
# Begin Source File
SOURCE=..\..\Compress\ImplodeHuffmanDecoder.h
# End Source File
# End Group
# Begin Group "LZMA"
@@ -1232,6 +1236,22 @@ SOURCE=..\..\Compress\LzOutWindow.cpp
SOURCE=..\..\Compress\LzOutWindow.h
# End Source File
# Begin Source File
SOURCE=..\..\Compress\XzDecoder.cpp
# End Source File
# Begin Source File
SOURCE=..\..\Compress\XzDecoder.h
# End Source File
# Begin Source File
SOURCE=..\..\Compress\XzEncoder.cpp
# End Source File
# Begin Source File
SOURCE=..\..\Compress\XzEncoder.h
# End Source File
# End Group
# Begin Group "Archive"

View File

@@ -22,6 +22,7 @@ COMMON_OBJS = \
$O\UTFConvert.obj \
$O\MyVector.obj \
$O\Wildcard.obj \
$O\XzCrc64Init.obj \
$O\XzCrc64Reg.obj \
$O\Sha1Reg.obj \
$O\Sha256Reg.obj \
@@ -38,6 +39,7 @@ WIN_OBJS = \
$O\MemoryLock.obj \
$O\PropVariant.obj \
$O\PropVariantConv.obj \
$O\PropVariantUtils.obj \
$O\Synchronization.obj \
$O\System.obj \
$O\TimeUtils.obj \
@@ -152,7 +154,6 @@ COMPRESS_OBJS = \
$O\DeflateRegister.obj \
$O\DeltaFilter.obj \
$O\ImplodeDecoder.obj \
$O\ImplodeHuffmanDecoder.obj \
$O\Lzma2Decoder.obj \
$O\Lzma2Encoder.obj \
$O\Lzma2Register.obj \
@@ -167,6 +168,8 @@ COMPRESS_OBJS = \
$O\PpmdZip.obj \
$O\QuantumDecoder.obj \
$O\ShrinkDecoder.obj \
$O\XzDecoder.obj \
$O\XzEncoder.obj \
$O\ZDecoder.obj \
CRYPTO_OBJS = \
@@ -257,12 +260,12 @@ ZSTD_OBJS = \
$O\zstd_v07.obj \
ZSTDMT_OBJS = \
$O\lz5mt_common.obj \
$O\lz5mt_compress.obj \
$O\lz5mt_decompress.obj \
$O\lz4mt_common.obj \
$O\lz4mt_compress.obj \
$O\lz4mt_decompress.obj \
$O\lz5mt_common.obj \
$O\lz5mt_compress.obj \
$O\lz5mt_decompress.obj \
$O\threading.obj \
$O\zstdmt_common.obj \
$O\zstdmt_compress.obj \

View File

@@ -406,6 +406,10 @@ SOURCE=..\..\..\Common\Wildcard.h
# End Source File
# Begin Source File
SOURCE=..\..\..\Common\XzCrc64Init.cpp
# End Source File
# Begin Source File
SOURCE=..\..\..\Common\XzCrc64Reg.cpp
# End Source File
# End Group
@@ -804,6 +808,22 @@ SOURCE=..\..\Compress\LzmaEncoder.h
SOURCE=..\..\Compress\LzmaRegister.cpp
# End Source File
# Begin Source File
SOURCE=..\..\Compress\XzDecoder.cpp
# End Source File
# Begin Source File
SOURCE=..\..\Compress\XzDecoder.h
# End Source File
# Begin Source File
SOURCE=..\..\Compress\XzEncoder.cpp
# End Source File
# Begin Source File
SOURCE=..\..\Compress\XzEncoder.h
# End Source File
# End Group
# Begin Group "Archive"

View File

@@ -22,6 +22,7 @@ COMMON_OBJS = \
$O\UTFConvert.obj \
$O\MyVector.obj \
$O\Wildcard.obj \
$O\XzCrc64Init.obj \
$O\XzCrc64Reg.obj \
WIN_OBJS = \
@@ -109,6 +110,8 @@ COMPRESS_OBJS = \
$O\LzmaDecoder.obj \
$O\LzmaEncoder.obj \
$O\LzmaRegister.obj \
$O\XzDecoder.obj \
$O\XzEncoder.obj \
CRYPTO_OBJS = \
$O\7zAes.obj \

View File

@@ -995,6 +995,24 @@ SOURCE=..\..\..\..\C\LzFindMt.h
# End Source File
# Begin Source File
SOURCE=..\..\..\..\C\Lzma2Dec.c
# SUBTRACT CPP /YX /Yc /Yu
# End Source File
# Begin Source File
SOURCE=..\..\..\..\C\Lzma2Dec.h
# End Source File
# Begin Source File
SOURCE=..\..\..\..\C\Lzma2Enc.c
# SUBTRACT CPP /YX /Yc /Yu
# End Source File
# Begin Source File
SOURCE=..\..\..\..\C\Lzma2Enc.h
# End Source File
# Begin Source File
SOURCE=..\..\..\..\C\LzmaDec.c
# SUBTRACT CPP /YX /Yc /Yu
# End Source File
@@ -1013,6 +1031,15 @@ SOURCE=..\..\..\..\C\LzmaEnc.h
# End Source File
# Begin Source File
SOURCE=..\..\..\..\C\MtCoder.c
# SUBTRACT CPP /YX /Yc /Yu
# End Source File
# Begin Source File
SOURCE=..\..\..\..\C\MtCoder.h
# End Source File
# Begin Source File
SOURCE=..\..\..\..\C\Sha256.c
!IF "$(CFG)" == "FM - Win32 Release"
@@ -1911,6 +1938,26 @@ SOURCE=..\..\Compress\CopyRegister.cpp
# End Source File
# Begin Source File
SOURCE=..\..\Compress\Lzma2Decoder.cpp
# End Source File
# Begin Source File
SOURCE=..\..\Compress\Lzma2Decoder.h
# End Source File
# Begin Source File
SOURCE=..\..\Compress\Lzma2Encoder.cpp
# End Source File
# Begin Source File
SOURCE=..\..\Compress\Lzma2Encoder.h
# End Source File
# Begin Source File
SOURCE=..\..\Compress\Lzma2Register.cpp
# End Source File
# Begin Source File
SOURCE=..\..\Compress\LzmaDecoder.cpp
# End Source File
# Begin Source File

View File

@@ -138,10 +138,27 @@ C_OBJS = \
!include "../../Crc.mak"
COMPRESS_OBJS = $(COMPRESS_OBJS) \
$O\Lz4Decoder.obj \
$O\Lz4Encoder.obj \
$O\Lz4Register.obj \
$O\Lz5Decoder.obj \
$O\Lz5Encoder.obj \
$O\Lz5Register.obj \
$O\ZstdDecoder.obj \
$O\ZstdEncoder.obj \
$O\ZstdRegister.obj \
LZ4_OBJS = \
$O\lz4.obj \
$O\lz4frame.obj \
$O\lz4hc.obj \
$O\lz4xxhash.obj \
LZ5_OBJS = \
$O\lz5.obj \
$O\lz5frame.obj \
$O\lz5hc.obj \
ZSTD_OBJS = \
$O\entropy_common.obj \
$O\fse_decompress.obj \
@@ -156,6 +173,12 @@ ZSTD_OBJS = \
ZSTDMT_OBJS = \
$O\threading.obj \
$O\lz4mt_common.obj \
$O\lz4mt_compress.obj \
$O\lz4mt_decompress.obj \
$O\lz5mt_common.obj \
$O\lz5mt_compress.obj \
$O\lz5mt_decompress.obj \
$O\zstdmt_common.obj \
$O\zstdmt_compress.obj \
$O\zstdmt_decompress.obj \

View File

@@ -14,6 +14,7 @@ COMMON_OBJS = \
$O\StringToInt.obj \
$O\UTFConvert.obj \
$O\Wildcard.obj \
$O\XzCrc64Init.obj \
$O\XzCrc64Reg.obj \
WIN_OBJS = \
@@ -200,7 +201,6 @@ COMPRESS_OBJS = \
$O\DeflateRegister.obj \
$O\DeltaFilter.obj \
$O\ImplodeDecoder.obj \
$O\ImplodeHuffmanDecoder.obj \
$O\LzhDecoder.obj \
$O\Lzma2Decoder.obj \
$O\Lzma2Encoder.obj \
@@ -223,10 +223,13 @@ COMPRESS_OBJS = \
$O\Rar5Decoder.obj \
$O\RarCodecsRegister.obj \
$O\ShrinkDecoder.obj \
$O\XpressDecoder.obj \
$O\XzDecoder.obj \
$O\XzEncoder.obj \
$O\ZlibDecoder.obj \
$O\ZlibEncoder.obj \
$O\ZDecoder.obj \
$O\XPressDecoder.obj \
CRYPTO_OBJS = \
$O\7zAes.obj \

View File

@@ -271,6 +271,10 @@ SOURCE=..\..\..\Common\MyBuffer.h
# End Source File
# Begin Source File
SOURCE=..\..\..\Common\MyBuffer2.h
# End Source File
# Begin Source File
SOURCE=..\..\..\Common\MyCom.h
# End Source File
# Begin Source File
@@ -383,6 +387,10 @@ SOURCE=..\..\..\Common\Wildcard.h
# End Source File
# Begin Source File
SOURCE=..\..\..\Common\XzCrc64Init.cpp
# End Source File
# Begin Source File
SOURCE=..\..\..\Common\XzCrc64Reg.cpp
# End Source File
# End Group
@@ -419,6 +427,16 @@ SOURCE=..\..\Compress\BitmEncoder.h
# Begin Source File
SOURCE=..\..\Compress\Rar1Decoder.cpp
!IF "$(CFG)" == "7z - Win32 Release"
# ADD CPP /O2
# SUBTRACT CPP /YX /Yc /Yu
!ELSEIF "$(CFG)" == "7z - Win32 Debug"
!ENDIF
# End Source File
# Begin Source File
@@ -427,6 +445,16 @@ SOURCE=..\..\Compress\Rar1Decoder.h
# Begin Source File
SOURCE=..\..\Compress\Rar2Decoder.cpp
!IF "$(CFG)" == "7z - Win32 Release"
# ADD CPP /O2
# SUBTRACT CPP /YX /Yc /Yu
!ELSEIF "$(CFG)" == "7z - Win32 Debug"
!ENDIF
# End Source File
# Begin Source File
@@ -453,6 +481,16 @@ SOURCE=..\..\Compress\Rar3Decoder.h
# Begin Source File
SOURCE=..\..\Compress\Rar3Vm.cpp
!IF "$(CFG)" == "7z - Win32 Release"
# ADD CPP /O2
# SUBTRACT CPP /YX /Yc /Yu
!ELSEIF "$(CFG)" == "7z - Win32 Debug"
!ENDIF
# End Source File
# Begin Source File
@@ -479,6 +517,16 @@ SOURCE=..\..\Compress\Rar5Decoder.h
# Begin Source File
SOURCE=..\..\Compress\RarCodecsRegister.cpp
!IF "$(CFG)" == "7z - Win32 Release"
# ADD CPP /O2
# SUBTRACT CPP /YX /Yc /Yu
!ELSEIF "$(CFG)" == "7z - Win32 Debug"
!ENDIF
# End Source File
# End Group
# Begin Group "BZip2 Compress"
@@ -491,6 +539,16 @@ SOURCE=..\..\Compress\BZip2Const.h
# Begin Source File
SOURCE=..\..\Compress\BZip2Crc.cpp
!IF "$(CFG)" == "7z - Win32 Release"
# ADD CPP /O2
# SUBTRACT CPP /YX /Yc /Yu
!ELSEIF "$(CFG)" == "7z - Win32 Debug"
!ENDIF
# End Source File
# Begin Source File
@@ -499,6 +557,16 @@ SOURCE=..\..\Compress\BZip2Crc.h
# Begin Source File
SOURCE=..\..\Compress\BZip2Decoder.cpp
!IF "$(CFG)" == "7z - Win32 Release"
# ADD CPP /O2
# SUBTRACT CPP /YX /Yc /Yu
!ELSEIF "$(CFG)" == "7z - Win32 Debug"
!ENDIF
# End Source File
# Begin Source File
@@ -507,6 +575,16 @@ SOURCE=..\..\Compress\BZip2Decoder.h
# Begin Source File
SOURCE=..\..\Compress\BZip2Encoder.cpp
!IF "$(CFG)" == "7z - Win32 Release"
# ADD CPP /O2
# SUBTRACT CPP /YX /Yc /Yu
!ELSEIF "$(CFG)" == "7z - Win32 Debug"
!ENDIF
# End Source File
# Begin Source File
@@ -515,6 +593,16 @@ SOURCE=..\..\Compress\BZip2Encoder.h
# Begin Source File
SOURCE=..\..\Compress\BZip2Register.cpp
!IF "$(CFG)" == "7z - Win32 Release"
# ADD CPP /O2
# SUBTRACT CPP /YX /Yc /Yu
!ELSEIF "$(CFG)" == "7z - Win32 Debug"
!ENDIF
# End Source File
# Begin Source File
@@ -527,6 +615,16 @@ SOURCE=..\..\Compress\Mtf8.h
# Begin Source File
SOURCE=..\..\Compress\Deflate64Register.cpp
!IF "$(CFG)" == "7z - Win32 Release"
# ADD CPP /O2
# SUBTRACT CPP /YX /Yc /Yu
!ELSEIF "$(CFG)" == "7z - Win32 Debug"
!ENDIF
# End Source File
# Begin Source File
@@ -535,6 +633,16 @@ SOURCE=..\..\Compress\DeflateConst.h
# Begin Source File
SOURCE=..\..\Compress\DeflateDecoder.cpp
!IF "$(CFG)" == "7z - Win32 Release"
# ADD CPP /O2
# SUBTRACT CPP /YX /Yc /Yu
!ELSEIF "$(CFG)" == "7z - Win32 Debug"
!ENDIF
# End Source File
# Begin Source File
@@ -543,6 +651,16 @@ SOURCE=..\..\Compress\DeflateDecoder.h
# Begin Source File
SOURCE=..\..\Compress\DeflateEncoder.cpp
!IF "$(CFG)" == "7z - Win32 Release"
# ADD CPP /O2
# SUBTRACT CPP /YX /Yc /Yu
!ELSEIF "$(CFG)" == "7z - Win32 Debug"
!ENDIF
# End Source File
# Begin Source File
@@ -551,10 +669,30 @@ SOURCE=..\..\Compress\DeflateEncoder.h
# Begin Source File
SOURCE=..\..\Compress\DeflateRegister.cpp
!IF "$(CFG)" == "7z - Win32 Release"
# ADD CPP /O2
# SUBTRACT CPP /YX /Yc /Yu
!ELSEIF "$(CFG)" == "7z - Win32 Debug"
!ENDIF
# End Source File
# Begin Source File
SOURCE=..\..\Compress\ImplodeDecoder.cpp
!IF "$(CFG)" == "7z - Win32 Release"
# ADD CPP /O2
# SUBTRACT CPP /YX /Yc /Yu
!ELSEIF "$(CFG)" == "7z - Win32 Debug"
!ENDIF
# End Source File
# Begin Source File
@@ -562,15 +700,17 @@ SOURCE=..\..\Compress\ImplodeDecoder.h
# End Source File
# Begin Source File
SOURCE=..\..\Compress\ImplodeHuffmanDecoder.cpp
# End Source File
# Begin Source File
SOURCE=..\..\Compress\ImplodeHuffmanDecoder.h
# End Source File
# Begin Source File
SOURCE=..\..\Compress\PpmdZip.cpp
!IF "$(CFG)" == "7z - Win32 Release"
# ADD CPP /O2
# SUBTRACT CPP /YX /Yc /Yu
!ELSEIF "$(CFG)" == "7z - Win32 Debug"
!ENDIF
# End Source File
# Begin Source File
@@ -579,6 +719,16 @@ SOURCE=..\..\Compress\PpmdZip.h
# Begin Source File
SOURCE=..\..\Compress\ShrinkDecoder.cpp
!IF "$(CFG)" == "7z - Win32 Release"
# ADD CPP /O2
# SUBTRACT CPP /YX /Yc /Yu
!ELSEIF "$(CFG)" == "7z - Win32 Debug"
!ENDIF
# End Source File
# Begin Source File
@@ -587,6 +737,16 @@ SOURCE=..\..\Compress\ShrinkDecoder.h
# Begin Source File
SOURCE=..\..\Compress\ZlibDecoder.cpp
!IF "$(CFG)" == "7z - Win32 Release"
# ADD CPP /O2
# SUBTRACT CPP /YX /Yc /Yu
!ELSEIF "$(CFG)" == "7z - Win32 Debug"
!ENDIF
# End Source File
# Begin Source File
@@ -595,6 +755,16 @@ SOURCE=..\..\Compress\ZlibDecoder.h
# Begin Source File
SOURCE=..\..\Compress\ZlibEncoder.cpp
!IF "$(CFG)" == "7z - Win32 Release"
# ADD CPP /O2
# SUBTRACT CPP /YX /Yc /Yu
!ELSEIF "$(CFG)" == "7z - Win32 Debug"
!ENDIF
# End Source File
# Begin Source File
@@ -843,6 +1013,22 @@ SOURCE=..\..\Compress\XpressDecoder.h
# End Source File
# Begin Source File
SOURCE=..\..\Compress\XzDecoder.cpp
# End Source File
# Begin Source File
SOURCE=..\..\Compress\XzDecoder.h
# End Source File
# Begin Source File
SOURCE=..\..\Compress\XzEncoder.cpp
# End Source File
# Begin Source File
SOURCE=..\..\Compress\XzEncoder.h
# End Source File
# Begin Source File
SOURCE=..\..\Compress\ZDecoder.cpp
# End Source File
# Begin Source File
@@ -1300,6 +1486,10 @@ SOURCE=..\..\..\..\C\XzIn.c
# End Group
# Begin Source File
SOURCE=..\..\..\..\C\7zBuf.h
# End Source File
# Begin Source File
SOURCE=..\..\..\..\C\7zBuf2.c
# SUBTRACT CPP /YX /Yc /Yu
# End Source File

View File

@@ -1,6 +1,6 @@
#include "../../MyVersionInfo.rc"
MY_VERSION_INFO_DLL("7z Plugin", "7z")
MY_VERSION_INFO_DLL("7z Plugin" , "7z")
0 ICON "../../Archive/Icons/7z.ico"

View File

@@ -0,0 +1,3 @@
// StdAfx.cpp
#include "StdAfx.h"

View File

@@ -0,0 +1,8 @@
// StdAfx.h
#ifndef __STDAFX_H
#define __STDAFX_H
#include "../../../Common/Common.h"
#endif

View File

@@ -0,0 +1,186 @@
PROG = 7za.dll
DEF_FILE = ../../Archive/Archive2.def
CFLAGS = $(CFLAGS) -DNEED_7ZIP_GUID
COMMON_OBJS = \
$O\CRC.obj \
$O\CrcReg.obj \
$O\IntToString.obj \
$O\NewHandler.obj \
$O\MyString.obj \
$O\Sha256Reg.obj \
$O\StringConvert.obj \
$O\StringToInt.obj \
$O\MyVector.obj \
$O\Wildcard.obj \
WIN_OBJS = \
$O\FileDir.obj \
$O\FileFind.obj \
$O\FileIO.obj \
$O\FileName.obj \
$O\PropVariant.obj \
$O\Synchronization.obj \
$O\System.obj \
7ZIP_COMMON_OBJS = \
$O\CreateCoder.obj \
$O\CWrappers.obj \
$O\InBuffer.obj \
$O\InOutTempBuffer.obj \
$O\FilterCoder.obj \
$O\LimitedStreams.obj \
$O\MethodId.obj \
$O\MethodProps.obj \
$O\OutBuffer.obj \
$O\ProgressUtils.obj \
$O\PropId.obj \
$O\StreamBinder.obj \
$O\StreamObjects.obj \
$O\StreamUtils.obj \
$O\UniqBlocks.obj \
$O\VirtThread.obj \
AR_OBJS = \
$O\ArchiveExports.obj \
$O\DllExports2.obj \
AR_COMMON_OBJS = \
$O\CoderMixer2.obj \
$O\HandlerOut.obj \
$O\InStreamWithCRC.obj \
$O\ItemNameUtils.obj \
$O\OutStreamWithCRC.obj \
$O\ParseProperties.obj \
7Z_OBJS = \
$O\7zCompressionMode.obj \
$O\7zDecode.obj \
$O\7zEncode.obj \
$O\7zExtract.obj \
$O\7zFolderInStream.obj \
$O\7zHandler.obj \
$O\7zHandlerOut.obj \
$O\7zHeader.obj \
$O\7zIn.obj \
$O\7zOut.obj \
$O\7zProperties.obj \
$O\7zSpecStream.obj \
$O\7zUpdate.obj \
$O\7zRegister.obj \
COMPRESS_OBJS = \
$O\CodecExports.obj \
$O\Bcj2Coder.obj \
$O\Bcj2Register.obj \
$O\BcjCoder.obj \
$O\BcjRegister.obj \
$O\BitlDecoder.obj \
$O\BranchMisc.obj \
$O\BranchRegister.obj \
$O\ByteSwap.obj \
$O\BZip2Crc.obj \
$O\BZip2Encoder.obj \
$O\BZip2Decoder.obj \
$O\BZip2Register.obj \
$O\CopyCoder.obj \
$O\CopyRegister.obj \
$O\DeflateEncoder.obj \
$O\DeflateDecoder.obj \
$O\DeflateRegister.obj \
$O\DeltaFilter.obj \
$O\Lzma2Decoder.obj \
$O\Lzma2Encoder.obj \
$O\Lzma2Register.obj \
$O\LzmaDecoder.obj \
$O\LzmaEncoder.obj \
$O\LzmaRegister.obj \
$O\LzOutWindow.obj \
$O\PpmdDecoder.obj \
$O\PpmdEncoder.obj \
$O\PpmdRegister.obj \
CRYPTO_OBJS = \
$O\7zAes.obj \
$O\7zAesRegister.obj \
$O\MyAes.obj \
$O\MyAesReg.obj \
$O\RandGen.obj \
C_OBJS = \
$O\Alloc.obj \
$O\Bcj2.obj \
$O\Bcj2Enc.obj \
$O\Bra.obj \
$O\Bra86.obj \
$O\BraIA64.obj \
$O\BwtSort.obj \
$O\CpuArch.obj \
$O\Delta.obj \
$O\HuffEnc.obj \
$O\LzFind.obj \
$O\LzFindMt.obj \
$O\Lzma2Dec.obj \
$O\Lzma2Enc.obj \
$O\LzmaDec.obj \
$O\LzmaEnc.obj \
$O\MtCoder.obj \
$O\Ppmd7.obj \
$O\Ppmd7Dec.obj \
$O\Ppmd7Enc.obj \
$O\Sha256.obj \
$O\Sort.obj \
$O\Threads.obj \
!include "../../Aes.mak"
!include "../../Crc.mak"
COMPRESS_OBJS = $(COMPRESS_OBJS) \
$O\Lz4Decoder.obj \
$O\Lz4Encoder.obj \
$O\Lz4Register.obj \
$O\Lz5Decoder.obj \
$O\Lz5Encoder.obj \
$O\Lz5Register.obj \
$O\ZstdDecoder.obj \
$O\ZstdEncoder.obj \
$O\ZstdRegister.obj \
LZ4_OBJS = \
$O\lz4.obj \
$O\lz4frame.obj \
$O\lz4hc.obj \
$O\lz4xxhash.obj \
LZ5_OBJS = \
$O\lz5.obj \
$O\lz5frame.obj \
$O\lz5hc.obj \
ZSTD_OBJS = \
$O\entropy_common.obj \
$O\fse_decompress.obj \
$O\huf_decompress.obj \
$O\zstd_common.obj \
$O\zstd_decompress.obj \
$O\xxhash.obj \
$O\fse_compress.obj \
$O\huf_compress.obj \
$O\zstd_compress.obj \
$O\error_private.obj \
ZSTDMT_OBJS = \
$O\threading.obj \
$O\lz4mt_common.obj \
$O\lz4mt_compress.obj \
$O\lz4mt_decompress.obj \
$O\lz5mt_common.obj \
$O\lz5mt_compress.obj \
$O\lz5mt_decompress.obj \
$O\zstdmt_common.obj \
$O\zstdmt_compress.obj \
$O\zstdmt_decompress.obj \
!include "../../7zip.mak"

View File

@@ -0,0 +1,5 @@
#include "../../MyVersionInfo.rc"
MY_VERSION_INFO_DLL("7z Standalone Plugin", "7za")
101 ICON "../../Archive/Icons/7z.ico"

View File

@@ -4,6 +4,8 @@
#include <stdio.h>
#include "../../../../C/CpuArch.h"
#if (defined(_WIN32) || defined(OS2) || defined(MSDOS)) && !defined(UNDER_CE)
#include <fcntl.h>
#include <io.h>
@@ -39,14 +41,16 @@
#include "../../UI/Console/BenchCon.h"
#include "../../UI/Console/ConsoleClose.h"
bool g_LargePagesMode = false;
using namespace NCommandLineParser;
static const unsigned kDictSizeLog = 24;
static const char *kCopyrightString = "\nLZMA " MY_VERSION_COPYRIGHT_DATE "\n\n";
#define kCopyrightString "\nLZMA " MY_VERSION_CPU " : " MY_COPYRIGHT_DATE "\n\n"
static const char *kHelpString =
"Usage: LZMA <command> [inputFile] [outputFile] [<switches>...]\n"
static const char * const kHelpString =
"Usage: lzma <command> [inputFile] [outputFile] [<switches>...]\n"
"\n"
"<command>\n"
" e : Encode file\n"
@@ -67,9 +71,9 @@ static const char *kHelpString =
" -so : write data to stdout\n";
static const char *kCantAllocate = "Can not allocate memory";
static const char *kReadError = "Read error";
static const char *kWriteError = "Write error";
static const char * const kCantAllocate = "Can not allocate memory";
static const char * const kReadError = "Read error";
static const char * const kWriteError = "Write error";
namespace NKey {
@@ -117,6 +121,21 @@ static const CSwitchForm kSwitchForms[] =
};
static void Convert_UString_to_AString(const UString &s, AString &temp)
{
int codePage = CP_OEMCP;
/*
int g_CodePage = -1;
int codePage = g_CodePage;
if (codePage == -1)
codePage = CP_OEMCP;
if (codePage == CP_UTF8)
ConvertUnicodeToUTF8(s, temp);
else
*/
UnicodeStringToMultiByte2(temp, s, (UINT)codePage);
}
static void PrintErr(const char *s)
{
fputs(s, stderr);
@@ -135,10 +154,12 @@ static void PrintError(const char *s)
PrintErr_LF(s);
}
static void PrintError2(const char *s1, const wchar_t *s2)
static void PrintError2(const char *s1, const UString &s2)
{
PrintError(s1);
PrintErr_LF(GetOemString(s2));
AString a;
Convert_UString_to_AString(s2, a);
PrintErr_LF(a);
}
static void PrintError_int(const char *s, int code)
@@ -208,7 +229,7 @@ public:
#define BACK_STR \
"\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b"
static const char *kBackSpaces =
static const char * const kBackSpaces =
BACK_STR
" "
BACK_STR;
@@ -298,7 +319,7 @@ static int Error_HRESULT(const char *s, HRESULT res)
static void AddProp(CObjectVector<CProperty> &props2, const char *name, const wchar_t *val)
{
CProperty &prop = props2.AddNew();
prop.Name.SetFromAscii(name);
prop.Name = name;
prop.Value = val;
}
@@ -322,10 +343,10 @@ static int main2(int numArgs, const char *args[])
for (int i = 1; i < numArgs; i++)
commandStrings.Add(MultiByteToUnicodeString(args[i]));
CParser parser(ARRAY_SIZE(kSwitchForms));
CParser parser;
try
{
if (!parser.ParseStrings(kSwitchForms, commandStrings))
if (!parser.ParseStrings(kSwitchForms, ARRAY_SIZE(kSwitchForms), commandStrings))
{
PrintError2(parser.ErrorMessage, parser.ErrorLine);
return 1;
@@ -376,7 +397,7 @@ static int main2(int numArgs, const char *args[])
AddProp(props2, "x", s);
}
UString mf = L"BT4";
UString mf ("BT4");
if (parser[NKey::kMatchFinder].ThereIs)
mf = parser[NKey::kMatchFinder].PostStrings[0];

View File

@@ -2,6 +2,8 @@
#include "StdAfx.h"
#include "../../../../C/CpuArch.h"
#include "../../../Common/MyWindows.h"
#include "../../../Common/MyInitGuid.h"
@@ -37,8 +39,8 @@ HINSTANCE g_hInstance = 0;
int g_CodePage = -1;
extern CStdOutStream *g_StdStream;
static const char *kCopyrightString =
"\n7-Zip SFX " MY_VERSION_COPYRIGHT_DATE "\n";
static const char * const kCopyrightString =
"\n7-Zip SFX " MY_VERSION_CPU " : " MY_COPYRIGHT_DATE "\n";
static const int kNumSwitches = 6;
@@ -65,7 +67,6 @@ enum EEnum
}
/*
static const char kRecursedIDChar = 'R';
static const wchar_t *kRecursedPostCharSet = L"0-";
namespace NRecursedPostCharIndex {
enum EEnum
@@ -101,10 +102,10 @@ static const NRecursedType::EEnum kCommandRecursedDefault[kNumCommandForms] =
// static const bool kTestExtractRecursedDefault = true;
// static const bool kAddRecursedDefault = false;
static const wchar_t *kUniversalWildcard = L"*";
static const char * const kUniversalWildcard = "*";
static const int kCommandIndex = 0;
static const char *kHelpString =
static const char * const kHelpString =
"\nUsage: 7zSFX [<command>] [<switches>...] [<file_name>...]\n"
"\n"
"<Commands>\n"
@@ -121,16 +122,16 @@ static const char *kHelpString =
// ---------------------------
// exception messages
static const char *kUserErrorMessage = "Incorrect command line"; // NExitCode::kUserError
// static const char *kIncorrectListFile = "Incorrect wildcard in listfile";
static const char *kIncorrectWildcardInCommandLine = "Incorrect wildcard in command line";
static const char * const kUserErrorMessage = "Incorrect command line"; // NExitCode::kUserError
// static const char * const kIncorrectListFile = "Incorrect wildcard in listfile";
static const char * const kIncorrectWildcardInCommandLine = "Incorrect wildcard in command line";
// static const CSysString kFileIsNotArchiveMessageBefore = "File \"";
// static const CSysString kFileIsNotArchiveMessageAfter = "\" is not archive";
// static const char *kProcessArchiveMessage = " archive: ";
// static const char * const kProcessArchiveMessage = " archive: ";
static const char *kCantFindSFX = " cannot find sfx";
static const char * const kCantFindSFX = " cannot find sfx";
namespace NCommandType
{
@@ -280,13 +281,16 @@ int Main2(
#endif
commandStrings.Delete(0);
#ifndef UNDER_CE
if (commandStrings.Size() > 0)
commandStrings.Delete(0);
#endif
NCommandLineParser::CParser parser(kNumSwitches);
NCommandLineParser::CParser parser;
try
{
if (!parser.ParseStrings(kSwitchForms, commandStrings))
if (!parser.ParseStrings(kSwitchForms, kNumSwitches, commandStrings))
{
g_StdOut << "Command line error:" << endl
<< parser.ErrorMessage << endl
@@ -331,7 +335,7 @@ int Main2(
{
if (nonSwitchStrings.Size() == curCommandIndex)
AddCommandLineWildcardToCensor(wildcardCensor, kUniversalWildcard, true, recursedType);
AddCommandLineWildcardToCensor(wildcardCensor, (UString)kUniversalWildcard, true, recursedType);
for (; curCommandIndex < nonSwitchStrings.Size(); curCommandIndex++)
{
const UString &s = nonSwitchStrings[curCommandIndex];

View File

@@ -15,9 +15,9 @@ using namespace NWindows;
using namespace NFile;
using namespace NDir;
static LPCWSTR kCantDeleteFile = L"Can not delete output file";
static LPCWSTR kCantOpenFile = L"Can not open output file";
static LPCWSTR kUnsupportedMethod = L"Unsupported Method";
static LPCSTR const kCantDeleteFile = "Can not delete output file";
static LPCSTR const kCantOpenFile = "Can not open output file";
static LPCSTR const kUnsupportedMethod = "Unsupported Method";
void CExtractCallbackImp::Init(IInArchive *archiveHandler,
const FString &directoryPath,

View File

@@ -18,8 +18,8 @@ using namespace NWindows;
using namespace NFile;
using namespace NDir;
static LPCWSTR kCantFindArchive = L"Can not find archive file";
static LPCWSTR kCantOpenArchive = L"Can not open the file as archive";
static LPCSTR const kCantFindArchive = "Can not find archive file";
static LPCSTR const kCantOpenArchive = "Can not open the file as archive";
struct CThreadExtracting
{
@@ -73,7 +73,7 @@ struct CThreadExtracting
return;
}
ExtractCallbackSpec->Init(ArchiveLink.GetArchive(), dirPath, L"Default", fi.MTime, 0);
ExtractCallbackSpec->Init(ArchiveLink.GetArchive(), dirPath, (UString)"Default", fi.MTime, 0);
Result = ArchiveLink.GetArchive()->Extract(0, (UInt32)(Int32)-1 , BoolToInt(false), ExtractCallback);
}

View File

@@ -33,7 +33,7 @@ using namespace NDir;
HINSTANCE g_hInstance;
static CFSTR kTempDirPrefix = FTEXT("7zS");
static CFSTR const kTempDirPrefix = FTEXT("7zS");
#define _SHELL_EXECUTE
@@ -169,7 +169,7 @@ int APIENTRY WinMain(HINSTANCE hInstance, HINSTANCE /* hPrevInstance */,
return 1;
}
UString dirPrefix = L"." WSTRING_PATH_SEPARATOR;
UString dirPrefix ("." STRING_PATH_SEPARATOR);
UString appLaunched;
bool showProgress = true;
if (!config.IsEmpty())
@@ -181,12 +181,12 @@ int APIENTRY WinMain(HINSTANCE hInstance, HINSTANCE /* hPrevInstance */,
ShowErrorMessage(L"Config failed");
return 1;
}
UString friendlyName = GetTextConfigValue(pairs, L"Title");
UString installPrompt = GetTextConfigValue(pairs, L"BeginPrompt");
UString progress = GetTextConfigValue(pairs, L"Progress");
UString friendlyName = GetTextConfigValue(pairs, "Title");
UString installPrompt = GetTextConfigValue(pairs, "BeginPrompt");
UString progress = GetTextConfigValue(pairs, "Progress");
if (progress.IsEqualTo_Ascii_NoCase("no"))
showProgress = false;
int index = FindTextConfigItem(pairs, L"Directory");
int index = FindTextConfigItem(pairs, "Directory");
if (index >= 0)
dirPrefix = pairs[index].String;
if (!installPrompt.IsEmpty() && !assumeYes)
@@ -195,11 +195,11 @@ int APIENTRY WinMain(HINSTANCE hInstance, HINSTANCE /* hPrevInstance */,
MB_ICONQUESTION) != IDYES)
return 0;
}
appLaunched = GetTextConfigValue(pairs, L"RunProgram");
appLaunched = GetTextConfigValue(pairs, "RunProgram");
#ifdef _SHELL_EXECUTE
executeFile = GetTextConfigValue(pairs, L"ExecuteFile");
executeParameters = GetTextConfigValue(pairs, L"ExecuteParameters");
executeFile = GetTextConfigValue(pairs, "ExecuteFile");
executeParameters = GetTextConfigValue(pairs, "ExecuteParameters");
#endif
}
@@ -260,7 +260,7 @@ int APIENTRY WinMain(HINSTANCE hInstance, HINSTANCE /* hPrevInstance */,
#ifdef _SHELL_EXECUTE
if (!executeFile.IsEmpty())
{
CSysString filePath = GetSystemString(executeFile);
CSysString filePath (GetSystemString(executeFile));
SHELLEXECUTEINFO execInfo;
execInfo.cbSize = sizeof(execInfo);
execInfo.fMask = SEE_MASK_NOCLOSEPROCESS
@@ -278,7 +278,7 @@ int APIENTRY WinMain(HINSTANCE hInstance, HINSTANCE /* hPrevInstance */,
executeParameters += switches;
}
CSysString parametersSys = GetSystemString(executeParameters);
CSysString parametersSys (GetSystemString(executeParameters));
if (parametersSys.IsEmpty())
execInfo.lpParameters = NULL;
else
@@ -337,7 +337,7 @@ int APIENTRY WinMain(HINSTANCE hInstance, HINSTANCE /* hPrevInstance */,
PROCESS_INFORMATION processInformation;
CSysString appLaunchedSys = GetSystemString(dirPrefix + appLaunched);
CSysString appLaunchedSys (GetSystemString(dirPrefix + appLaunched));
BOOL createResult = CreateProcess(NULL, (LPTSTR)(LPCTSTR)appLaunchedSys,
NULL, NULL, FALSE, 0, NULL, NULL /*tempDir.GetPath() */,

View File

@@ -65,7 +65,7 @@ static DWORD GetDllVersion(LPCTSTR dllName)
bool g_LVN_ITEMACTIVATE_Support = true;
static const wchar_t *kUnknownExceptionMessage = L"ERROR: Unknown Error!";
static const wchar_t * const kUnknownExceptionMessage = L"ERROR: Unknown Error!";
void ErrorMessageForHRESULT(HRESULT res)
{