The purpose of this page is to provide usage answers for people writing CPMake build files.

How to perform XSL transformations

XSL transforms can be done using the Java Transformer class.  This class is part of the javax.xml.transform package.  Here is an example of a rule and method that uses the Transformer class to process an xml file with a style sheet:
make.createExplicitRule(tempdir+"/howto.html", new String[]
      }, "transform", true);
transform(String target, String[] prereqs)
   tf = TransformerFactory.newInstance();
   trans = tf.newTransformer(new StreamSource(new File(prereqs[1])));
   trans.transform(new StreamSource(new File(prereqs[0])), 
      new StreamResult(new File(target)));
In the above example the target is the output of the transformation.  prereqs[0] is the XML file to transform and prereqs[1] is the XSL style sheet.
One thing to make note of is that if the same style sheet is to be used to transform multiple documents it would be better to move the first two lines of the transform method out into global space.  Then the Transformer object can be used over and over again.

How to compile java code with CPMake

For this item please see the tutorial on writing a Java build file.

How to compile C/C++ code with CPMake

For this item please see the tutorial on writing a C++ build file.

How to update a project with CVS

This item is coming soon.

How to create a rule to FTP files

This item is coming soon.