6

7-zip 22.00 – APFS, Posix TAR, high precision timestamps

 1 year ago
source link: https://sourceforge.net/p/sevenzip/discussion/45797/thread/9c2d9061ce/
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.

7-Zip 22.00

  • 7-Zip 22.00 was released.

    Download

    7-Zip for 64-bit Windows x64:
    https://7-zip.org/a/7z2200-x64.exe

    7-Zip for 32-bit Windows x86:
    https://7-zip.org/a/7z2200.exe

    7-Zip for 64-bit Windows ARM64:
    https://7-zip.org/a/7z2200-arm64.exe

    What's new after 7-Zip 21.07:

    • 7-Zip now can extract APFS (Apple File System) images that can be used in DMG files.
    • 7-Zip now can create TAR archives in POSIX (pax) tar format with the switches
      -ttar -mm=pax or -ttar -mm=posix
    • 7-Zip now can store additional file timestamps with high precision (1 ns in Linux) in tar/pax archives with the following switches:
      -ttar -mm=pax -mtp=3 -mtc -mta
    • New switches for Linux version for TAR archives:
      -snoi : store owner/group ids in archive or set owner/group ids from archive to extracted files.
      -snon : store owner/group names in archive
    • New -snz switch to propagate Zone.Identifier stream to extracted files (Windows).
    • New option "Propagate Zone.Id stream" in Tools/Options/7-Zip menu.
    • New "Options" window in "Add to archive" allows to select what metadata must be included to archive. Also it allows to select new option
      "Do not change source files last access time".
    • Some bugs were fixed.
     
    👍
  • The same issue with GCC 12 occurs:

    ../C/LzmaEnc.c: In function ‘LzmaEnc_CodeOneMemBlock’:
    ../C/LzmaEnc.c:2996:19: error: storing the address of local variable ‘outStream’ in ‘p_16->rc.outStream’ [-Werror=dangling-pointer=]
    2996 |   p->rc.outStream = &outStream.vt;
    |   ~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~
    ../C/LzmaEnc.c:2979:28: note: ‘outStream’ declared here
    2979 |   CLzmaEnc_SeqOutStreamBuf outStream;
    |                            ^~~~~~~~~
    ../C/LzmaEnc.c:2979:28: note: ‘pp_15(D)’ declared here
    

    One needs this patch to address it:

    --- a/C/LzmaEnc.c   2021-11-18 19:00:00.000000000 +0100
    +++ b/C/LzmaEnc.c   2022-05-12 20:59:51.038852048 +0200
    @@ -2993,12 +2993,13 @@
    
       nowPos64 = p->nowPos64;
       RangeEnc_Init(&p->rc);
    -  p->rc.outStream = &outStream.vt;
    
       if (desiredPackSize == 0)
         return SZ_ERROR_OUTPUT_EOF;
    
    +  p->rc.outStream = &outStream.vt;
       res = LzmaEnc_CodeOneBlock(p, desiredPackSize, *unpackSize);
    +  p->rc.outStream = NULL;
    
       *unpackSize = (UInt32)(p->nowPos64 - nowPos64);
       *destLen -= outStream.rem;
    

     

  • teoberi - 3 days ago

    gcc-12.1.0

    cd CPP/7zip/Bundles/Alone2/
    make -f ../../cmpl_gcc_x64.mak
    

    In file included from ../../Archive/Chm/ChmIn.cpp:14:
    In copy constructor ‘NArchive::NChm::CLzxInfo::CLzxInfo(const NArchive::NChm::CLzxInfo&)’,
    inlined from ‘NArchive::NChm::CMethodInfo::CMethodInfo(const NArchive::NChm::CMethodInfo&)’ at ../../Archive/Chm/ChmIn.h:161:8,
    inlined from ‘unsigned int CObjectVector<t>::AddInReserved(const T&) [with T = NArchive::NChm::CMethodInfo]’ at ../../Archive/Chm/../../../Common/MyVector.h:515:29,
    inlined from ‘unsigned int CObjectVector<t>::Add(const T&) [with T = NArchive::NChm::CMethodInfo]’ at ../../Archive/Chm/../../../Common/MyVector.h:510:25,
    inlined from ‘LONG NArchive::NChm::CInArchive::OpenHighLevel(IInStream, NArchive::NChm::CFilesDatabase&)’ at ../../Archive/Chm/ChmIn.cpp:760:26:
    ../../Archive/Chm/ChmIn.h:116:8: error: ‘method.NArchive::NChm::CMethodInfo::LzxInfo.NArchive::NChm::CLzxInfo::WindowSizeBits’ may be used uninitialized [-Werror=maybe-uninitialized]
    116 | struct CLzxInfo
    | ^~~~~~~~
    ../../Archive/Chm/ChmIn.cpp: In member function ‘LONG NArchive::NChm::CInArchive::OpenHighLevel(IInStream
    , NArchive::NChm::CFilesDatabase&)’:
    ../../Archive/Chm/ChmIn.cpp:758:19: note: ‘method’ declared here
    758 | CMethodInfo method;
    | ^~~~~~
    cc1plus: all warnings being treated as errors
    make: *** [../../7zip_gcc.mak:528: b/g_x64/ChmIn.o] Error 1</t></t>

     

  • teoberi - 3 days ago

    @post-factum

    The workaround with -Wp,-U_FORTIFY_SOURCE doesn't seem to work for me any more, so if there are better ideas on how to enable RELRO and make checksec happy — let me know.

    Remove -Wp,-U_FORTIFY_SOURCE to make RELRO work.
    Now checksec is very happy.

    checksec --file=b/g_x64/7zz
    

    RELRO STACK CANARY NX PIE RPATH RUNPATH Symbols FORTIFY Fortified Fortifiable FILE
    Full RELRO Canary found NX enabled PIE enabled No RPATH No RUNPATH No Symbols Yes 6 16 b/g_x64/7zz

     


Log in to post a comment.


About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK