Create Manifest and Data Definition files
Finally, you need to create a
manifest.xml file in the
Source folder. The
manifest.xml file should refer to the
feature.xml file you created earlier:
<?xml version="1.0" encoding="utf-8"?>
<Solution xmlns="http://schemas.microsoft.com/sharepoint/"
SolutionId="1FE5FC37-B901-4aa3-8CA0-F8A004CAD393" >
<FeatureManifests>
<FeatureManifest Location="DevXList\feature.xml"/>
</FeatureManifests>
</Solution>
Create a Data Definition File
The next step is to create a data definition file (
.ddf). This file contains the instructions required later by the
makecab.exe utility to create the cabinet (CAB) file. Here's the content:
.OPTION Explicit ; Generate errors
.Set DiskDirectory1="..\bin"
.Set CabinetNameTemplate="DevX.wsp"
manifest.xml
.Set DestinationDir="DevXList\ListTemplates"
DevXList\ListTemplates\DevXListManifest.xml ; specify cab file name
.Set DestinationDir="DevXList\Messages"
DevXList\Messages\schema.xml
.Set DestinationDir="DevXList"
DevXList\Feature.xml
Check out this link for a
basic explanation of the .ddf command syntax.
Creating the Solution File
 | |
| Figure 4. Generating a Solution Package: A Solution Package is simply a CAB file with a .wpf extension, so you can use the makecab.exe tool to create it. |
With all the prerequisites in place, you can now build the Solution Package file, which is simply a CAB file with a
.wsp extension that you can deploy. The.wsp file can contain one or more of the following resources:
- Assemblies
- Features
- Web Parts
- Web Pages
- Templates
The simplest way to create a CAB file is to use the
makecab.exe command line tool, passing the
.ddf file as an argument as shown in
Figure 4:
By default,
makecab.exe tool generates the output CAB file in the
Bin directory with the name
DevX.wsp.
Adding the Solution File
 | |
| Figure 5. Adding the Solution Package: Add the Solution Package using stsadm with the -addsolution option, passing it the name of the .wsp file. |
You need to add the Solution file to SharePoint Server using the
stsadm tool, which you'll find in the following folder:
C:\Program Files\Common Files\Microsoft Shared\
web server extensions\12\BIN
| Author's Note: The stsadmtool is easier to use if you add its path to your %PATH% system variable using the Windows path command. |
Finally, use
stsadm to add the solution file as shown in
Figure 5.