Search code examples
vxworks

How to version a VxWorks Workbench Project


I am attempting to stand up a VxWorks Workbench version 4.5.2 project into a CM system but am running into issues. I have just started learning VxWorks Workbench. I have searched a bit on how others have done this and I came across two solutions:

  1. Make the project path relative in a sub-directory in the WindRiver home directory.
  2. Do not version Workbench project files and just version my source code. Every client must re-create the Workbench project on their local machine.

The first solution would be ok but I have not been able to make it work. There seems to be some registry (Windows 10) or some path stored elsewhere for Workbench related workspace locations but the end result is the project is not loaded.

The second solution would be a last resort that I would prefer not to do as there are many steps to re-creating a project on a local machine making it tedious and error prone. Does anyone have experience versioning Workbench 4 projects into CM and can share possible solutions?


Solution

  • This can be complicated, and it very much depends on what project type you are talking about.

    For DKMs, RTPs, Static and Shared Library projects, you need to version these project files:

    • .wrproject
    • .wrmakefile
    • .cproject
    • .project

    Other project types will have these, but also some additional files that are required to recreate the project, for instance VIP projects also have a <projectname>.wpj file. A conclusive list is too long for this answer however.

    You do not need to version the automatically generated Makefile , nor do you need to version the automatically generated build subfolders.

    My advice is to store the projects along side your code. I personally prefer to store my projects outside of my workspace, and they should certainly not be stored anywhere in your Windriver installation folder.

    I tend to use a structure like this:

    • c:\gitrepositorys\CuriousCamel\Source\
      • dkmProject1
        • .wrproject
        • .project
        • .wrmakefile
        • .cproject
        • dkm.c
      • dkmProject2
      • dkmProject3
      • vipProject

    etc.

    The above are all versioned. In terms of the actual Workbench Workspace, I tend to create it in c:\gitrepositorys\CuriousCamel\Workspace and this is explicitly not versioned - I create it fresh for each clone, and often delete and recreate when I switch branch.

    Existing projects can be imported into the workspace using the import wizard (using the General->Existing Projects from Filesystem option). When you create a new project, just make sure you choose the "Create Project in external location" option, and select wherever you have chosen to store projects.