To build a library project, follow the steps listed below:
- Select the desired project in the CodeWarrior Projects view.
The Properties for <Project_name> dialog box appears.
- Select Tool Chain Editor from the left panel.
The Tool Chain Editor options page appears in the right panel.
- Click the Select Tools button.
The Select tools dialog box appears.
- Replace Linker with Libmaker in Select tools dialog box.
Note: For CodeWarrior for Microcontrollers v10.2, replace S08 Linker with S08Libmaker in the Select tools dialog box.
- Click OK.
The Tools settings dialog box closes.
- Select Settings from the left panel.
The Settings options page appears in the right panel.
- Click the Build Artifact tab.
- Change the Artifact extension to the desired extension (e.g. 'lib').
- Click Apply to save the settings.
- Click OK.
The Properties for <Project_name> dialog box closes.
- Right-click the project in the CodeWarrior Projects view and select Clean Project from the context-menu.
This removes the previous build artifact.
- Remove the start08.c file from the project.
- Change the libmaker command as listed below:
- Change from: ${COMMAND} ${FLAGS} ${OUTPUT_FLAG} -cmd( ${INPUTS} = ${OUTPUT})
- To: ${COMMAND} ${FLAGS} ${OUTPUT_FLAG} -cmd( ${INPUTS} = myLib.lib)
An alternate and easier way to build a library project is, while creating a new project using the New BareBoard Project wizard, select Library in the Project Type/Output option in the Devices page.