Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/kornelski/7z.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIgor Pavlov <ipavlov@users.sourceforge.net>2015-06-15 03:00:00 +0300
committerKornel LesiƄski <kornel@geekhood.net>2016-05-28 02:16:54 +0300
commit54490d51d5c6b0d794dcbad2d634d4c95fc25b6c (patch)
treec3c413656432c0ef87b2841c80e42b55ad17d4e8 /CPP/7zip/Bundles
parent0713a3ab803e57401f18432148b4139e5fe6e5dd (diff)
15.0515.05
Diffstat (limited to 'CPP/7zip/Bundles')
-rw-r--r--CPP/7zip/Bundles/Alone/Alone.dsp102
-rw-r--r--CPP/7zip/Bundles/Alone/makefile9
-rw-r--r--CPP/7zip/Bundles/Alone7z/Alone.dsp80
-rw-r--r--CPP/7zip/Bundles/Alone7z/makefile5
-rw-r--r--CPP/7zip/Bundles/Fm/FM.dsp342
-rw-r--r--CPP/7zip/Bundles/Fm/makefile2
-rw-r--r--CPP/7zip/Bundles/Format7z/makefile5
-rw-r--r--CPP/7zip/Bundles/Format7zExtract/makefile4
-rw-r--r--CPP/7zip/Bundles/Format7zExtractR/makefile4
-rw-r--r--CPP/7zip/Bundles/Format7zF/Arc.mak10
-rw-r--r--CPP/7zip/Bundles/Format7zF/Format7z.dsp245
-rw-r--r--CPP/7zip/Bundles/Format7zR/makefile5
-rw-r--r--CPP/7zip/Bundles/LzmaCon/LzmaAlone.cpp571
-rw-r--r--CPP/7zip/Bundles/LzmaCon/resource.rc2
-rw-r--r--CPP/7zip/Bundles/SFXCon/SFXCon.dsp66
-rw-r--r--CPP/7zip/Bundles/SFXCon/SfxCon.cpp16
-rw-r--r--CPP/7zip/Bundles/SFXCon/makefile11
-rw-r--r--CPP/7zip/Bundles/SFXCon/resource.rc2
-rw-r--r--CPP/7zip/Bundles/SFXSetup/ExtractCallbackSfx.cpp28
-rw-r--r--CPP/7zip/Bundles/SFXSetup/SFXSetup.dsp58
-rw-r--r--CPP/7zip/Bundles/SFXSetup/SfxSetup.cpp16
-rw-r--r--CPP/7zip/Bundles/SFXSetup/makefile10
-rw-r--r--CPP/7zip/Bundles/SFXSetup/resource.rc2
-rw-r--r--CPP/7zip/Bundles/SFXWin/SFXWin.dsp58
-rw-r--r--CPP/7zip/Bundles/SFXWin/makefile11
-rw-r--r--CPP/7zip/Bundles/SFXWin/resource.rc2
26 files changed, 1168 insertions, 498 deletions
diff --git a/CPP/7zip/Bundles/Alone/Alone.dsp b/CPP/7zip/Bundles/Alone/Alone.dsp
index 40f87879..cd7341c1 100644
--- a/CPP/7zip/Bundles/Alone/Alone.dsp
+++ b/CPP/7zip/Bundles/Alone/Alone.dsp
@@ -350,6 +350,10 @@ SOURCE=..\..\..\Common\NewHandler.h
# End Source File
# Begin Source File
+SOURCE=..\..\..\Common\Sha1Reg.cpp
+# End Source File
+# Begin Source File
+
SOURCE=..\..\..\Common\Sha256Reg.cpp
# End Source File
# Begin Source File
@@ -1214,14 +1218,6 @@ SOURCE=..\..\Compress\BitmEncoder.h
# End Source File
# Begin Source File
-SOURCE=..\..\Compress\BranchCoder.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\Compress\BranchCoder.h
-# End Source File
-# Begin Source File
-
SOURCE=..\..\Compress\BranchMisc.cpp
# End Source File
# Begin Source File
@@ -1517,14 +1513,6 @@ SOURCE=..\..\Archive\Common\CoderMixer2.h
# End Source File
# Begin Source File
-SOURCE=..\..\Archive\Common\CoderMixer2MT.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\Archive\Common\CoderMixer2MT.h
-# End Source File
-# Begin Source File
-
SOURCE=..\..\Archive\Common\DummyOutStream.cpp
# End Source File
# Begin Source File
@@ -1650,6 +1638,10 @@ SOURCE=..\..\Archive\GzHandler.cpp
# End Source File
# Begin Source File
+SOURCE=..\..\Archive\IArchive.h
+# End Source File
+# Begin Source File
+
SOURCE=..\..\Archive\LzmaHandler.cpp
# End Source File
# Begin Source File
@@ -1944,32 +1936,6 @@ SOURCE=..\..\Crypto\RandGen.h
# End Source File
# Begin Source File
-SOURCE=..\..\Crypto\Sha1.cpp
-
-!IF "$(CFG)" == "Alone - Win32 Release"
-
-# ADD CPP /O2
-# SUBTRACT CPP /YX /Yc /Yu
-
-!ELSEIF "$(CFG)" == "Alone - Win32 Debug"
-
-!ELSEIF "$(CFG)" == "Alone - Win32 ReleaseU"
-
-!ELSEIF "$(CFG)" == "Alone - Win32 DebugU"
-
-!ENDIF
-
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\Crypto\Sha1.h
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\Crypto\Sha1Reg.cpp
-# End Source File
-# Begin Source File
-
SOURCE=..\..\Crypto\WzAes.cpp
# End Source File
# Begin Source File
@@ -2385,6 +2351,30 @@ SOURCE=..\..\..\..\C\Bcj2.h
# End Source File
# Begin Source File
+SOURCE=..\..\..\..\C\Bcj2Enc.c
+
+!IF "$(CFG)" == "Alone - Win32 Release"
+
+# ADD CPP /O2
+# SUBTRACT CPP /YX /Yc /Yu
+
+!ELSEIF "$(CFG)" == "Alone - Win32 Debug"
+
+# SUBTRACT CPP /YX /Yc /Yu
+
+!ELSEIF "$(CFG)" == "Alone - Win32 ReleaseU"
+
+# SUBTRACT CPP /YX /Yc /Yu
+
+!ELSEIF "$(CFG)" == "Alone - Win32 DebugU"
+
+# SUBTRACT CPP /YX /Yc /Yu
+
+!ENDIF
+
+# End Source File
+# Begin Source File
+
SOURCE=..\..\..\..\C\Bra.c
!IF "$(CFG)" == "Alone - Win32 Release"
@@ -2918,6 +2908,34 @@ SOURCE=..\..\..\..\C\RotateDefs.h
# End Source File
# Begin Source File
+SOURCE=..\..\..\..\C\Sha1.c
+
+!IF "$(CFG)" == "Alone - Win32 Release"
+
+# ADD CPP /O2
+# SUBTRACT CPP /YX /Yc /Yu
+
+!ELSEIF "$(CFG)" == "Alone - Win32 Debug"
+
+# SUBTRACT CPP /YX /Yc /Yu
+
+!ELSEIF "$(CFG)" == "Alone - Win32 ReleaseU"
+
+# SUBTRACT CPP /YX /Yc /Yu
+
+!ELSEIF "$(CFG)" == "Alone - Win32 DebugU"
+
+# SUBTRACT CPP /YX /Yc /Yu
+
+!ENDIF
+
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\C\Sha1.h
+# End Source File
+# Begin Source File
+
SOURCE=..\..\..\..\C\Sha256.c
!IF "$(CFG)" == "Alone - Win32 Release"
diff --git a/CPP/7zip/Bundles/Alone/makefile b/CPP/7zip/Bundles/Alone/makefile
index 15139714..02a51398 100644
--- a/CPP/7zip/Bundles/Alone/makefile
+++ b/CPP/7zip/Bundles/Alone/makefile
@@ -23,6 +23,7 @@ COMMON_OBJS = \
$O\MyVector.obj \
$O\Wildcard.obj \
$O\XzCrc64Reg.obj \
+ $O\Sha1Reg.obj \
$O\Sha256Reg.obj \
WIN_OBJS = \
@@ -50,7 +51,6 @@ WIN_OBJS = \
$O\InBuffer.obj \
$O\InOutTempBuffer.obj \
$O\LimitedStreams.obj \
- $O\LockedStream.obj \
$O\MemBlocks.obj \
$O\MethodId.obj \
$O\MethodProps.obj \
@@ -77,7 +77,6 @@ AR_OBJS = \
AR_COMMON_OBJS = \
$O\CoderMixer2.obj \
- $O\CoderMixer2MT.obj \
$O\CrossThreadProgress.obj \
$O\DummyOutStream.obj \
$O\FindSignature.obj \
@@ -139,7 +138,6 @@ COMPRESS_OBJS = \
$O\BcjCoder.obj \
$O\BcjRegister.obj \
$O\BitlDecoder.obj \
- $O\BranchCoder.obj \
$O\BranchMisc.obj \
$O\BranchRegister.obj \
$O\ByteSwap.obj \
@@ -181,8 +179,6 @@ CRYPTO_OBJS = \
$O\MyAesReg.obj \
$O\Pbkdf2HmacSha1.obj \
$O\RandGen.obj \
- $O\Sha1.obj \
- $O\Sha1Reg.obj \
$O\WzAes.obj \
$O\ZipCrypto.obj \
$O\ZipStrong.obj \
@@ -190,6 +186,8 @@ CRYPTO_OBJS = \
C_OBJS = \
$O\7zStream.obj \
$O\Alloc.obj \
+ $O\Bcj2.obj \
+ $O\Bcj2Enc.obj \
$O\Bra.obj \
$O\Bra86.obj \
$O\BraIA64.obj \
@@ -210,6 +208,7 @@ C_OBJS = \
$O\Ppmd8.obj \
$O\Ppmd8Dec.obj \
$O\Ppmd8Enc.obj \
+ $O\Sha1.obj \
$O\Sha256.obj \
$O\Sort.obj \
$O\Threads.obj \
diff --git a/CPP/7zip/Bundles/Alone7z/Alone.dsp b/CPP/7zip/Bundles/Alone7z/Alone.dsp
index 2800ff88..089e4020 100644
--- a/CPP/7zip/Bundles/Alone7z/Alone.dsp
+++ b/CPP/7zip/Bundles/Alone7z/Alone.dsp
@@ -44,7 +44,7 @@ RSC=rc.exe
# PROP Ignore_Export_Lib 0
# PROP Target_Dir ""
# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
-# ADD CPP /nologo /Gz /MT /W3 /GX /O1 /I "..\..\..\\" /D "NDEBUG" /D "_MBCS" /D "WIN32" /D "_CONSOLE" /Yu"StdAfx.h" /FD /c
+# ADD CPP /nologo /Gr /MT /W3 /GX /O1 /I "..\..\..\\" /D "NDEBUG" /D "_MBCS" /D "WIN32" /D "_CONSOLE" /FAc /Yu"StdAfx.h" /FD /c
# ADD BASE RSC /l 0x419 /d "NDEBUG"
# ADD RSC /l 0x419 /d "NDEBUG"
BSC32=bscmake.exe
@@ -69,7 +69,7 @@ LINK32=link.exe
# PROP Ignore_Export_Lib 0
# PROP Target_Dir ""
# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /GZ /c
-# ADD CPP /nologo /Gz /MDd /W3 /Gm /GX /ZI /Od /I "..\..\..\\" /D "_DEBUG" /D "_MBCS" /D "WIN32" /D "_CONSOLE" /Yu"StdAfx.h" /FD /GZ /c
+# ADD CPP /nologo /Gr /MDd /W3 /Gm /GX /ZI /Od /I "..\..\..\\" /D "_DEBUG" /D "_MBCS" /D "WIN32" /D "_CONSOLE" /Yu"StdAfx.h" /FD /GZ /c
# ADD BASE RSC /l 0x419 /d "_DEBUG"
# ADD RSC /l 0x419 /d "_DEBUG"
BSC32=bscmake.exe
@@ -94,7 +94,7 @@ LINK32=link.exe
# PROP Ignore_Export_Lib 0
# PROP Target_Dir ""
# ADD BASE CPP /nologo /MD /W3 /GX /O2 /D "NDEBUG" /D "WIN32" /D "_CONSOLE" /D "EXCLUDE_COM" /D "NO_REGISTRY" /Yu"StdAfx.h" /FD /c
-# ADD CPP /nologo /Gz /MD /W4 /GX /O1 /I "..\..\..\\" /D "NDEBUG" /D "UNICODE" /D "_UNICODE" /D "WIN32" /D "_CONSOLE" /Yu"StdAfx.h" /FD /c
+# ADD CPP /nologo /Gr /MD /W4 /GX /O1 /I "..\..\..\\" /D "NDEBUG" /D "UNICODE" /D "_UNICODE" /D "WIN32" /D "_CONSOLE" /Yu"StdAfx.h" /FD /c
# ADD BASE RSC /l 0x419 /d "NDEBUG"
# ADD RSC /l 0x419 /d "NDEBUG"
BSC32=bscmake.exe
@@ -121,7 +121,7 @@ LINK32=link.exe
# PROP Ignore_Export_Lib 0
# PROP Target_Dir ""
# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "_DEBUG" /D "WIN32" /D "_CONSOLE" /D "EXCLUDE_COM" /D "NO_REGISTRY" /D "_MBCS" /Yu"StdAfx.h" /FD /GZ /c
-# ADD CPP /nologo /Gz /MDd /W4 /Gm /GX /ZI /Od /I "..\..\..\\" /D "_DEBUG" /D "_UNICODE" /D "UNICODE" /D "WIN32" /D "_CONSOLE" /Yu"StdAfx.h" /FD /GZ /c
+# ADD CPP /nologo /Gr /MDd /W4 /Gm /GX /ZI /Od /I "..\..\..\\" /D "_DEBUG" /D "_UNICODE" /D "UNICODE" /D "WIN32" /D "_CONSOLE" /Yu"StdAfx.h" /FD /GZ /c
# ADD BASE RSC /l 0x419 /d "_DEBUG"
# ADD RSC /l 0x419 /d "_DEBUG"
BSC32=bscmake.exe
@@ -738,14 +738,6 @@ SOURCE=..\..\Compress\BcjRegister.cpp
# End Source File
# Begin Source File
-SOURCE=..\..\Compress\BranchCoder.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\Compress\BranchCoder.h
-# End Source File
-# Begin Source File
-
SOURCE=..\..\Compress\BranchMisc.cpp
# End Source File
# Begin Source File
@@ -961,14 +953,6 @@ SOURCE=..\..\Archive\Common\CoderMixer2.h
# End Source File
# Begin Source File
-SOURCE=..\..\Archive\Common\CoderMixer2MT.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\Archive\Common\CoderMixer2MT.h
-# End Source File
-# Begin Source File
-
SOURCE=..\..\Archive\Common\DummyOutStream.cpp
# End Source File
# Begin Source File
@@ -1026,6 +1010,10 @@ SOURCE=..\..\Archive\Common\ParseProperties.h
# End Group
# Begin Source File
+SOURCE=..\..\Archive\IArchive.h
+# End Source File
+# Begin Source File
+
SOURCE=..\..\Archive\LzmaHandler.cpp
# End Source File
# Begin Source File
@@ -1526,6 +1514,58 @@ SOURCE=..\..\..\..\C\Alloc.h
# End Source File
# Begin Source File
+SOURCE=..\..\..\..\C\Bcj2.c
+
+!IF "$(CFG)" == "Alone - Win32 Release"
+
+# ADD CPP /O2
+# SUBTRACT CPP /YX /Yc /Yu
+
+!ELSEIF "$(CFG)" == "Alone - Win32 Debug"
+
+# SUBTRACT CPP /YX /Yc /Yu
+
+!ELSEIF "$(CFG)" == "Alone - Win32 ReleaseU"
+
+# SUBTRACT CPP /YX /Yc /Yu
+
+!ELSEIF "$(CFG)" == "Alone - Win32 DebugU"
+
+# SUBTRACT CPP /YX /Yc /Yu
+
+!ENDIF
+
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\C\Bcj2.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\C\Bcj2Enc.c
+
+!IF "$(CFG)" == "Alone - Win32 Release"
+
+# ADD CPP /O2
+# SUBTRACT CPP /YX /Yc /Yu
+
+!ELSEIF "$(CFG)" == "Alone - Win32 Debug"
+
+# SUBTRACT CPP /YX /Yc /Yu
+
+!ELSEIF "$(CFG)" == "Alone - Win32 ReleaseU"
+
+# SUBTRACT CPP /YX /Yc /Yu
+
+!ELSEIF "$(CFG)" == "Alone - Win32 DebugU"
+
+# SUBTRACT CPP /YX /Yc /Yu
+
+!ENDIF
+
+# End Source File
+# Begin Source File
+
SOURCE=..\..\..\..\C\Bra.c
# SUBTRACT CPP /YX /Yc /Yu
# End Source File
diff --git a/CPP/7zip/Bundles/Alone7z/makefile b/CPP/7zip/Bundles/Alone7z/makefile
index 84b235eb..7589bc30 100644
--- a/CPP/7zip/Bundles/Alone7z/makefile
+++ b/CPP/7zip/Bundles/Alone7z/makefile
@@ -48,7 +48,6 @@ WIN_OBJS = \
$O\InOutTempBuffer.obj \
$O\FilterCoder.obj \
$O\LimitedStreams.obj \
- $O\LockedStream.obj \
$O\MethodId.obj \
$O\MethodProps.obj \
$O\OffsetStream.obj \
@@ -68,7 +67,6 @@ AR_OBJS = \
AR_COMMON_OBJS = \
$O\CoderMixer2.obj \
- $O\CoderMixer2MT.obj \
$O\CrossThreadProgress.obj \
$O\DummyOutStream.obj \
$O\HandlerOut.obj \
@@ -101,7 +99,6 @@ COMPRESS_OBJS = \
$O\Bcj2Register.obj \
$O\BcjCoder.obj \
$O\BcjRegister.obj \
- $O\BranchCoder.obj \
$O\BranchMisc.obj \
$O\BranchRegister.obj \
$O\ByteSwap.obj \
@@ -125,6 +122,8 @@ CRYPTO_OBJS = \
C_OBJS = \
$O\7zStream.obj \
$O\Alloc.obj \
+ $O\Bcj2.obj \
+ $O\Bcj2Enc.obj \
$O\Bra.obj \
$O\Bra86.obj \
$O\BraIA64.obj \
diff --git a/CPP/7zip/Bundles/Fm/FM.dsp b/CPP/7zip/Bundles/Fm/FM.dsp
index 1f214b33..dfb0bb47 100644
--- a/CPP/7zip/Bundles/Fm/FM.dsp
+++ b/CPP/7zip/Bundles/Fm/FM.dsp
@@ -45,7 +45,7 @@ RSC=rc.exe
# PROP Ignore_Export_Lib 0
# PROP Target_Dir ""
# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /YX /FD /c
-# ADD CPP /nologo /Gz /MD /W4 /WX /GX /O1 /D "NDEBUG" /D "_MBCS" /D "WIN32" /D "_WINDOWS" /D "LANG" /D "WIN_LONG_PATH" /D "NEW_FOLDER_INTERFACE" /D "EXTERNAL_CODECS" /D "SUPPORT_DEVICE_FILE" /Yu"StdAfx.h" /FD /c
+# ADD CPP /nologo /Gz /MD /W4 /WX /GX /O1 /D "NDEBUG" /D "_MBCS" /D "WIN32" /D "_WINDOWS" /D "LANG" /D "WIN_LONG_PATH" /D "NEW_FOLDER_INTERFACE" /D "EXTERNAL_CODECS_2" /D "SUPPORT_DEVICE_FILE" /Yu"StdAfx.h" /FD /c
# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
# ADD BASE RSC /l 0x419 /d "NDEBUG"
@@ -72,7 +72,7 @@ LINK32=link.exe
# PROP Ignore_Export_Lib 0
# PROP Target_Dir ""
# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /YX /FD /GZ /c
-# ADD CPP /nologo /Gz /MDd /W4 /WX /Gm /GX /ZI /Od /D "_DEBUG" /D "_MBCS" /D "WIN32" /D "_WINDOWS" /D "LANG" /D "WIN_LONG_PATH" /D "NEW_FOLDER_INTERFACE" /D "EXTERNAL_CODECS" /D "SUPPORT_DEVICE_FILE" /Yu"StdAfx.h" /FD /GZ /c
+# ADD CPP /nologo /Gz /MDd /W4 /WX /Gm /GX /ZI /Od /D "_DEBUG" /D "_MBCS" /D "WIN32" /D "_WINDOWS" /D "LANG" /D "WIN_LONG_PATH" /D "NEW_FOLDER_INTERFACE" /D "EXTERNAL_CODECS_2" /D "SUPPORT_DEVICE_FILE" /Yu"StdAfx.h" /FD /GZ /c
# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32
# ADD BASE RSC /l 0x419 /d "_DEBUG"
@@ -99,7 +99,7 @@ LINK32=link.exe
# PROP Ignore_Export_Lib 0
# PROP Target_Dir ""
# ADD BASE CPP /nologo /MD /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /Yu"StdAfx.h" /FD /c
-# ADD CPP /nologo /Gz /MD /W4 /WX /GX /O1 /D "NDEBUG" /D "WIN32" /D "_WINDOWS" /D "LANG" /D "WIN_LONG_PATH" /D "NEW_FOLDER_INTERFACE" /D "EXTERNAL_CODECS" /D "SUPPORT_DEVICE_FILE" /Yu"StdAfx.h" /FD /c
+# ADD CPP /nologo /Gz /MD /W4 /WX /GX /O1 /D "NDEBUG" /D "WIN32" /D "_WINDOWS" /D "LANG" /D "WIN_LONG_PATH" /D "NEW_FOLDER_INTERFACE" /D "EXTERNAL_CODECS_2" /D "SUPPORT_DEVICE_FILE" /Yu"StdAfx.h" /FD /c
# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
# ADD BASE RSC /l 0x419 /d "NDEBUG"
@@ -127,7 +127,7 @@ LINK32=link.exe
# PROP Ignore_Export_Lib 0
# PROP Target_Dir ""
# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /Yu"StdAfx.h" /FD /GZ /c
-# ADD CPP /nologo /Gz /MDd /W4 /WX /Gm /GX /ZI /Od /D "_DEBUG" /D "WIN32" /D "_WINDOWS" /D "LANG" /D "WIN_LONG_PATH" /D "NEW_FOLDER_INTERFACE" /D "EXTERNAL_CODECS" /D "SUPPORT_DEVICE_FILE" /Yu"StdAfx.h" /FD /GZ /c
+# ADD CPP /nologo /Gz /MDd /W4 /WX /Gm /GX /ZI /Od /D "_DEBUG" /D "WIN32" /D "_WINDOWS" /D "LANG" /D "WIN_LONG_PATH" /D "NEW_FOLDER_INTERFACE" /D "EXTERNAL_CODECS_2" /D "SUPPORT_DEVICE_FILE" /Yu"StdAfx.h" /FD /GZ /c
# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32
# ADD BASE RSC /l 0x419 /d "_DEBUG"
@@ -211,9 +211,188 @@ SOURCE=..\..\UI\FileManager\Test.bmp
# Begin Group "Archive"
# PROP Default_Filter ""
+# Begin Group "7z"
+
+# PROP Default_Filter ""
# Begin Source File
-SOURCE=..\..\Archive\IArchive.h
+SOURCE=..\..\Archive\7z\7zCompressionMode.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Archive\7z\7zCompressionMode.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Archive\7z\7zDecode.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Archive\7z\7zDecode.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Archive\7z\7zEncode.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Archive\7z\7zEncode.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Archive\7z\7zExtract.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Archive\7z\7zFolderInStream.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Archive\7z\7zFolderInStream.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Archive\7z\7zFolderOutStream.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Archive\7z\7zFolderOutStream.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Archive\7z\7zHandler.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Archive\7z\7zHandler.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Archive\7z\7zHandlerOut.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Archive\7z\7zHeader.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Archive\7z\7zHeader.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Archive\7z\7zIn.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Archive\7z\7zIn.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Archive\7z\7zItem.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Archive\7z\7zOut.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Archive\7z\7zOut.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Archive\7z\7zProperties.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Archive\7z\7zProperties.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Archive\7z\7zRegister.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Archive\7z\7zSpecStream.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Archive\7z\7zSpecStream.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Archive\7z\7zUpdate.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Archive\7z\7zUpdate.h
+# End Source File
+# End Group
+# Begin Group "Archive Common"
+
+# PROP Default_Filter ""
+# Begin Source File
+
+SOURCE=..\..\Archive\Common\CoderMixer.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Archive\Common\CoderMixer.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Archive\Common\CoderMixer2.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Archive\Common\CoderMixer2.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Archive\Common\DummyOutStream.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Archive\Common\DummyOutStream.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Archive\Common\FindSignature.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Archive\Common\FindSignature.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Archive\Common\HandlerOut.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Archive\Common\HandlerOut.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Archive\Common\InStreamWithCRC.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Archive\Common\InStreamWithCRC.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Archive\Common\ItemNameUtils.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Archive\Common\ItemNameUtils.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Archive\Common\MultiStream.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Archive\Common\MultiStream.h
# End Source File
# Begin Source File
@@ -223,12 +402,33 @@ SOURCE=..\..\Archive\Common\OutStreamWithCRC.cpp
SOURCE=..\..\Archive\Common\OutStreamWithCRC.h
# End Source File
+# Begin Source File
+
+SOURCE=..\..\Archive\Common\ParseProperties.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Archive\Common\ParseProperties.h
+# End Source File
+# End Group
+# Begin Source File
+
+SOURCE=..\..\Archive\IArchive.h
+# End Source File
# End Group
# Begin Group "Folders"
# PROP Default_Filter ""
# Begin Source File
+SOURCE=..\..\UI\FileManager\AltStreamsFolder.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\UI\FileManager\AltStreamsFolder.h
+# End Source File
+# Begin Source File
+
SOURCE=..\..\UI\FileManager\FSDrives.cpp
# End Source File
# Begin Source File
@@ -605,6 +805,22 @@ SOURCE=..\..\UI\FileManager\UpdateCallback100.h
# PROP Default_Filter ""
# Begin Source File
+SOURCE=..\..\Common\CreateCoder.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Common\CreateCoder.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Common\CWrappers.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Common\CWrappers.h
+# End Source File
+# Begin Source File
+
SOURCE=..\..\Common\FilePathAutoRename.cpp
# End Source File
# Begin Source File
@@ -621,6 +837,14 @@ SOURCE=..\..\Common\FileStreams.h
# End Source File
# Begin Source File
+SOURCE=..\..\Common\InOutTempBuffer.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Common\InOutTempBuffer.h
+# End Source File
+# Begin Source File
+
SOURCE=..\..\Common\MethodProps.cpp
# End Source File
# Begin Source File
@@ -629,6 +853,14 @@ SOURCE=..\..\Common\MethodProps.h
# End Source File
# Begin Source File
+SOURCE=..\..\Common\OutBuffer.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Common\OutBuffer.h
+# End Source File
+# Begin Source File
+
SOURCE=..\..\Common\ProgressUtils.cpp
# End Source File
# Begin Source File
@@ -641,6 +873,14 @@ SOURCE=..\..\Common\PropId.cpp
# End Source File
# Begin Source File
+SOURCE=..\..\Common\StreamBinder.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Common\StreamBinder.h
+# End Source File
+# Begin Source File
+
SOURCE=..\..\Common\StreamObjects.cpp
# End Source File
# Begin Source File
@@ -663,6 +903,14 @@ SOURCE=..\..\Common\UniqBlocks.cpp
SOURCE=..\..\Common\UniqBlocks.h
# End Source File
+# Begin Source File
+
+SOURCE=..\..\Common\VirtThread.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Common\VirtThread.h
+# End Source File
# End Group
# Begin Group "C"
@@ -745,6 +993,42 @@ SOURCE=..\..\..\..\C\CpuArch.h
# End Source File
# Begin Source File
+SOURCE=..\..\..\..\C\LzFind.c
+# SUBTRACT CPP /YX /Yc /Yu
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\C\LzFind.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\C\LzFindMt.c
+# SUBTRACT CPP /YX /Yc /Yu
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\C\LzFindMt.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\C\LzmaDec.c
+# SUBTRACT CPP /YX /Yc /Yu
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\C\LzmaDec.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\C\LzmaEnc.c
+# SUBTRACT CPP /YX /Yc /Yu
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\C\LzmaEnc.h
+# End Source File
+# Begin Source File
+
SOURCE=..\..\..\..\C\Sha256.c
!IF "$(CFG)" == "FM - Win32 Release"
@@ -1302,14 +1586,6 @@ SOURCE=..\..\UI\Common\CompressCall2.cpp
# End Source File
# Begin Source File
-SOURCE=..\..\Common\CreateCoder.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\Common\CreateCoder.h
-# End Source File
-# Begin Source File
-
SOURCE=..\..\UI\Common\DefaultName.cpp
# End Source File
# Begin Source File
@@ -1618,6 +1894,14 @@ SOURCE=..\..\UI\GUI\UpdateCallbackGUI.h
# End Source File
# Begin Source File
+SOURCE=..\..\UI\GUI\UpdateCallbackGUI2.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\UI\GUI\UpdateCallbackGUI2.h
+# End Source File
+# Begin Source File
+
SOURCE=..\..\UI\GUI\UpdateGUI.cpp
# End Source File
# Begin Source File
@@ -1637,37 +1921,49 @@ SOURCE=..\..\Compress\CopyCoder.cpp
SOURCE=..\..\Compress\CopyCoder.h
# End Source File
-# End Group
-# Begin Group "Interface"
+# Begin Source File
-# PROP Default_Filter ""
+SOURCE=..\..\Compress\CopyRegister.cpp
+# End Source File
# Begin Source File
-SOURCE=..\..\ICoder.h
+SOURCE=..\..\Compress\LzmaDecoder.cpp
# End Source File
# Begin Source File
-SOURCE=..\..\IDecl.h
+SOURCE=..\..\Compress\LzmaDecoder.h
# End Source File
# Begin Source File
-SOURCE=..\..\IPassword.h
+SOURCE=..\..\Compress\LzmaEncoder.cpp
# End Source File
# Begin Source File
-SOURCE=..\..\IProgress.h
+SOURCE=..\..\Compress\LzmaEncoder.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Compress\LzmaRegister.cpp
# End Source File
# End Group
-# Begin Group "Crypto"
+# Begin Group "Interface"
# PROP Default_Filter ""
# Begin Source File
-SOURCE=..\..\Crypto\Sha1.cpp
+SOURCE=..\..\ICoder.h
# End Source File
# Begin Source File
-SOURCE=..\..\Crypto\Sha1.h
+SOURCE=..\..\IDecl.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\IPassword.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\IProgress.h
# End Source File
# End Group
# Begin Source File
diff --git a/CPP/7zip/Bundles/Fm/makefile b/CPP/7zip/Bundles/Fm/makefile
index fd211a1d..8ae5f4f6 100644
--- a/CPP/7zip/Bundles/Fm/makefile
+++ b/CPP/7zip/Bundles/Fm/makefile
@@ -2,7 +2,6 @@ PROG = 7zFM.exe
CFLAGS = $(CFLAGS) \
-DLANG \
-DNEW_FOLDER_INTERFACE \
- -DEXTERNAL_CODECS \
!IFDEF UNDER_CE
LIBS = $(LIBS) ceshell.lib Commctrl.lib
@@ -86,6 +85,7 @@ GUI_OBJS = \
$O\ExtractGUI.obj \
$O\HashGUI.obj \
$O\UpdateCallbackGUI.obj \
+ $O\UpdateCallbackGUI2.obj \
$O\UpdateGUI.obj \
diff --git a/CPP/7zip/Bundles/Format7z/makefile b/CPP/7zip/Bundles/Format7z/makefile
index 01e63e67..992fc714 100644
--- a/CPP/7zip/Bundles/Format7z/makefile
+++ b/CPP/7zip/Bundles/Format7z/makefile
@@ -32,7 +32,6 @@ WIN_OBJS = \
$O\InOutTempBuffer.obj \
$O\FilterCoder.obj \
$O\LimitedStreams.obj \
- $O\LockedStream.obj \
$O\MethodId.obj \
$O\MethodProps.obj \
$O\OutBuffer.obj \
@@ -50,7 +49,6 @@ AR_OBJS = \
AR_COMMON_OBJS = \
$O\CoderMixer2.obj \
- $O\CoderMixer2MT.obj \
$O\CrossThreadProgress.obj \
$O\HandlerOut.obj \
$O\InStreamWithCRC.obj \
@@ -84,7 +82,6 @@ COMPRESS_OBJS = \
$O\BcjCoder.obj \
$O\BcjRegister.obj \
$O\BitlDecoder.obj \
- $O\BranchCoder.obj \
$O\BranchMisc.obj \
$O\BranchRegister.obj \
$O\ByteSwap.obj \
@@ -116,6 +113,8 @@ CRYPTO_OBJS = \
C_OBJS = \
$O\Alloc.obj \
+ $O\Bcj2.obj \
+ $O\Bcj2Enc.obj \
$O\Bra.obj \
$O\Bra86.obj \
$O\BraIA64.obj \
diff --git a/CPP/7zip/Bundles/Format7zExtract/makefile b/CPP/7zip/Bundles/Format7zExtract/makefile
index 86a76e3d..93240c80 100644
--- a/CPP/7zip/Bundles/Format7zExtract/makefile
+++ b/CPP/7zip/Bundles/Format7zExtract/makefile
@@ -26,7 +26,6 @@ WIN_OBJS = \
$O\InBuffer.obj \
$O\FilterCoder.obj \
$O\LimitedStreams.obj \
- $O\LockedStream.obj \
$O\MethodId.obj \
$O\MethodProps.obj \
$O\OutBuffer.obj \
@@ -43,7 +42,6 @@ AR_OBJS = \
AR_COMMON_OBJS = \
$O\CoderMixer2.obj \
- $O\CoderMixer2MT.obj \
$O\CrossThreadProgress.obj \
$O\ItemNameUtils.obj \
$O\OutStreamWithCRC.obj \
@@ -68,7 +66,6 @@ COMPRESS_OBJS = \
$O\BcjCoder.obj \
$O\BcjRegister.obj \
$O\BitlDecoder.obj \
- $O\BranchCoder.obj \
$O\BranchMisc.obj \
$O\BranchRegister.obj \
$O\ByteSwap.obj \
@@ -96,6 +93,7 @@ CRYPTO_OBJS = \
C_OBJS = \
$O\Alloc.obj \
+ $O\Bcj2.obj \
$O\Bra.obj \
$O\Bra86.obj \
$O\BraIA64.obj \
diff --git a/CPP/7zip/Bundles/Format7zExtractR/makefile b/CPP/7zip/Bundles/Format7zExtractR/makefile
index 7241b37c..3d49c46f 100644
--- a/CPP/7zip/Bundles/Format7zExtractR/makefile
+++ b/CPP/7zip/Bundles/Format7zExtractR/makefile
@@ -26,7 +26,6 @@ WIN_OBJS = \
$O\InBuffer.obj \
$O\FilterCoder.obj \
$O\LimitedStreams.obj \
- $O\LockedStream.obj \
$O\MethodId.obj \
$O\MethodProps.obj \
$O\OutBuffer.obj \
@@ -43,7 +42,6 @@ AR_OBJS = \
AR_COMMON_OBJS = \
$O\CoderMixer2.obj \
- $O\CoderMixer2MT.obj \
$O\CrossThreadProgress.obj \
$O\HandlerOut.obj \
$O\ItemNameUtils.obj \
@@ -69,7 +67,6 @@ COMPRESS_OBJS = \
$O\Bcj2Register.obj \
$O\BcjCoder.obj \
$O\BcjRegister.obj \
- $O\BranchCoder.obj \
$O\BranchMisc.obj \
$O\BranchRegister.obj \
$O\ByteSwap.obj \
@@ -83,6 +80,7 @@ COMPRESS_OBJS = \
C_OBJS = \
$O\Alloc.obj \
+ $O\Bcj2.obj \
$O\Bra.obj \
$O\Bra86.obj \
$O\BraIA64.obj \
diff --git a/CPP/7zip/Bundles/Format7zF/Arc.mak b/CPP/7zip/Bundles/Format7zF/Arc.mak
index c26a6d67..c2f415cf 100644
--- a/CPP/7zip/Bundles/Format7zF/Arc.mak
+++ b/CPP/7zip/Bundles/Format7zF/Arc.mak
@@ -8,6 +8,7 @@ COMMON_OBJS = \
$O\MyVector.obj \
$O\MyXml.obj \
$O\NewHandler.obj \
+ $O\Sha1Reg.obj \
$O\Sha256Reg.obj \
$O\StringConvert.obj \
$O\StringToInt.obj \
@@ -86,7 +87,6 @@ AR_OBJS = \
AR_COMMON_OBJS = \
$O\CoderMixer2.obj \
- $O\CoderMixer2MT.obj \
$O\CrossThreadProgress.obj \
$O\DummyOutStream.obj \
$O\FindSignature.obj \
@@ -172,14 +172,11 @@ ZIP_OBJS = \
$O\ZipRegister.obj \
COMPRESS_OBJS = \
- $O\ArjDecoder1.obj \
- $O\ArjDecoder2.obj \
$O\Bcj2Coder.obj \
$O\Bcj2Register.obj \
$O\BcjCoder.obj \
$O\BcjRegister.obj \
$O\BitlDecoder.obj \
- $O\BranchCoder.obj \
$O\BranchMisc.obj \
$O\BranchRegister.obj \
$O\ByteSwap.obj \
@@ -231,8 +228,6 @@ CRYPTO_OBJS = \
$O\RandGen.obj \
$O\Rar20Crypto.obj \
$O\RarAes.obj \
- $O\Sha1.obj \
- $O\Sha1Reg.obj \
$O\WzAes.obj \
$O\ZipCrypto.obj \
$O\ZipStrong.obj \
@@ -242,6 +237,8 @@ C_OBJS = \
$O\7zBuf2.obj \
$O\7zStream.obj \
$O\Alloc.obj \
+ $O\Bcj2.obj \
+ $O\Bcj2Enc.obj \
$O\Bra.obj \
$O\Bra86.obj \
$O\BraIA64.obj \
@@ -262,6 +259,7 @@ C_OBJS = \
$O\Ppmd8.obj \
$O\Ppmd8Dec.obj \
$O\Ppmd8Enc.obj \
+ $O\Sha1.obj \
$O\Sha256.obj \
$O\Sort.obj \
$O\Threads.obj \
diff --git a/CPP/7zip/Bundles/Format7zF/Format7z.dsp b/CPP/7zip/Bundles/Format7zF/Format7z.dsp
index 40f45455..82df284c 100644
--- a/CPP/7zip/Bundles/Format7zF/Format7z.dsp
+++ b/CPP/7zip/Bundles/Format7zF/Format7z.dsp
@@ -43,7 +43,7 @@ RSC=rc.exe
# PROP Ignore_Export_Lib 1
# PROP Target_Dir ""
# ADD BASE CPP /nologo /MT /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "MY7Z_EXPORTS" /YX /FD /c
-# ADD CPP /nologo /Gr /MT /W4 /WX /GX /O1 /D "NDEBUG" /D "WIN32" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "MY7Z_EXPORTS" /D "NO_REGISTRY" /D "EXTERNAL_CODECS" /D "_7ZIP_LARGE_PAGES" /FAs /Yu"StdAfx.h" /FD /c
+# ADD CPP /nologo /Gr /MT /W4 /WX /GX /O1 /D "NDEBUG" /D "WIN32" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "MY7Z_EXPORTS" /D "NO_REGISTRY" /D "EXTERNAL_CODECS" /D "_7ZIP_LARGE_PAGES" /D "_7ZIP_ST_9" /FAcs /Yu"StdAfx.h" /FD /GF /c
# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
# ADD BASE RSC /l 0x419 /d "NDEBUG"
@@ -70,7 +70,7 @@ LINK32=link.exe
# PROP Ignore_Export_Lib 1
# PROP Target_Dir ""
# ADD BASE CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "MY7Z_EXPORTS" /YX /FD /GZ /c
-# ADD CPP /nologo /Gr /MTd /W4 /WX /Gm /GX /ZI /Od /I "..\..\..\..\SDK" /D "_DEBUG" /D "WIN32" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "MY7Z_EXPORTS" /D "NO_REGISTRY" /D "EXTERNAL_CODECS" /D "_7ZIP_LARGE_PAGES" /Yu"StdAfx.h" /FD /GZ /c
+# ADD CPP /nologo /Gr /MTd /W4 /WX /Gm /GX /ZI /Od /I "..\..\..\..\SDK" /D "_DEBUG" /D "WIN32" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "MY7Z_EXPORTS" /D "NO_REGISTRY" /D "EXTERNAL_CODECS" /D "_7ZIP_LARGE_PAGES" /D "_7ZIP_ST_9" /Yu"StdAfx.h" /FD /GZ /c
# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32
# ADD BASE RSC /l 0x419 /d "_DEBUG"
@@ -80,7 +80,8 @@ BSC32=bscmake.exe
# ADD BSC32 /nologo
LINK32=link.exe
# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /pdbtype:sept
-# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /out:"C:\Program Files\7-Zip\7z.dll" /pdbtype:sept
+# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /out:"C:\Program Files\7-Zip\7z.dll" /pdbtype:sept /ignore:4033
+# SUBTRACT LINK32 /pdb:none
!ENDIF
@@ -334,6 +335,10 @@ SOURCE=..\..\..\Common\NewHandler.h
# End Source File
# Begin Source File
+SOURCE=..\..\..\Common\Sha1Reg.cpp
+# End Source File
+# Begin Source File
+
SOURCE=..\..\..\Common\Sha256Reg.cpp
# End Source File
# Begin Source File
@@ -376,58 +381,6 @@ SOURCE=..\..\..\Common\XzCrc64Reg.cpp
# Begin Group "Compress"
# PROP Default_Filter ""
-# Begin Group "PPMD"
-
-# PROP Default_Filter ""
-# Begin Source File
-
-SOURCE=..\..\Compress\PpmdDecoder.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\PpmdDecoder.h
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\Compress\PpmdEncoder.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\PpmdEncoder.h
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\Compress\PpmdRegister.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\Compress\PpmdSubAlloc.h
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\Compress\PpmdType.h
-# End Source File
-# End Group
# Begin Group "Bit Coder"
# PROP Default_Filter ""
@@ -628,6 +581,16 @@ SOURCE=..\..\Compress\ZlibEncoder.h
# Begin Source File
SOURCE=..\..\Compress\Bcj2Coder.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
@@ -651,14 +614,6 @@ SOURCE=..\..\Compress\BcjRegister.cpp
# End Source File
# Begin Source File
-SOURCE=..\..\Compress\BranchCoder.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\Compress\BranchCoder.h
-# End Source File
-# Begin Source File
-
SOURCE=..\..\Compress\BranchMisc.cpp
# End Source File
# Begin Source File
@@ -687,6 +642,10 @@ SOURCE=..\..\Compress\CopyRegister.cpp
# End Source File
# Begin Source File
+SOURCE=..\..\Compress\DeltaFilter.cpp
+# End Source File
+# Begin Source File
+
SOURCE=..\..\Compress\Lzma2Decoder.cpp
# End Source File
# Begin Source File
@@ -727,65 +686,77 @@ SOURCE=..\..\Compress\LzmaRegister.cpp
# End Source File
# Begin Source File
-SOURCE=..\..\Compress\RangeCoder.h
-# End Source File
-# Begin Source File
+SOURCE=..\..\Compress\PpmdDecoder.cpp
-SOURCE=..\..\Compress\RangeCoderBit.h
-# End Source File
-# End Group
-# Begin Group "Cab Compress"
+!IF "$(CFG)" == "7z - Win32 Release"
-# PROP Default_Filter ""
-# Begin Source File
+# ADD CPP /O2
+# SUBTRACT CPP /YX /Yc /Yu
+
+!ELSEIF "$(CFG)" == "7z - Win32 Debug"
+
+!ENDIF
-SOURCE=..\..\Compress\Lzx.h
# End Source File
# Begin Source File
-SOURCE=..\..\Compress\Lzx86Converter.cpp
+SOURCE=..\..\Compress\PpmdDecoder.h
# End Source File
# Begin Source File
-SOURCE=..\..\Compress\Lzx86Converter.h
+SOURCE=..\..\Compress\PpmdEncoder.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\LzxDecoder.cpp
+SOURCE=..\..\Compress\PpmdEncoder.h
# End Source File
# Begin Source File
-SOURCE=..\..\Compress\LzxDecoder.h
+SOURCE=..\..\Compress\PpmdRegister.cpp
# End Source File
+# End Group
+# Begin Group "Cab Compress"
+
+# PROP Default_Filter ""
# Begin Source File
-SOURCE=..\..\Compress\QuantumDecoder.cpp
+SOURCE=..\..\Compress\Lzx.h
# End Source File
# Begin Source File
-SOURCE=..\..\Compress\QuantumDecoder.h
+SOURCE=..\..\Compress\Lzx86Converter.cpp
# End Source File
-# End Group
# Begin Source File
-SOURCE=..\..\Compress\ArjDecoder1.cpp
+SOURCE=..\..\Compress\Lzx86Converter.h
# End Source File
# Begin Source File
-SOURCE=..\..\Compress\ArjDecoder1.h
+SOURCE=..\..\Compress\LzxDecoder.cpp
# End Source File
# Begin Source File
-SOURCE=..\..\Compress\ArjDecoder2.cpp
+SOURCE=..\..\Compress\LzxDecoder.h
# End Source File
# Begin Source File
-SOURCE=..\..\Compress\ArjDecoder2.h
+SOURCE=..\..\Compress\QuantumDecoder.cpp
# End Source File
# Begin Source File
-SOURCE=..\..\Compress\DeltaFilter.cpp
+SOURCE=..\..\Compress\QuantumDecoder.h
# End Source File
+# End Group
# Begin Source File
SOURCE=..\..\Compress\HuffmanDecoder.h
@@ -924,25 +895,7 @@ SOURCE=..\..\Crypto\RarAes.h
# End Source File
# Begin Source File
-SOURCE=..\..\Crypto\Sha1.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=..\..\Crypto\Sha1.h
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\Crypto\Sha1Reg.cpp
+SOURCE=..\..\Crypto\Sha1Cls.h
# End Source File
# Begin Source File
@@ -1042,14 +995,6 @@ SOURCE=..\..\Common\LimitedStreams.h
# End Source File
# Begin Source File
-SOURCE=..\..\Common\LockedStream.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\Common\LockedStream.h
-# End Source File
-# Begin Source File
-
SOURCE=..\..\Common\MemBlocks.cpp
# End Source File
# Begin Source File
@@ -1338,6 +1283,42 @@ SOURCE=..\..\..\..\C\Alloc.h
# End Source File
# Begin Source File
+SOURCE=..\..\..\..\C\Bcj2.c
+
+!IF "$(CFG)" == "7z - Win32 Release"
+
+# ADD CPP /O2
+# SUBTRACT CPP /YX /Yc /Yu
+
+!ELSEIF "$(CFG)" == "7z - Win32 Debug"
+
+# SUBTRACT CPP /YX /Yc /Yu
+
+!ENDIF
+
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\C\Bcj2.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\C\Bcj2Enc.c
+
+!IF "$(CFG)" == "7z - Win32 Release"
+
+# ADD CPP /O2
+# SUBTRACT CPP /YX /Yc /Yu
+
+!ELSEIF "$(CFG)" == "7z - Win32 Debug"
+
+# SUBTRACT CPP /YX /Yc /Yu
+
+!ENDIF
+
+# End Source File
+# Begin Source File
+
SOURCE=..\..\..\..\C\Bra.c
!IF "$(CFG)" == "7z - Win32 Release"
@@ -1701,6 +1682,26 @@ SOURCE=..\..\..\..\C\RotateDefs.h
# End Source File
# Begin Source File
+SOURCE=..\..\..\..\C\Sha1.c
+
+!IF "$(CFG)" == "7z - Win32 Release"
+
+# ADD CPP /O2
+# SUBTRACT CPP /YX /Yc /Yu
+
+!ELSEIF "$(CFG)" == "7z - Win32 Debug"
+
+# SUBTRACT CPP /YX /Yc /Yu
+
+!ENDIF
+
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\C\Sha1.h
+# End Source File
+# Begin Source File
+
SOURCE=..\..\..\..\C\Sha256.c
!IF "$(CFG)" == "7z - Win32 Release"
@@ -1797,14 +1798,6 @@ SOURCE=..\..\Archive\7z\7zFolderInStream.h
# End Source File
# Begin Source File
-SOURCE=..\..\Archive\7z\7zFolderOutStream.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\Archive\7z\7zFolderOutStream.h
-# End Source File
-# Begin Source File
-
SOURCE=..\..\Archive\7z\7zHandler.cpp
# End Source File
# Begin Source File
@@ -1973,14 +1966,6 @@ SOURCE=..\..\Archive\Common\CoderMixer2.h
# End Source File
# Begin Source File
-SOURCE=..\..\Archive\Common\CoderMixer2MT.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\Archive\Common\CoderMixer2MT.h
-# End Source File
-# Begin Source File
-
SOURCE=..\..\Archive\Common\DummyOutStream.cpp
# End Source File
# Begin Source File
@@ -2440,6 +2425,10 @@ SOURCE=..\..\Archive\XzHandler.cpp
# End Source File
# Begin Source File
+SOURCE=..\..\Archive\XzHandler.h
+# End Source File
+# Begin Source File
+
SOURCE=..\..\Archive\ZHandler.cpp
# End Source File
# End Group
diff --git a/CPP/7zip/Bundles/Format7zR/makefile b/CPP/7zip/Bundles/Format7zR/makefile
index 555654bc..8d41ce89 100644
--- a/CPP/7zip/Bundles/Format7zR/makefile
+++ b/CPP/7zip/Bundles/Format7zR/makefile
@@ -30,7 +30,6 @@ WIN_OBJS = \
$O\InOutTempBuffer.obj \
$O\FilterCoder.obj \
$O\LimitedStreams.obj \
- $O\LockedStream.obj \
$O\MethodId.obj \
$O\MethodProps.obj \
$O\OutBuffer.obj \
@@ -48,7 +47,6 @@ AR_OBJS = \
AR_COMMON_OBJS = \
$O\CoderMixer2.obj \
- $O\CoderMixer2MT.obj \
$O\CrossThreadProgress.obj \
$O\HandlerOut.obj \
$O\InStreamWithCRC.obj \
@@ -81,7 +79,6 @@ COMPRESS_OBJS = \
$O\Bcj2Register.obj \
$O\BcjCoder.obj \
$O\BcjRegister.obj \
- $O\BranchCoder.obj \
$O\BranchMisc.obj \
$O\BranchRegister.obj \
$O\ByteSwap.obj \
@@ -97,6 +94,8 @@ COMPRESS_OBJS = \
C_OBJS = \
$O\Alloc.obj \
+ $O\Bcj2.obj \
+ $O\Bcj2Enc.obj \
$O\Bra.obj \
$O\Bra86.obj \
$O\BraIA64.obj \
diff --git a/CPP/7zip/Bundles/LzmaCon/LzmaAlone.cpp b/CPP/7zip/Bundles/LzmaCon/LzmaAlone.cpp
index d321e454..5b64b524 100644
--- a/CPP/7zip/Bundles/LzmaCon/LzmaAlone.cpp
+++ b/CPP/7zip/Bundles/LzmaCon/LzmaAlone.cpp
@@ -25,6 +25,7 @@
#include "../../../Windows/System.h"
#endif
+#include "../../../Common/IntToString.h"
#include "../../../Common/CommandLineParser.h"
#include "../../../Common/StringConvert.h"
#include "../../../Common/StringToInt.h"
@@ -36,14 +37,41 @@
#include "../../Compress/LzmaEncoder.h"
#include "../../UI/Console/BenchCon.h"
-
+#include "../../UI/Console/ConsoleClose.h"
using namespace NCommandLineParser;
+static const unsigned kDictSizeLog = 24;
+
+static const char *kCopyrightString = "\nLZMA " MY_VERSION_COPYRIGHT_DATE "\n\n";
+
+static const char *kHelpString =
+ "Usage: LZMA <command> [inputFile] [outputFile] [<switches>...]\n"
+ "\n"
+ "<command>\n"
+ " e : Encode file\n"
+ " d : Decode file\n"
+ " b : Benchmark\n"
+ "<switches>\n"
+ " -a{N} : set compression mode : [0, 1] : default = 1 (max)\n"
+ " -d{N} : set dictionary size : [12, 30] : default = 24 (16 MiB)\n"
+ " -fb{N} : set number of fast bytes : [5, 273] : default = 128\n"
+ " -mc{N} : set number of cycles for match finder\n"
+ " -lc{N} : set number of literal context bits : [0, 8] : default = 3\n"
+ " -lp{N} : set number of literal pos bits : [0, 4] : default = 0\n"
+ " -pb{N} : set number of pos bits : [0, 4] : default = 2\n"
+ " -mf{M} : set match finder: [hc4, bt2, bt3, bt4] : default = bt4\n"
+ " -mt{N} : set number of CPU threads\n"
+ " -eos : write end of stream marker\n"
+ " -si : read data from stdin\n"
+ " -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";
+
namespace NKey {
enum Enum
{
@@ -88,75 +116,195 @@ static const CSwitchForm kSwitchForms[] =
{ "F86", NSwitchType::kChar, false, 0, "+" }
};
-static void PrintMessage(const char *s)
+
+static void PrintErr(const char *s)
{
fputs(s, stderr);
}
+static void PrintErr_LF(const char *s)
+{
+ PrintErr(s);
+ fputc('\n', stderr);
+}
+
+
+static void PrintError(const char *s)
+{
+ PrintErr("\nERROR: ");
+ PrintErr_LF(s);
+}
+
+static void PrintError2(const char *s1, const wchar_t *s2)
+{
+ PrintError(s1);
+ PrintErr_LF(GetOemString(s2));
+}
+
+static void PrintError_int(const char *s, int code)
+{
+ PrintError(s);
+ char temp[32];
+ ConvertInt64ToString(code, temp);
+ PrintErr("Error code = ");
+ PrintErr_LF(temp);
+}
+
+
+
+static void Print(const char *s)
+{
+ fputs(s, stdout);
+}
+
+static void Print_UInt64(UInt64 v)
+{
+ char temp[32];
+ ConvertUInt64ToString(v, temp);
+ Print(temp);
+}
+
+static void Print_MB(UInt64 v)
+{
+ Print_UInt64(v);
+ Print(" MiB");
+}
+
+static void Print_Size(const char *s, UInt64 v)
+{
+ Print(s);
+ Print_UInt64(v);
+ Print(" (");
+ Print_MB(v >> 20);
+ Print(")\n");
+}
+
+static void PrintTitle()
+{
+ Print(kCopyrightString);
+}
+
static void PrintHelp()
{
- PrintMessage("\nUsage: LZMA <e|d> inputFile outputFile [<switches>...]\n"
- " e: encode file\n"
- " d: decode file\n"
- " b: Benchmark\n"
- "<Switches>\n"
- " -a{N}: set compression mode - [0, 1], default: 1 (max)\n"
- " -d{N}: set dictionary size - [12, 30], default: 23 (8MB)\n"
- " -fb{N}: set number of fast bytes - [5, 273], default: 128\n"
- " -mc{N}: set number of cycles for match finder\n"
- " -lc{N}: set number of literal context bits - [0, 8], default: 3\n"
- " -lp{N}: set number of literal pos bits - [0, 4], default: 0\n"
- " -pb{N}: set number of pos bits - [0, 4], default: 2\n"
- " -mf{MF_ID}: set Match Finder: [bt2, bt3, bt4, hc4], default: bt4\n"
- " -mt{N}: set number of CPU threads\n"
- " -eos: write End Of Stream marker\n"
- " -si: read data from stdin\n"
- " -so: write data to stdout\n"
- );
+ PrintTitle();
+ Print(kHelpString);
}
-static void PrintHelpAndExit(const char *s)
+class CProgressPrint:
+ public ICompressProgressInfo,
+ public CMyUnknownImp
+{
+ UInt64 _size1;
+ UInt64 _size2;
+public:
+ CProgressPrint(): _size1(0), _size2(0) {}
+
+ void ClosePrint();
+
+ MY_UNKNOWN_IMP1(ICompressProgressInfo)
+
+ STDMETHOD(SetRatioInfo)(const UInt64 *inSize, const UInt64 *outSize);
+};
+
+#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 =
+BACK_STR
+" "
+BACK_STR;
+
+
+void CProgressPrint::ClosePrint()
{
- fprintf(stderr, "\nError: %s\n\n", s);
- PrintHelp();
- throw -1;
+ Print(kBackSpaces);
}
-static void IncorrectCommand()
+STDMETHODIMP CProgressPrint::SetRatioInfo(const UInt64 *inSize, const UInt64 *outSize)
{
- PrintHelpAndExit("Incorrect command");
+ if (NConsoleClose::TestBreakSignal())
+ return E_ABORT;
+ if (inSize)
+ {
+ UInt64 v1 = *inSize >> 20;
+ UInt64 v2 = _size2;
+ if (outSize)
+ v2 = *outSize >> 20;
+ if (v1 != _size1 || v2 != _size2)
+ {
+ _size1 = v1;
+ _size2 = v2;
+ ClosePrint();
+ Print_MB(_size1);
+ Print(" -> ");
+ Print_MB(_size2);
+ }
+ }
+ return S_OK;
}
-static void WriteArgumentsToStringList(int numArgs, const char *args[], UStringVector &strings)
+
+static void IncorrectCommand()
{
- for (int i = 1; i < numArgs; i++)
- strings.Add(MultiByteToUnicodeString(args[i]));
+ throw "Incorrect command";
}
-static bool GetNumber(const wchar_t *s, UInt32 &value)
+static UInt32 GetNumber(const wchar_t *s)
{
- value = 0;
- if (*s == 0)
- return false;
const wchar_t *end;
- value = ConvertStringToUInt32(s, &end);
- return *end == 0;
+ UInt32 v = ConvertStringToUInt32(s, &end);
+ if (*end != 0)
+ IncorrectCommand();
+ return v;
}
static void ParseUInt32(const CParser &parser, unsigned index, UInt32 &res)
{
if (parser[index].ThereIs)
- if (!GetNumber(parser[index].PostStrings[0], res))
- IncorrectCommand();
+ res = GetNumber(parser[index].PostStrings[0]);
}
-#define NT_CHECK_FAIL_ACTION PrintMessage("Unsupported Windows version"); return 1;
-int main2(int numArgs, const char *args[])
+static int Error_HRESULT(const char *s, HRESULT res)
{
- NT_CHECK
+ if (res == E_ABORT)
+ {
+ Print("\n\nBreak signaled\n");
+ return 255;
+ }
- PrintMessage("\nLZMA " MY_VERSION_COPYRIGHT_DATE "\n");
+ PrintError(s);
+
+ if (res == E_OUTOFMEMORY)
+ {
+ PrintErr_LF(kCantAllocate);
+ return 8;
+ }
+ if (res == E_INVALIDARG)
+ {
+ PrintErr_LF("Ununsupported parameter");
+ }
+ else
+ {
+ char temp[32];
+ ConvertUInt32ToHex(res, temp);
+ PrintErr("Error code = 0x");
+ PrintErr_LF(temp);
+ }
+ return 1;
+}
+
+#define NT_CHECK_FAIL_ACTION PrintError("Unsupported Windows version"); return 1;
+
+static void AddProp(CObjectVector<CProperty> &props2, const char *name, const wchar_t *val)
+{
+ CProperty &prop = props2.AddNew();
+ prop.Name.SetFromAscii(name);
+ prop.Value = val;
+}
+
+static int main2(int numArgs, const char *args[])
+{
+ NT_CHECK
if (numArgs == 1)
{
@@ -164,20 +312,24 @@ int main2(int numArgs, const char *args[])
return 0;
}
- bool unsupportedTypes = (sizeof(Byte) != 1 || sizeof(UInt32) < 4 || sizeof(UInt64) < 4);
+ /*
+ bool unsupportedTypes = (sizeof(Byte) != 1 || sizeof(UInt32) < 4 || sizeof(UInt64) < 8);
if (unsupportedTypes)
- {
- PrintMessage("Unsupported base types. Edit Common/Types.h and recompile");
- return 1;
- }
+ throw "Unsupported base types. Edit Common/Types.h and recompile";
+ */
UStringVector commandStrings;
- WriteArgumentsToStringList(numArgs, args, commandStrings);
+ for (int i = 1; i < numArgs; i++)
+ commandStrings.Add(MultiByteToUnicodeString(args[i]));
CParser parser(ARRAY_SIZE(kSwitchForms));
try
{
- parser.ParseStrings(kSwitchForms, commandStrings);
+ if (!parser.ParseStrings(kSwitchForms, commandStrings))
+ {
+ PrintError2(parser.ErrorMessage, parser.ErrorLine);
+ return 1;
+ }
}
catch(...)
{
@@ -189,40 +341,41 @@ int main2(int numArgs, const char *args[])
PrintHelp();
return 0;
}
- const UStringVector &nonSwitchStrings = parser.NonSwitchStrings;
+
+ bool stdInMode = parser[NKey::kStdIn].ThereIs;
+ bool stdOutMode = parser[NKey::kStdOut].ThereIs;
+
+ if (!stdOutMode)
+ PrintTitle();
+
+ const UStringVector &params = parser.NonSwitchStrings;
unsigned paramIndex = 0;
- if (paramIndex >= nonSwitchStrings.Size())
+ if (paramIndex >= params.Size())
IncorrectCommand();
- const UString &command = nonSwitchStrings[paramIndex++];
+ const UString &command = params[paramIndex++];
- CObjectVector<CProperty> props;
+ CObjectVector<CProperty> props2;
bool dictDefined = false;
UInt32 dict = (UInt32)(Int32)-1;
+
if (parser[NKey::kDict].ThereIs)
{
- UInt32 dicLog;
+ UInt32 dictLog;
const UString &s = parser[NKey::kDict].PostStrings[0];
- if (!GetNumber(s, dicLog))
- IncorrectCommand();
- dict = 1 << dicLog;
+ dictLog = GetNumber(s);
+ dict = 1 << dictLog;
dictDefined = true;
- CProperty prop;
- prop.Name = L"d";
- prop.Value = s;
- props.Add(prop);
+ AddProp(props2, "d", s);
}
+
if (parser[NKey::kLevel].ThereIs)
{
- UInt32 level = 5;
const UString &s = parser[NKey::kLevel].PostStrings[0];
- if (!GetNumber(s, level))
- IncorrectCommand();
- CProperty prop;
- prop.Name = L"x";
- prop.Value = s;
- props.Add(prop);
+ /* UInt32 level = */ GetNumber(s);
+ AddProp(props2, "x", s);
}
+
UString mf = L"BT4";
if (parser[NKey::kMatchFinder].ThereIs)
mf = parser[NKey::kMatchFinder].PostStrings[0];
@@ -230,70 +383,64 @@ int main2(int numArgs, const char *args[])
UInt32 numThreads = (UInt32)(Int32)-1;
#ifndef _7ZIP_ST
+
if (parser[NKey::kMultiThread].ThereIs)
{
- UInt32 numCPUs = NWindows::NSystem::GetNumberOfProcessors();
const UString &s = parser[NKey::kMultiThread].PostStrings[0];
if (s.IsEmpty())
- numThreads = numCPUs;
+ numThreads = NWindows::NSystem::GetNumberOfProcessors();
else
- if (!GetNumber(s, numThreads))
- IncorrectCommand();
- CProperty prop;
- prop.Name = L"mt";
- prop.Value = s;
- props.Add(prop);
+ numThreads = GetNumber(s);
+ AddProp(props2, "mt", s);
}
+
#endif
+
if (parser[NKey::kMethod].ThereIs)
{
- UString s = parser[NKey::kMethod].PostStrings[0];
+ const UString &s = parser[NKey::kMethod].PostStrings[0];
if (s.IsEmpty() || s[0] != '=')
IncorrectCommand();
- CProperty prop;
- prop.Name = L"m";
- prop.Value = s.Ptr(1);
- props.Add(prop);
+ AddProp(props2, "m", s.Ptr(1));
}
- if (MyStringCompareNoCase(command, L"b") == 0)
+ if (StringsAreEqualNoCase_Ascii(command, "b"))
{
- const UInt32 kNumDefaultItereations = 1;
- UInt32 numIterations = kNumDefaultItereations;
- {
- if (paramIndex < nonSwitchStrings.Size())
- if (!GetNumber(nonSwitchStrings[paramIndex++], numIterations))
- numIterations = kNumDefaultItereations;
- }
- HRESULT res = BenchCon(props, numIterations, stderr);
- if (res != S_OK)
- {
- if (res != E_ABORT)
- {
- PrintMessage("Benchmark Error");
- return 1;
- }
- }
- return 0;
+ UInt32 numIterations = 1;
+ if (paramIndex < params.Size())
+ numIterations = GetNumber(params[paramIndex++]);
+ if (params.Size() != paramIndex)
+ IncorrectCommand();
+
+ HRESULT res = BenchCon(props2, numIterations, stdout);
+
+ if (res == S_OK)
+ return 0;
+ return Error_HRESULT("Benchmark error", res);
+ }
+
+ {
+ UInt32 needParams = 3;
+ if (stdInMode) needParams--;
+ if (stdOutMode) needParams--;
+ if (needParams != params.Size())
+ IncorrectCommand();
}
if (numThreads == (UInt32)(Int32)-1)
numThreads = 1;
bool encodeMode = false;
- if (MyStringCompareNoCase(command, L"e") == 0)
+
+ if (StringsAreEqualNoCase_Ascii(command, "e"))
encodeMode = true;
- else if (MyStringCompareNoCase(command, L"d") == 0)
- encodeMode = false;
- else
+ else if (!StringsAreEqualNoCase_Ascii(command, "d"))
IncorrectCommand();
- bool stdInMode = parser[NKey::kStdIn].ThereIs;
- bool stdOutMode = parser[NKey::kStdOut].ThereIs;
-
CMyComPtr<ISequentialInStream> inStream;
- CInFileStream *inStreamSpec = 0;
+ CInFileStream *inStreamSpec = NULL;
+
if (stdInMode)
{
inStream = new CStdInFileStream;
@@ -301,21 +448,19 @@ int main2(int numArgs, const char *args[])
}
else
{
- if (paramIndex >= nonSwitchStrings.Size())
- IncorrectCommand();
- const UString &inputName = nonSwitchStrings[paramIndex++];
+ const UString &inputName = params[paramIndex++];
inStreamSpec = new CInFileStream;
inStream = inStreamSpec;
if (!inStreamSpec->Open(us2fs(inputName)))
{
- fprintf(stderr, "\nError: can not open input file %s\n",
- (const char *)GetOemString(inputName));
+ PrintError2("can not open input file", inputName);
return 1;
}
}
CMyComPtr<ISequentialOutStream> outStream;
COutFileStream *outStreamSpec = NULL;
+
if (stdOutMode)
{
outStream = new CStdOutFileStream;
@@ -323,42 +468,70 @@ int main2(int numArgs, const char *args[])
}
else
{
- if (paramIndex >= nonSwitchStrings.Size())
- IncorrectCommand();
- const UString &outputName = nonSwitchStrings[paramIndex++];
+ const UString &outputName = params[paramIndex++];
outStreamSpec = new COutFileStream;
outStream = outStreamSpec;
if (!outStreamSpec->Create(us2fs(outputName), true))
{
- fprintf(stderr, "\nError: can not open output file %s\n",
- (const char *)GetOemString(outputName));
+ PrintError2("can not open output file", outputName);
return 1;
}
}
+ bool fileSizeDefined = false;
+ UInt64 fileSize = 0;
+
+ if (inStreamSpec)
+ {
+ if (!inStreamSpec->File.GetLength(fileSize))
+ throw "Can not get file length";
+ fileSizeDefined = true;
+ if (!stdOutMode)
+ Print_Size("Input size: ", fileSize);
+ }
+
+ if (encodeMode && !dictDefined)
+ {
+ dict = 1 << kDictSizeLog;
+ if (fileSizeDefined)
+ {
+ unsigned i;
+ for (i = 16; i < kDictSizeLog; i++)
+ if ((UInt32)((UInt32)1 << i) >= fileSize)
+ break;
+ dict = (UInt32)1 << i;
+ }
+ }
+
if (parser[NKey::kFilter86].ThereIs)
{
- // -f86 switch is for x86 filtered mode: BCJ + LZMA.
+ /* -f86 switch is for x86 filtered mode: BCJ + LZMA.
+ It uses modified header format.
+ It's not recommended to use -f86 mode now.
+ You can use xz format instead, if you want to use filters */
+
if (parser[NKey::kEOS].ThereIs || stdInMode)
throw "Can not use stdin in this mode";
- UInt64 fileSize;
- inStreamSpec->File.GetLength(fileSize);
+
if (fileSize > 0xF0000000)
throw "File is too big";
+
size_t inSize = (size_t)fileSize;
- Byte *inBuffer = 0;
+ Byte *inBuffer = NULL;
+
if (inSize != 0)
{
inBuffer = (Byte *)MyAlloc((size_t)inSize);
- if (inBuffer == 0)
+ if (!inBuffer)
throw kCantAllocate;
}
if (ReadStream_FAIL(inStream, inBuffer, inSize) != S_OK)
throw "Can not read";
- Byte *outBuffer = 0;
+ Byte *outBuffer = NULL;
size_t outSize;
+
if (encodeMode)
{
// we allocate 105% of original size for output buffer
@@ -366,56 +539,70 @@ int main2(int numArgs, const char *args[])
if (outSize != 0)
{
outBuffer = (Byte *)MyAlloc((size_t)outSize);
- if (outBuffer == 0)
+ if (!outBuffer)
throw kCantAllocate;
}
- if (!dictDefined)
- dict = 1 << 23;
+
int res = Lzma86_Encode(outBuffer, &outSize, inBuffer, inSize,
5, dict, parser[NKey::kFilter86].PostCharIndex == 0 ? SZ_FILTER_YES : SZ_FILTER_AUTO);
+
if (res != 0)
{
- fprintf(stderr, "\nEncoder error = %d\n", (int)res);
+ PrintError_int("Encode error", (int)res);
return 1;
}
}
else
{
UInt64 outSize64;
+
if (Lzma86_GetUnpackSize(inBuffer, inSize, &outSize64) != 0)
throw "data error";
+
outSize = (size_t)outSize64;
if (outSize != outSize64)
throw "too big";
if (outSize != 0)
{
outBuffer = (Byte *)MyAlloc(outSize);
- if (outBuffer == 0)
+ if (!outBuffer)
throw kCantAllocate;
}
+
int res = Lzma86_Decode(outBuffer, &outSize, inBuffer, &inSize);
+
if (inSize != (size_t)fileSize)
throw "incorrect processed size";
if (res != 0)
- throw "LzmaDecoder error";
+ {
+ PrintError_int("Decode error", (int)res);
+ return 1;
+ }
}
+
if (WriteStream(outStream, outBuffer, outSize) != S_OK)
throw kWriteError;
+
MyFree(outBuffer);
MyFree(inBuffer);
- return 0;
}
+ else
+ {
+
+ CProgressPrint *progressSpec = NULL;
+ CMyComPtr<ICompressProgressInfo> progress;
+ if (!stdOutMode)
+ {
+ progressSpec = new CProgressPrint;
+ progress = progressSpec;
+ }
- UInt64 fileSize;
if (encodeMode)
{
NCompress::NLzma::CEncoder *encoderSpec = new NCompress::NLzma::CEncoder;
CMyComPtr<ICompressCoder> encoder = encoderSpec;
- if (!dictDefined)
- dict = 1 << 23;
-
UInt32 pb = 2;
UInt32 lc = 3; // = 0; for 32-bit data
UInt32 lp = 0; // = 2; for 32-bit data
@@ -434,8 +621,7 @@ int main2(int numArgs, const char *args[])
mcDefined = parser[NKey::kMc].ThereIs;
if (mcDefined)
- if (!GetNumber(parser[NKey::kMc].PostStrings[0], mc))
- IncorrectCommand();
+ mc = GetNumber(parser[NKey::kMc].PostStrings[0]);
const PROPID propIDs[] =
{
@@ -450,6 +636,7 @@ int main2(int numArgs, const char *args[])
NCoderPropID::kNumThreads,
NCoderPropID::kMatchFinderCycles,
};
+
const unsigned kNumPropsMax = ARRAY_SIZE(propIDs);
PROPVARIANT props[kNumPropsMax];
@@ -480,92 +667,106 @@ int main2(int numArgs, const char *args[])
if (!mcDefined)
numProps--;
- if (encoderSpec->SetCoderProperties(propIDs, props, numProps) != S_OK)
- IncorrectCommand();
- encoderSpec->WriteCoderProperties(outStream);
+ HRESULT res = encoderSpec->SetCoderProperties(propIDs, props, numProps);
+ if (res != S_OK)
+ return Error_HRESULT("incorrect encoder properties", res);
- if (eos || stdInMode)
- fileSize = (UInt64)(Int64)-1;
- else
- inStreamSpec->File.GetLength(fileSize);
+ if (encoderSpec->WriteCoderProperties(outStream) != S_OK)
+ throw kWriteError;
- for (int i = 0; i < 8; i++)
- {
- Byte b = Byte(fileSize >> (8 * i));
- if (outStream->Write(&b, 1, 0) != S_OK)
- {
- PrintMessage(kWriteError);
- return 1;
- }
- }
- HRESULT result = encoder->Code(inStream, outStream, 0, 0, 0);
- if (result == E_OUTOFMEMORY)
+ bool fileSizeWasUsed = true;
+ if (eos || stdInMode)
{
- PrintMessage("\nError: Can not allocate memory\n");
- return 1;
+ fileSize = (UInt64)(Int64)-1;
+ fileSizeWasUsed = false;
}
- else if (result != S_OK)
+
{
- fprintf(stderr, "\nEncoder error = %X\n", (unsigned)result);
- return 1;
+ Byte temp[8];
+ for (int i = 0; i < 8; i++)
+ temp[i]= (Byte)(fileSize >> (8 * i));
+ if (WriteStream(outStream, temp, 8) != S_OK)
+ throw kWriteError;
}
+
+ res = encoder->Code(inStream, outStream, NULL, NULL, progress);
+ if (progressSpec)
+ progressSpec->ClosePrint();
+
+ if (res != S_OK)
+ return Error_HRESULT("Encoding error", res);
+
+ UInt64 processedSize = encoderSpec->GetInputProcessedSize();
+
+ if (fileSizeWasUsed && processedSize != fileSize)
+ throw "Incorrect size of processed data";
}
else
{
NCompress::NLzma::CDecoder *decoderSpec = new NCompress::NLzma::CDecoder;
CMyComPtr<ICompressCoder> decoder = decoderSpec;
+
decoderSpec->FinishStream = true;
- const UInt32 kPropertiesSize = 5;
+
+ const unsigned kPropertiesSize = 5;
Byte header[kPropertiesSize + 8];
+
if (ReadStream_FALSE(inStream, header, kPropertiesSize + 8) != S_OK)
- {
- PrintMessage(kReadError);
- return 1;
- }
+ throw kReadError;
+
if (decoderSpec->SetDecoderProperties2(header, kPropertiesSize) != S_OK)
- {
- PrintMessage("SetDecoderProperties error");
- return 1;
- }
- fileSize = 0;
+ throw "SetDecoderProperties error";
+
+ UInt64 unpackSize = 0;
for (int i = 0; i < 8; i++)
- fileSize |= ((UInt64)header[kPropertiesSize + i]) << (8 * i);
+ unpackSize |= ((UInt64)header[kPropertiesSize + i]) << (8 * i);
+
+ bool unpackSizeDefined = (unpackSize != (UInt64)(Int64)-1);
+
+ HRESULT res = decoder->Code(inStream, outStream, NULL, unpackSizeDefined ? &unpackSize : NULL, progress);
+ if (progressSpec)
+ progressSpec->ClosePrint();
- bool isSizeDefined = (fileSize != (UInt64)(Int64)-1);
- HRESULT res = decoder->Code(inStream, outStream, 0, isSizeDefined ? &fileSize : NULL, 0) != S_OK;
if (res != S_OK)
{
- PrintMessage("Decoder error");
- return 1;
- }
- if (isSizeDefined && decoderSpec->GetOutputProcessedSize() != fileSize)
- {
- PrintMessage("Error: incorrect uncompressed size in header");
- return 1;
+ if (res == S_FALSE)
+ {
+ PrintError("Decoding error");
+ return 1;
+ }
+ return Error_HRESULT("Decoding error", res);
}
+
+ if (unpackSizeDefined && unpackSize != decoderSpec->GetOutputProcessedSize())
+ throw "incorrect uncompressed size in header";
+ }
}
- if (outStreamSpec != NULL)
+
+ if (!stdOutMode)
+ Print_Size("Output size: ", outStreamSpec->ProcessedSize);
+
+ if (outStreamSpec)
{
if (outStreamSpec->Close() != S_OK)
- {
- PrintMessage("File closing error");
- return 1;
- }
+ throw "File closing error";
}
+
return 0;
}
int MY_CDECL main(int numArgs, const char *args[])
{
+ NConsoleClose::CCtrlHandlerSetter ctrlHandlerSetter;
+
try { return main2(numArgs, args); }
catch (const char *s)
{
- fprintf(stderr, "\nError: %s\n", s);
+ PrintError(s);
return 1;
}
catch(...)
{
- PrintMessage("\nError\n");
+ PrintError("Unknown Error");
return 1;
}
}
diff --git a/CPP/7zip/Bundles/LzmaCon/resource.rc b/CPP/7zip/Bundles/LzmaCon/resource.rc
index c68fdcc0..43b50738 100644
--- a/CPP/7zip/Bundles/LzmaCon/resource.rc
+++ b/CPP/7zip/Bundles/LzmaCon/resource.rc
@@ -1,3 +1,3 @@
-#include "../../../../C/7zVersion.rc"
+#include "../../MyVersionInfo.rc"
MY_VERSION_INFO_APP("LZMA", "lzma")
diff --git a/CPP/7zip/Bundles/SFXCon/SFXCon.dsp b/CPP/7zip/Bundles/SFXCon/SFXCon.dsp
index 092fedcd..0cacd60c 100644
--- a/CPP/7zip/Bundles/SFXCon/SFXCon.dsp
+++ b/CPP/7zip/Bundles/SFXCon/SFXCon.dsp
@@ -117,14 +117,6 @@ SOURCE=..\..\Archive\Common\CoderMixer2.h
# End Source File
# Begin Source File
-SOURCE=..\..\Archive\Common\CoderMixer2MT.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\Archive\Common\CoderMixer2MT.h
-# End Source File
-# Begin Source File
-
SOURCE=..\..\Archive\Common\CrossThreadProgress.cpp
# End Source File
# Begin Source File
@@ -197,6 +189,14 @@ SOURCE=..\..\UI\Console\OpenCallbackConsole.h
# End Source File
# Begin Source File
+SOURCE=..\..\UI\Console\PercentPrinter.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\UI\Console\PercentPrinter.h
+# End Source File
+# Begin Source File
+
SOURCE=..\..\UI\Console\UserInputUtils.cpp
# End Source File
# Begin Source File
@@ -281,7 +281,15 @@ SOURCE=..\..\Compress\BcjRegister.cpp
# End Source File
# Begin Source File
-SOURCE=..\..\Compress\BranchCoder.cpp
+SOURCE=..\..\Compress\BranchMisc.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Compress\BranchMisc.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Compress\BranchRegister.cpp
# End Source File
# Begin Source File
@@ -293,6 +301,10 @@ SOURCE=..\..\Compress\CopyRegister.cpp
# End Source File
# Begin Source File
+SOURCE=..\..\Compress\DeltaFilter.cpp
+# End Source File
+# Begin Source File
+
SOURCE=..\..\Compress\Lzma2Decoder.cpp
# End Source File
# Begin Source File
@@ -605,6 +617,14 @@ SOURCE=..\..\Common\PropId.cpp
# End Source File
# Begin Source File
+SOURCE=..\..\Common\RegisterArc.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Common\RegisterCodec.h
+# End Source File
+# Begin Source File
+
SOURCE=..\..\Common\StreamBinder.cpp
# End Source File
# Begin Source File
@@ -758,6 +778,20 @@ SOURCE=..\..\..\..\C\Alloc.h
# End Source File
# Begin Source File
+SOURCE=..\..\..\..\C\Bcj2.c
+# SUBTRACT CPP /YX /Yc /Yu
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\C\Bcj2.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\C\Bra.c
+# SUBTRACT CPP /YX /Yc /Yu
+# End Source File
+# Begin Source File
+
SOURCE=..\..\..\..\C\Bra.h
# End Source File
# Begin Source File
@@ -767,11 +801,25 @@ SOURCE=..\..\..\..\C\Bra86.c
# End Source File
# Begin Source File
+SOURCE=..\..\..\..\C\BraIA64.c
+# SUBTRACT CPP /YX /Yc /Yu
+# End Source File
+# Begin Source File
+
SOURCE=..\..\..\..\C\CpuArch.c
# SUBTRACT CPP /YX /Yc /Yu
# End Source File
# Begin Source File
+SOURCE=..\..\..\..\C\Delta.c
+# SUBTRACT CPP /YX /Yc /Yu
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\C\Delta.h
+# End Source File
+# Begin Source File
+
SOURCE=..\..\..\..\C\Lzma2Dec.c
# SUBTRACT CPP /YX /Yc /Yu
# End Source File
diff --git a/CPP/7zip/Bundles/SFXCon/SfxCon.cpp b/CPP/7zip/Bundles/SFXCon/SfxCon.cpp
index c8837f9d..01089c5e 100644
--- a/CPP/7zip/Bundles/SFXCon/SfxCon.cpp
+++ b/CPP/7zip/Bundles/SFXCon/SfxCon.cpp
@@ -104,7 +104,7 @@ static const char *kHelpString =
"\nUsage: 7zSFX [<command>] [<switches>...]\n"
"\n"
"<Commands>\n"
- " l: List contents of archive\n"
+ // " l: List contents of archive\n"
" t: Test integrity of archive\n"
" x: eXtract files with full pathname (default)\n"
"<Switches>\n"
@@ -369,22 +369,22 @@ int Main2(
{
CExtractCallbackConsole *ecs = new CExtractCallbackConsole;
CMyComPtr<IFolderArchiveExtractCallback> extractCallback = ecs;
- ecs->OutStream = g_StdStream;
+ ecs->Init(g_StdStream, &g_StdErr, g_StdStream);
#ifndef _NO_CRYPTO
ecs->PasswordIsDefined = passwordEnabled;
ecs->Password = password;
#endif
- ecs->Init();
-
+ /*
COpenCallbackConsole openCallback;
- openCallback.OutStream = g_StdStream;
+ openCallback.Init(g_StdStream, g_StdStream);
#ifndef _NO_CRYPTO
openCallback.PasswordIsDefined = passwordEnabled;
openCallback.Password = password;
#endif
+ */
CExtractOptions eo;
eo.StdOutMode = false;
@@ -402,7 +402,7 @@ int Main2(
codecs, CObjectVector<COpenType>(), CIntVector(),
v1, v2,
wildcardCensorHead,
- eo, &openCallback, ecs,
+ eo, ecs, ecs,
// NULL, // hash
errorMessage, stat);
if (!errorMessage.IsEmpty())
@@ -425,6 +425,9 @@ int Main2(
}
else
{
+ throw CSystemException(E_NOTIMPL);
+
+ /*
UInt64 numErrors = 0;
UInt64 numWarnings = 0;
HRESULT result = ListArchives(
@@ -447,6 +450,7 @@ int Main2(
}
if (result != S_OK)
throw CSystemException(result);
+ */
}
}
return 0;
diff --git a/CPP/7zip/Bundles/SFXCon/makefile b/CPP/7zip/Bundles/SFXCon/makefile
index dd795b0b..d3d61372 100644
--- a/CPP/7zip/Bundles/SFXCon/makefile
+++ b/CPP/7zip/Bundles/SFXCon/makefile
@@ -14,6 +14,7 @@ CONSOLE_OBJS = \
$O\List.obj \
$O\MainAr.obj \
$O\OpenCallbackConsole.obj \
+ $O\PercentPrinter.obj \
$O\UserInputUtils.obj \
COMMON_OBJS = \
@@ -48,7 +49,6 @@ WIN_OBJS = \
$O\InBuffer.obj \
$O\FilterCoder.obj \
$O\LimitedStreams.obj \
- $O\LockedStream.obj \
$O\OutBuffer.obj \
$O\ProgressUtils.obj \
$O\PropId.obj \
@@ -72,7 +72,6 @@ AR_OBJS = \
AR_COMMON_OBJS = \
$O\CoderMixer2.obj \
- $O\CoderMixer2MT.obj \
$O\CrossThreadProgress.obj \
$O\ItemNameUtils.obj \
$O\MultiStream.obj \
@@ -88,13 +87,15 @@ AR_COMMON_OBJS = \
$O\7zRegister.obj \
COMPRESS_OBJS = \
- $O\BranchCoder.obj \
$O\Bcj2Coder.obj \
$O\Bcj2Register.obj \
$O\BcjCoder.obj \
$O\BcjRegister.obj \
+ $O\BranchMisc.obj \
+ $O\BranchRegister.obj \
$O\CopyCoder.obj \
$O\CopyRegister.obj \
+ $O\DeltaFilter.obj \
$O\Lzma2Decoder.obj \
$O\Lzma2Register.obj \
$O\LzmaDecoder.obj \
@@ -109,8 +110,12 @@ CRYPTO_OBJS = \
C_OBJS = \
$O\Alloc.obj \
+ $O\Bcj2.obj \
+ $O\Bra.obj \
$O\Bra86.obj \
+ $O\BraIA64.obj \
$O\CpuArch.obj \
+ $O\Delta.obj \
$O\Lzma2Dec.obj \
$O\LzmaDec.obj \
$O\Ppmd7.obj \
diff --git a/CPP/7zip/Bundles/SFXCon/resource.rc b/CPP/7zip/Bundles/SFXCon/resource.rc
index a83581c2..58331b81 100644
--- a/CPP/7zip/Bundles/SFXCon/resource.rc
+++ b/CPP/7zip/Bundles/SFXCon/resource.rc
@@ -1,4 +1,4 @@
-#include "../../../../C/7zVersion.rc"
+#include "../../MyVersionInfo.rc"
MY_VERSION_INFO_APP("7z Console SFX", "7z.sfx")
diff --git a/CPP/7zip/Bundles/SFXSetup/ExtractCallbackSfx.cpp b/CPP/7zip/Bundles/SFXSetup/ExtractCallbackSfx.cpp
index 9fe98fc0..ac7df6b2 100644
--- a/CPP/7zip/Bundles/SFXSetup/ExtractCallbackSfx.cpp
+++ b/CPP/7zip/Bundles/SFXSetup/ExtractCallbackSfx.cpp
@@ -58,6 +58,11 @@ HRESULT CExtractCallbackImp::Open_SetCompleted(const UInt64 * /* numFiles */, co
#endif
}
+HRESULT CExtractCallbackImp::Open_Finished()
+{
+ return S_OK;
+}
+
STDMETHODIMP CExtractCallbackImp::SetTotal(UInt64 size)
{
#ifndef _NO_PROGRESS
@@ -83,7 +88,7 @@ void CExtractCallbackImp::CreateComplexDirectory(const UStringVector &dirPathPar
{
fullPath += us2fs(dirPathParts[i]);
CreateDir(fullPath);
- fullPath += FCHAR_PATH_SEPARATOR;
+ fullPath.Add_PathSepar();
}
}
@@ -95,18 +100,21 @@ STDMETHODIMP CExtractCallbackImp::GetStream(UInt32 index,
return E_ABORT;
#endif
_outFileStream.Release();
- NCOM::CPropVariant propVariantName;
- RINOK(_archiveHandler->GetProperty(index, kpidPath, &propVariantName));
+
UString fullPath;
- if (propVariantName.vt == VT_EMPTY)
- fullPath = _itemDefaultName;
- else
{
- if (propVariantName.vt != VT_BSTR)
- return E_FAIL;
- fullPath = propVariantName.bstrVal;
+ NCOM::CPropVariant prop;
+ RINOK(_archiveHandler->GetProperty(index, kpidPath, &prop));
+ if (prop.vt == VT_EMPTY)
+ fullPath = _itemDefaultName;
+ else
+ {
+ if (prop.vt != VT_BSTR)
+ return E_FAIL;
+ fullPath.SetFromBstr(prop.bstrVal);
+ }
+ _filePath = fullPath;
}
- _filePath = fullPath;
if (askExtractMode == NArchive::NExtract::NAskMode::kExtract)
{
diff --git a/CPP/7zip/Bundles/SFXSetup/SFXSetup.dsp b/CPP/7zip/Bundles/SFXSetup/SFXSetup.dsp
index 3a8ae36b..1f076f7d 100644
--- a/CPP/7zip/Bundles/SFXSetup/SFXSetup.dsp
+++ b/CPP/7zip/Bundles/SFXSetup/SFXSetup.dsp
@@ -205,14 +205,6 @@ SOURCE=..\..\Archive\Common\CoderMixer2.h
# End Source File
# Begin Source File
-SOURCE=..\..\Archive\Common\CoderMixer2MT.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\Archive\Common\CoderMixer2MT.h
-# End Source File
-# Begin Source File
-
SOURCE=..\..\Archive\Common\CrossThreadProgress.cpp
# End Source File
# Begin Source File
@@ -257,7 +249,15 @@ SOURCE=..\..\Compress\BcjRegister.cpp
# End Source File
# Begin Source File
-SOURCE=..\..\Compress\BranchCoder.cpp
+SOURCE=..\..\Compress\BranchMisc.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Compress\BranchMisc.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Compress\BranchRegister.cpp
# End Source File
# Begin Source File
@@ -269,6 +269,10 @@ SOURCE=..\..\Compress\CopyRegister.cpp
# End Source File
# Begin Source File
+SOURCE=..\..\Compress\DeltaFilter.cpp
+# End Source File
+# Begin Source File
+
SOURCE=..\..\Compress\Lzma2Decoder.cpp
# End Source File
# Begin Source File
@@ -513,14 +517,6 @@ SOURCE=..\..\Common\LimitedStreams.h
# End Source File
# Begin Source File
-SOURCE=..\..\Common\LockedStream.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\Common\LockedStream.h
-# End Source File
-# Begin Source File
-
SOURCE=..\..\Common\OutBuffer.cpp
# End Source File
# Begin Source File
@@ -680,6 +676,20 @@ SOURCE=..\..\..\..\C\Alloc.h
# End Source File
# Begin Source File
+SOURCE=..\..\..\..\C\Bcj2.c
+# SUBTRACT CPP /YX /Yc /Yu
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\C\Bcj2.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\C\Bra.c
+# SUBTRACT CPP /YX /Yc /Yu
+# End Source File
+# Begin Source File
+
SOURCE=..\..\..\..\C\Bra.h
# End Source File
# Begin Source File
@@ -689,6 +699,11 @@ SOURCE=..\..\..\..\C\Bra86.c
# End Source File
# Begin Source File
+SOURCE=..\..\..\..\C\BraIA64.c
+# SUBTRACT CPP /YX /Yc /Yu
+# End Source File
+# Begin Source File
+
SOURCE=..\..\..\..\C\CpuArch.c
# SUBTRACT CPP /YX /Yc /Yu
# End Source File
@@ -698,6 +713,15 @@ SOURCE=..\..\..\..\C\CpuArch.h
# End Source File
# Begin Source File
+SOURCE=..\..\..\..\C\Delta.c
+# SUBTRACT CPP /YX /Yc /Yu
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\C\Delta.h
+# End Source File
+# Begin Source File
+
SOURCE=..\..\..\..\C\Lzma2Dec.c
# SUBTRACT CPP /YX /Yc /Yu
# End Source File
diff --git a/CPP/7zip/Bundles/SFXSetup/SfxSetup.cpp b/CPP/7zip/Bundles/SFXSetup/SfxSetup.cpp
index 20bde9e9..611ef651 100644
--- a/CPP/7zip/Bundles/SFXSetup/SfxSetup.cpp
+++ b/CPP/7zip/Bundles/SFXSetup/SfxSetup.cpp
@@ -94,12 +94,11 @@ static bool ReadDataString(CFSTR fileName, LPCSTR startID,
}
}
-static char kStartID[] = ",!@Install@!UTF-8!";
-static char kEndID[] = ",!@InstallEnd@!";
+static char kStartID[] = { ',','!','@','I','n','s','t','a','l','l','@','!','U','T','F','-','8','!', 0 };
+static char kEndID[] = { ',','!','@','I','n','s','t','a','l','l','E','n','d','@','!', 0 };
-class CInstallIDInit
+struct CInstallIDInit
{
-public:
CInstallIDInit()
{
kStartID[0] = ';';
@@ -147,7 +146,7 @@ int APIENTRY WinMain(HINSTANCE hInstance, HINSTANCE /* hPrevInstance */,
switches.Trim();
bool assumeYes = false;
- if (MyStringCompareNoCase_N(switches, L"-y", 2) == 0)
+ if (switches.IsPrefixedBy_Ascii_NoCase("-y"))
{
assumeYes = true;
switches = switches.Ptr(2);
@@ -177,7 +176,7 @@ int APIENTRY WinMain(HINSTANCE hInstance, HINSTANCE /* hPrevInstance */,
UString friendlyName = GetTextConfigValue(pairs, L"Title");
UString installPrompt = GetTextConfigValue(pairs, L"BeginPrompt");
UString progress = GetTextConfigValue(pairs, L"Progress");
- if (progress.IsEqualToNoCase(L"no"))
+ if (progress.IsEqualTo_Ascii_NoCase("no"))
showProgress = false;
int index = FindTextConfigItem(pairs, L"Directory");
if (index >= 0)
@@ -265,8 +264,7 @@ int APIENTRY WinMain(HINSTANCE hInstance, HINSTANCE /* hPrevInstance */,
if (!switches.IsEmpty())
{
- if (!executeParameters.IsEmpty())
- executeParameters += L' ';
+ executeParameters.Add_Space_if_NotEmpty();
executeParameters += switches;
}
@@ -315,7 +313,7 @@ int APIENTRY WinMain(HINSTANCE hInstance, HINSTANCE /* hPrevInstance */,
if (!switches.IsEmpty())
{
- appLaunched += L' ';
+ appLaunched.Add_Space();
appLaunched += switches;
}
STARTUPINFO startupInfo;
diff --git a/CPP/7zip/Bundles/SFXSetup/makefile b/CPP/7zip/Bundles/SFXSetup/makefile
index ac5c6aa4..ae631988 100644
--- a/CPP/7zip/Bundles/SFXSetup/makefile
+++ b/CPP/7zip/Bundles/SFXSetup/makefile
@@ -44,7 +44,6 @@ WIN_CTRL_OBJS = \
$O\InBuffer.obj \
$O\FilterCoder.obj \
$O\LimitedStreams.obj \
- $O\LockedStream.obj \
$O\OutBuffer.obj \
$O\ProgressUtils.obj \
$O\PropId.obj \
@@ -68,7 +67,6 @@ FM_OBJS = \
AR_COMMON_OBJS = \
$O\CoderMixer2.obj \
- $O\CoderMixer2MT.obj \
$O\CrossThreadProgress.obj \
$O\ItemNameUtils.obj \
$O\OutStreamWithCRC.obj \
@@ -82,13 +80,15 @@ AR_COMMON_OBJS = \
$O\7zRegister.obj \
COMPRESS_OBJS = \
- $O\BranchCoder.obj \
$O\Bcj2Coder.obj \
$O\Bcj2Register.obj \
$O\BcjCoder.obj \
$O\BcjRegister.obj \
+ $O\BranchMisc.obj \
+ $O\BranchRegister.obj \
$O\CopyCoder.obj \
$O\CopyRegister.obj \
+ $O\DeltaFilter.obj \
$O\Lzma2Decoder.obj \
$O\Lzma2Register.obj \
$O\LzmaDecoder.obj \
@@ -96,8 +96,12 @@ COMPRESS_OBJS = \
C_OBJS = \
$O\Alloc.obj \
+ $O\Bcj2.obj \
+ $O\Bra.obj \
$O\Bra86.obj \
+ $O\BraIA64.obj \
$O\CpuArch.obj \
+ $O\Delta.obj \
$O\Lzma2Dec.obj \
$O\LzmaDec.obj \
$O\Threads.obj \
diff --git a/CPP/7zip/Bundles/SFXSetup/resource.rc b/CPP/7zip/Bundles/SFXSetup/resource.rc
index 8819a2c8..47e1b762 100644
--- a/CPP/7zip/Bundles/SFXSetup/resource.rc
+++ b/CPP/7zip/Bundles/SFXSetup/resource.rc
@@ -1,4 +1,4 @@
-#include "../../../../C/7zVersion.rc"
+#include "../../MyVersionInfo.rc"
#include "resource.h"
MY_VERSION_INFO_APP("7z Setup SFX", "7zS.sfx")
diff --git a/CPP/7zip/Bundles/SFXWin/SFXWin.dsp b/CPP/7zip/Bundles/SFXWin/SFXWin.dsp
index 55dbe377..3e11881b 100644
--- a/CPP/7zip/Bundles/SFXWin/SFXWin.dsp
+++ b/CPP/7zip/Bundles/SFXWin/SFXWin.dsp
@@ -197,14 +197,6 @@ SOURCE=..\..\Archive\Common\CoderMixer2.h
# End Source File
# Begin Source File
-SOURCE=..\..\Archive\Common\CoderMixer2MT.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\Archive\Common\CoderMixer2MT.h
-# End Source File
-# Begin Source File
-
SOURCE=..\..\Archive\Common\CrossThreadProgress.cpp
# End Source File
# Begin Source File
@@ -257,7 +249,15 @@ SOURCE=..\..\Compress\BcjRegister.cpp
# End Source File
# Begin Source File
-SOURCE=..\..\Compress\BranchCoder.cpp
+SOURCE=..\..\Compress\BranchMisc.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Compress\BranchMisc.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\Compress\BranchRegister.cpp
# End Source File
# Begin Source File
@@ -269,6 +269,10 @@ SOURCE=..\..\Compress\CopyRegister.cpp
# End Source File
# Begin Source File
+SOURCE=..\..\Compress\DeltaFilter.cpp
+# End Source File
+# Begin Source File
+
SOURCE=..\..\Compress\Lzma2Decoder.cpp
# End Source File
# Begin Source File
@@ -509,6 +513,14 @@ SOURCE=..\..\UI\FileManager\FormatUtils.h
# End Source File
# Begin Source File
+SOURCE=..\..\UI\FileManager\PropertyName.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\UI\FileManager\PropertyName.h
+# End Source File
+# Begin Source File
+
SOURCE=..\..\UI\FileManager\SysIconUtils.cpp
# End Source File
# Begin Source File
@@ -858,6 +870,20 @@ SOURCE=..\..\..\..\C\Alloc.h
# End Source File
# Begin Source File
+SOURCE=..\..\..\..\C\Bcj2.c
+# SUBTRACT CPP /YX /Yc /Yu
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\C\Bcj2.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\C\Bra.c
+# SUBTRACT CPP /YX /Yc /Yu
+# End Source File
+# Begin Source File
+
SOURCE=..\..\..\..\C\Bra.h
# End Source File
# Begin Source File
@@ -867,11 +893,25 @@ SOURCE=..\..\..\..\C\Bra86.c
# End Source File
# Begin Source File
+SOURCE=..\..\..\..\C\BraIA64.c
+# SUBTRACT CPP /YX /Yc /Yu
+# End Source File
+# Begin Source File
+
SOURCE=..\..\..\..\C\CpuArch.c
# SUBTRACT CPP /YX /Yc /Yu
# End Source File
# Begin Source File
+SOURCE=..\..\..\..\C\Delta.c
+# SUBTRACT CPP /YX /Yc /Yu
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\..\C\Delta.h
+# End Source File
+# Begin Source File
+
SOURCE=..\..\..\..\C\Lzma2Dec.c
# SUBTRACT CPP /YX /Yc /Yu
# End Source File
diff --git a/CPP/7zip/Bundles/SFXWin/makefile b/CPP/7zip/Bundles/SFXWin/makefile
index d6e1de78..7f2a78c1 100644
--- a/CPP/7zip/Bundles/SFXWin/makefile
+++ b/CPP/7zip/Bundles/SFXWin/makefile
@@ -56,7 +56,6 @@ WIN_CTRL_OBJS = \
$O\InBuffer.obj \
$O\FilterCoder.obj \
$O\LimitedStreams.obj \
- $O\LockedStream.obj \
$O\OutBuffer.obj \
$O\ProgressUtils.obj \
$O\PropId.obj \
@@ -85,6 +84,7 @@ FM_OBJS = \
$O\OverwriteDialog.obj \
$O\PasswordDialog.obj \
$O\ProgressDialog2.obj \
+ $O\PropertyName.obj \
$O\SysIconUtils.obj \
AR_OBJS = \
@@ -92,7 +92,6 @@ AR_OBJS = \
AR_COMMON_OBJS = \
$O\CoderMixer2.obj \
- $O\CoderMixer2MT.obj \
$O\CrossThreadProgress.obj \
$O\ItemNameUtils.obj \
$O\MultiStream.obj \
@@ -107,13 +106,15 @@ AR_COMMON_OBJS = \
$O\7zRegister.obj \
COMPRESS_OBJS = \
- $O\BranchCoder.obj \
$O\Bcj2Coder.obj \
$O\Bcj2Register.obj \
$O\BcjCoder.obj \
$O\BcjRegister.obj \
+ $O\BranchMisc.obj \
+ $O\BranchRegister.obj \
$O\CopyCoder.obj \
$O\CopyRegister.obj \
+ $O\DeltaFilter.obj \
$O\Lzma2Decoder.obj \
$O\Lzma2Register.obj \
$O\LzmaDecoder.obj \
@@ -128,7 +129,11 @@ CRYPTO_OBJS = \
C_OBJS = \
$O\Alloc.obj \
+ $O\Bcj2.obj \
+ $O\Bra.obj \
$O\Bra86.obj \
+ $O\BraIA64.obj \
+ $O\Delta.obj \
$O\CpuArch.obj \
$O\Lzma2Dec.obj \
$O\LzmaDec.obj \
diff --git a/CPP/7zip/Bundles/SFXWin/resource.rc b/CPP/7zip/Bundles/SFXWin/resource.rc
index ccde0cb2..91292b2f 100644
--- a/CPP/7zip/Bundles/SFXWin/resource.rc
+++ b/CPP/7zip/Bundles/SFXWin/resource.rc
@@ -1,4 +1,4 @@
-#include "../../../../C/7zVersion.rc"
+#include "../../MyVersionInfo.rc"
#include "../../GuiCommon.rc"
#include "../../UI/GUI/ExtractDialogRes.h"
#include "../../UI/FileManager/PropertyNameRes.h"