Take the 2-minute tour ×
SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. It's 100% free, no registration required.

I am trying to Create a ddf file for my custom list feature using tutorial given in this link

Create a wsp using ddf

but in this link there isn't enough Information like what is the directory structure + where in ddf file is it telling the destination of the items like.

OR can anyone find me a tutorial where I learn about the making this file with bit of explanation PLease.

share|improve this question

2 Answers 2

up vote 4 down vote accepted

If you're creating a custom list that means you have files like this:

  • feature.xml (to be put inside a subfolder of 12Hive\TEMPLATE\FEATURES)
  • elements.xml (to be put in same folder)
  • schema.xml (to be put in the subfolder of the above defined by Name in ListTemplate)

Your manifest.xml will be something like:

<?xml version="1.0"?>
<Solution SolutionId="eba06f3e-2f6b-4b4b-bb88-b7b6004f4a1a" xmlns="http://schemas.microsoft.com/sharepoint/">
  <FeatureManifests>
    <FeatureManifest Location="MyFeature\feature.xml" />
  </FeatureManifests>
</Solution>

The FeatureManifest specifies that this should go into 12Hive\TEMPLATE\FEATURES and it'll look for referenced files at the relative locations inside the cab file.

Your makecab.ddf will be something like:

;*** Diamond Directive File
; 
;
.OPTION EXPLICIT                    ; Generate errors on variable typos
;
.Set CabinetNameTemplate=test.wsp       ; The name of the WSP file
.set DiskDirectoryTemplate=CDROM    ; All cabinets go in a single directory
.Set CompressionType=MSZIP          ; 
.Set Cabinet=on                     ; 
.Set Compress=on                    ;
.Set DiskDirectory1=.               ; Use the specified directory for the output CAB file 
;
;*** Disable size limits for wsp (cab) files ;
;
.Set CabinetFileCountThreshold=0 
.Set FolderFileCountThreshold=0 
.Set FolderSizeThreshold=0 
.Set MaxCabinetSize=0 
.Set MaxDiskFileCount=0
.Set MaxDiskSize=0
;
;*** Files to zip                   ;
;
"C:\test\12\template\features\MyFeature\Elements.xml" "MyFeature\Elements.xml"
"C:\test\12\template\features\MyFeature\Feature.xml" "MyFeature\Feature.xml"
"C:\test\12\template\features\MyFeature\MyList\Schema.xml" "MyFeature\MyList\Schema.xml"
"C:\test\manifest.xml" "manifest.xml"

You should give your wsp another name in CabinetNameTemplate and down in the Files to zip section you should replace the first reference with the location of the files in your file system. The references can be relative to where you run makecab.

But as Dave writes you should use WSPBuilder instead of making these yourselves. If you put your files in a directory structure like the one I have used in my makecab.ddf then you can just run WSPBuilder in the c:\test directory and it'll look for files in the 12 folder and build the wsp file for you. If you want to see the manifest.xml and makecab.ddf then you can run WSPBuilder with the switches "-BuildDDF -CleanUp false"

share|improve this answer
    
+1 for both answering the ddf question AND the WSPBuilder tip. :-) –  Paul Lucas Mar 14 '12 at 22:56
    
Cheers Guys, I solved my problem yesterday, there was some problem with my feature.xml, which was cause of miss understanding, and details about it can be find here, sharepoint.stackexchange.com/questions/31548/… –  Muhammad Raja Mar 15 '12 at 8:40
    
THANK YOU!!!!!!!!!!!! How come this is the first place I've found that syntax to specify the folder to put them inside the CAB! here's my script: stackoverflow.com/questions/19411440/… –  Nacht Jul 10 at 5:17

Unless you have some specific reason for using ddf, like custom server\client ddf profiles, I would highly recommend you use a tool like WSP Builder instead. This tool makes the whole process a great deal easier.

share|improve this answer
    
Does WSPBuilder provides solution package files somehow ? as on our servers we need to deploy it as a solution package, i do have installed WSPBuilder package in my Visual studio, i just dont know, what the difference between creating a hand coded solution package (.wsp) then actually using WSPBuilder, Thanks for reply btw. –  Muhammad Raja Mar 14 '12 at 14:53
1  
It does create the WSP file which is the 'Solution Package' you need for server deployment. This article will probably answer a lot of your questions : rasor.wordpress.com/2008/10/12/wss-dev-quickstart If not, there are tons of blogs out there that go into a lot of depth into various aspects of the tool. –  Dave Wise Mar 14 '12 at 15:04
    
Thanks alot for searching this tutorial, actually as I said am looking for Custom List feature, not webpart and even if I look at the options it asks me to create a blank feature and do it from scratch, however i want to make a dummy Template custom list feature, so that when i want to create a new one, all i have to do is change the name of feature, GUID and the information about fields as required by me or other users, here is some details about the feature, sharepoint.stackexchange.com/questions/31548/… –  Muhammad Raja Mar 14 '12 at 15:10
    
currently i am following a msdn tutorial to create a wsp file using ddf but its too complicated and got a bug which is defined in that question. Cheers –  Muhammad Raja Mar 14 '12 at 15:10

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.