I have a few questions.
First, I'm doing C ++ as a hobby. I'm using Qt for the time being, but this time (maybe) I don't have that much, so I'll omit it.
It is 7-Zip32.dll that is DL, but it is "7-ZIP32.DLL Version 9.22.00.02". (Note: Q3 has been written and removed because I don't understand its meaning.Q1, Q2 only.)
[Prerequisites]: Operate ZIP files that have been edited (added, deleted, etc.) with 7-Zip32.dll (hereinafter 7Z), compressed files that are supported by 7Z, etc.
Q1. Is it possible to read without decompression?
For example, in the range examined, Java jar files are actually zip files.
If possible, I put it in the same directory or subdirectory as the executable file, for example as installdata.zip,
It feels like reading as an ordinary binary file (* .bin etc.) or text file
Is it going to expand in memory? Is there a way to read the data without decompressing it?
Temporarily decompress->Delete them just before exiting (when exiting from main function etc.) ...
Although it is okay, this method can be used when a close command (message) is skipped when using the GUI.
In case of CUI such as batch processing etc., if it is interrupted for any reason, the decompressed file remains.
You have to delete it yourself.
Is there a way to use this "without decompressing" like a jar file in Java?
Eventually it will be extracted from the zip file, so it should have been decompressed,
I couldn't think of the name, so I decided to "Don't unzip".
Is it unpacked to a temporary folder such as Windows? ...
Q2. Is it possible to change the icon of the self-extracting archive created with 7Z?
I know it can be set in a shortcut file (* .lnk),
I would like to do it if I can change the icon of the self-extracting archive itself.
If it's impossible, like something like a license display (like Q about Qt function?)
That's not a strong request.
Q3. I used 7z.sfx in the self-extracting archive, but when I look at the "-sfx" in the included 7-zipCMD.txt
There seems to be a "configuration file".
It seems that you can specify the window title and location (directory) for decompression.
But I'm not sure how to use it. (Once generated, the self-extracting archive is generated as it is. (Neither the zip file nor the 7z file mediates.)
(Is it a zip file if mediating?) For example, as a command (as one of the arguments passed to the SevenZip function),
"a -sfx7z.sfx HELLO.EXE C: \\ test \\ cpp \\ file1.txt -dDEFINITION.txt" , -d<definition file path>or the definition file is placed in the same directory as the executable file that operates sfx,
Put the definition file in the same directory as the self-extracting archive ...
I tried each, but none changed. (Leave as default.)
All you need is 7z.sfx, the name of the self-extracting archive, and the file (* .zip) to make the self-extracting archive? I thought I was writing, but could it mean that I had to set it to 7z?
Language: C ++ (C ++ 11)
OS: Windows 10
7-Zip32.dll version: 7-ZIP32.DLL Version 9.22.00.02
I read t_obara's correction request (?).
Oh, yes. I can't reproduce it completely because I'm writing from outside,
First of all, dynamic linking is used, and the function is in a state where the SevenZip function and the enumeration function group (such as FindFirst) can be used.
(Of course we have the necessary structures.)
If i look at the included 7-zipAPI.txt, the enumeration system is
- Open archive
- Read with FindFirst->Exit here if an error is returned
- Read one after another with while + FindNext
- Close archive
. So I get the size of the file (stored) between 3 and 4.
String command passed to SevenZip for decompression
I think it was
x archive [file to be decompressed] -o decompression destination
. (Because I'm on the go.)
I tried to search for "memory" as a keyword in "search" on the text editor side, but it seemed to be irrelevant to this time because of "memory during compression".
(Do you need more information? Because i am on the go, there is no problem file at hand ... orz)
I read lunatea's comment (request for correction).
I'm sorry, it seems that the writing was bad. What I wanted to say is not the 7-Zip32.dll license, but whether the icon can be rewritten. I mean.
I'm not familiar with sports, but if you're using football shoes like Adi * s, you can't hide the company's logo. Because of its role as an advertising tower.
For example, suppose I made and released a software to make SFX (self-extracting archive) using 7-Zip32.dll.
The generated SFX icon is a 7z one.
If this is the role of the advertising tower ... the icon should not be erased.
I wrote in that sense, but it wasn't written well. I'm sorry.
Answer # 1
A1. I think it means expanding to memory
I'm not an author, so I can only say that it's impossible as long as you read the manual.
If you are interested, there is a support bulletin board at 7-Zip32.dll author's site, so it is a good idea to listen there
By the way, I will explore how to use 7z.dll directly.
This is here and there is no decent documentation, so you need to read the source.
A2. If an icon is embedded in sfx, there is a possibility that it will be handled by rewriting resources
It's more common to do it with existing tools such as Resource Hacker than to do it with C ++
Answer # 2
The Java jar cannot be run alone. Java is reading and executing.
I don't know the details of the contents, but speaking roughly, Java reads the jar file (decompresses it internally) and executes it.
Q1. Is it possible to read without decompression?
Who does this process? The self-extracting file has an executable program at the top, which will decompress and execute the compressed data of the main unit.
What would you want to do if you were able to expand to memory with 7-Zip DLL? If you wanted to execute the expanded data, it would not be impossible, but now Windows requires considerable technical skills I think.
- about the meaning of c ++ (struct-like) code
- a quick question about c ++
- c ++ - about the argument types of the constructor
- c ++ - about shift operator (operater operator)
- c ++ - ask about openframeworks addon "ofxmidi"
- c ++ - about meaningless definitions in typedef
- about c ++ pair
- i have a question about type conversion (c ++)
- c ++ - about exclusion of child functions
- c ++ - about the sort program
- c ++ - about standard input in visual studio code
- c ++ - about exclusive processing using lock_guard
- about c ++ compilation with vs code for mac >> error
- c ++ - about #ifndef, #define, and #endif macros
- c ++ - about test case output
- c ++ - questions about qt5 slots
- c ++ - about the node deletion function of the tree structure editing program
- c ++ - about the problem of cumulative sum (atcoder abc-c)
- about the structure of functions in c ++ code
- c ++ - about the behavior of the program when inserting the first value into the binary search tree
- python 3x - typeerror: 'method' object is not subscriptable
- python - you may need to restart the kernel to use updated packages error
- xcode - pod install [!] no `podfile 'found in the project directory
- vuejs - [vuetify] unable to locate target [data-app] i want to unit test to avoid warning
- android studio - emulator: dsound: could not initialize about the error message directsoundcapture
- android studio - unresolved reference comes out in kotlin
- mysql startup failed [error] innodb: the innodb_system data file 'ibdata1' must be writable
- django - oserror: [winerror 123] the file name, directory name, or volume label syntax is incorrect : '<frozen importlib_boot
- python - importerror: cannot import name md5 error cannot be resolved