永发信息网

用什么软件制作cab文件?

答案:1  悬赏:0  手机版
解决时间 2021-05-01 07:50
  • 提问者网友:流星是天使的眼泪
  • 2021-05-01 00:09
这些手机用的软件是怎么制作的,知道的人不防说一下,谢谢.
最佳答案
  • 五星知识达人网友:不如潦草
  • 2021-05-01 01:17
MakeCAB是微软提供的制作CAB的文件,详细的MakeCAB介绍请参考微软MSDN。
正好这几天做的一个WEB ActiveX SIP Phone需要打包成.CAB文件,于是稍微研究了一下MakeCAB的用法。
直接运行MakeCAB,系统给出命令用法如下:

C:Documents and SettingsSunDesktopwebsipp>makecab
Microsoft (R) Cabinet Maker - Version 5.1.2600.2180
Copyright (c) Microsoft Corporation. All rights reserved..
MAKECAB [/V[n]] [/D var=value ...] [/L dir] source [destination]
MAKECAB [/V[n]] [/D var=value ...] /F directive_file [...]
source File to compress.
destination File name to give compressed file. If omitted, the
last character of the source file name is replaced
with an underscore (_) and used as the destination.
/F directives A file with MakeCAB directives (may be repeated).
/D var=value Defines variable with specified value.
/L dir Location to place destination (default is current directory).
/V[n] Verbosity level (1..3).

如果目录里面有多个文件,那么就需要编写一个文件列表文件,用来告诉MakeCAB,有多少文件需要打包。
简单的编写了一个list.txt文件,里面仅仅包含2行。一个是libactivex.inf,一个libactivex.dll
然后执行:

makecab /F list.txt /D compressiontype=lzx /D compressionmemory=21 /V

系统将显示压缩过程和压缩结果,如下:

Microsoft (R) Cabinet Maker - Version 5.1.2600.2180
Copyright (c) Microsoft Corporation. All rights reserved..
287,395 bytes in 2 files
Total files: 2
Bytes before: 287,395
Bytes after: 162,170
After/Before: 56.43% compression
Time: 0.74 seconds ( 0 hr 0 min 0.74 sec)
Throughput: 378.76 Kb/second

压缩之后,目录下将生成一个目录,将目录里面的文件改名成libactivex.cab(可以是你需要的文件名)就OK了。

然后就可以放到WEB服务器的目录下,IE打开的时候就会提示下载了。


附:INF的生成方法将在以后介绍。

其实,还有2个办法生成CAB文件,一个就是利用Visual Studio,另外一个就是利用专门的打包工具,可以google一下。
===========
---
makecab.exe 的簡單用法

如果說makecab是指令行操作-----那麽iexpress就是gui操作了。

2.makecab批量压缩:---只好用間接的方法了, for %v in (*.*) do makecab %v
批量壓縮在同一個cab:



需要製作出一個列表,然後再來用 /f 來配合.
=====
=================
makecab 的使用方法详解与技巧 :
最简单的用法:
makecab 文件完整的名称 如 makecab wmd.dll
指定压缩类型及使用内存的大小:
makecab /d compressiontype=lzx /d compressionmemory=21 wmd.dll 压缩比高
批量压缩的办法:
for %v in (*.*) do makecab %v
之前俺研究了好久,都不知道怎么用一条命令将一个目录下的所有文件压缩成CAB包,现在终于知道了,呵
压缩成一个CAB包的办法:
type list.txt (生成一个文件列表)
makecab /f list.txt /d compressiontype=mszip /d compressionmemory=21 /d maxdisksize=1024000000 /d diskdirectorytemplate=dd* /d cabinetnametemplate=dd*.cab
来个高压缩比的。呵
makecab /f list.txt /d compressiontype=lzx /d compressionmemory=21 /d maxdisksize=1024000000 /d diskdirectorytemplate=dd* /d cabinetnametemplate=dd*.cab
这儿的list.txt里面是文件的列表,如果是相对路径那么要放到要压缩的文件夹中,如果是绝对路径就可以放到任何地方喽!

生成文件列表
1.这里假设文件夹为为D:\123。
2.以Windows XP操作系统为例,单击“开始|运行”,输入cmd,然后单击“确定”。
3.在命令提示符窗口中输入以下命令,dir d:\123 >c:\filelist.txt
这样就在C:盘根目录下生成了一个名为“filelist.txt”的文本文件,该文件中即包含文件夹D:\123 里面的所有文件的详细列表。
如果希望将D:盘中子目录中的文件和文件夹列表也全部列出来,可以在命令提示符窗口中输入以下命令。
dir d:\ /s >c:\filelist.txt
如果使用下面的命令,即加一个/b,则会生成一个简单的文件名列表,不包括其它信息,这种方法可能更加实用一些。
dir d:\ /s /b >c:\filelist.txt
我要举报
如以上回答内容为低俗、色情、不良、暴力、侵权、涉及违法等信息,可以点下面链接进行举报!
点此我要举报以上问答信息
大家都在看
推荐资讯