MSFN Forum: [help] Problem with makecab directives - MSFN Forum

Jump to content



Unattended CD/DVD Guide Homepage · MSFN Forum Rules

If you have questions about customizing Windows XP that are nLite-specific, please post them in the nLite forum, not here. If you have questions regarding the unattended installation of Windows XP, please post them in the Unattended Windows 2000/XP/2003 section.
Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

[help] Problem with makecab directives Rate Topic: -----

#1 User is offline   Camarade_Tux 

  • MSFN Addict
  • PipPipPipPipPipPipPip
  • Group: Members
  • Posts: 1,760
  • Joined: 22-May 05

Posted 17 June 2006 - 10:47 AM

Hi everybody,

I'm trying to make a slipstreamer for Vista Icon Pack and I've nearly done it.

File are found, extracted, modified but I can't compress them.
I want to do that with makecab and directive file to avoid having 60 black boxes appearing and disappearing on my screen.

This is the beginning of my directive file:

.Set Compress=ON
.Set Cabinet=OFF
.Set CompressionType=LZX
.Set CompressionMemory=21
.Set SourceDir=d:\temp\WORK
.Set DiskDirectoryTemplate=D:\VIP
accwiz.exe
ahui.exe
appwiz.cpl
...


And I get this:
D:\Scratch\Download\VIPv2_SP>makecab /F d:\temp\work\directives.ddf
Microsoft (R) Cabinet Maker - Version 5.1.2600.0
Copyright (c) Microsoft Corporation. All rights reserved..

26,381,312 bytes in 58 files
  0.00% - accwiz.exe (1 of 58)
d:\temp\work\directives.ddf(10): ERROR: NOT IMPLEMENTED YET: compressing single
files: accwiz.exe
d:\temp\work\directives.ddf(10): ERROR: MakeCAB aborted.


If I change ".Set Cabinet=OFF" to ".Set Cabinet=ON", it works normally.
Does anyone know how I could get this to work ?


Thanks.


#2 User is offline   LLXX 

  • MSFN Junkie
  • PipPipPipPipPipPipPipPipPip
  • Group: Banned
  • Posts: 3,399
  • Joined: 04-December 05

Posted 17 June 2006 - 05:53 PM

Tried a different version of MakeCab?

#3 User is offline   Camarade_Tux 

  • MSFN Addict
  • PipPipPipPipPipPipPip
  • Group: Members
  • Posts: 1,760
  • Joined: 22-May 05

Posted 18 June 2006 - 01:42 AM

Same with makecab from cabsdk. :no:
But I may have an idea. Otherwise, it is possible I can achieve the same thing with "free" alternatives.

#4 User is offline   benners 

  • Senior Member
  • PipPipPipPip
  • Group: Members
  • Posts: 692
  • Joined: 29-December 03

Posted 18 June 2006 - 06:20 AM

You could use a program like RunHiddenconsole here or hstart, I use the first with no probs, just place it in the system32 or windows dir.

#5 User is offline   Camarade_Tux 

  • MSFN Addict
  • PipPipPipPipPipPipPip
  • Group: Members
  • Posts: 1,760
  • Joined: 22-May 05

Posted 18 June 2006 - 06:39 AM

Indeed, I'll check that if I can't manage with directives.

In fact directives are much more efficient. They require less time to complete since makecab doesn't have to be run again and again.

#6 User is offline   Delprat 

  • Poll: Why are you reading this ?
  • PipPipPip
  • Group: Members
  • Posts: 481
  • Joined: 18-May 05

Posted 18 June 2006 - 06:46 AM

[DELETED]

View PostCamarade_Tux, on Jun 18 2006, 01:39 PM, said:

In fact directives are much more efficient. They require less time to complete since makecab doesn't have to be run again and again.


Did you benchmarked that ?
I'm pretty sure that the executable remains in the disk cache between runs ?

This post has been edited by Delprat: 18 June 2006 - 07:36 AM


#7 User is offline   GreenMachine 

  • ineXPlicable
  • Group: Developers
  • Posts: 3,062
  • Joined: 22-August 03

Posted 19 June 2006 - 11:16 AM

Look for the simple answer ...

A directive file (or DDF, Diamond Directive FIle) is not intended to compress individual files. Your stated goal is not to see the DOS box flash. Simply direct MAKECAB output to NUL ... The following code compresses everything in DIR1 into DIR2 discretly:
FOR /F "USEBACKQ" %%I IN (`DIR /A-D /B DIR1\*.* 2^>NUL`) DO (
  MAKECAB /D CompressionMemory=21 /D CompressionType=LZX /L DIR2 DIR1\%%I > NUL
)

Or to see what is happening:
FOR /F "USEBACKQ" %%I IN (`DIR /A-D /B DIR1\*.* 2^>NUL`) DO (
  ECHO Compressing %%I
  MAKECAB /D CompressionMemory=21 /D CompressionType=LZX /L DIR2 DIR1\%%I > NUL
)


#8 User is offline   Camarade_Tux 

  • MSFN Addict
  • PipPipPipPipPipPipPip
  • Group: Members
  • Posts: 1,760
  • Joined: 22-May 05

Posted 19 June 2006 - 11:24 AM

Ok, I'll try that, then.

In fact, I thought this:
Posted Image

would also apply to multiple files.

(image from CABSDK)

This post has been edited by Camarade_Tux: 19 June 2006 - 11:24 AM


#9 User is offline   Delprat 

  • Poll: Why are you reading this ?
  • PipPipPip
  • Group: Members
  • Posts: 481
  • Joined: 18-May 05

Posted 19 June 2006 - 12:30 PM

I've searched in hfslip code and it uses DDFs only to create cabinets.
If you look in makecab.doc around your screenshot, you'll see example showing how to compress like you want : in each one there's at least one file not compressed :
.Set Compress=OFF
.Set Cabinet=OFF
setup.exe
setup.inf
.Set Compress=ON
.Set Cabinet=OFF
.Set CompressionType=LZX
.Set CompressionMemory=21
.Set SourceDir=d:\temp\WORK
.Set DiskDirectoryTemplate=D:\VIP
accwiz.exe
ahui.exe
appwiz.cpl
...


Also, hfslip uses DiskDirectory1 instead of DiskDirectoryTemplate, and no SourceDir but a relative path on each file.

++

Share this topic:


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users



All trademarks mentioned on this page are the property of their respective owners
Copyright © 2001 - 2011 msfn.org
Privacy Policy