Most of the steps done in developing a wrapper also need to be done when porting software. An ACD file is still required. The main differences are in writing the source code. The basic steps are the same:
Implement the C source code
Header documentation
Empty main()
function
Call to embInitPV
Variables to handle ACD data items
Calls to ajAcdGet*
to retrieve ACD values
Code to clean up the ACD variables
For a port there are significantly more things to consider. The main()
function will need rewriting to handle the ACD file processing as follows:
Add code to pick up application options from ACD file processing rather than processing them as in the original
Identify functions that read input from user and update the function calls
Replace the output functions with appropriate calls to the EMBOSS libraries (possibly)
You must identify any functions that read input from the user, then add code to pick up values from the ACD file instead of processing them as in the original. The output can be left in whatever format is produced by the original application. You might add code to use the output functions provided by the EMBOSS libraries.
Clearly it's necessary to carefully familiarise yourself with the third party source code. It might be necessary to make edits across multiple files. This is the main disadvantage to porting software.
The remaining sections illustrate the approach taken for the port ohmmalign.