Build Project on Linux

Sysprogs forums Forums VisualGDB Build Project on Linux

This topic contains 5 replies, has 2 voices, and was last updated by  support 5 months, 1 week ago.

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #31892

    mcd
    Participant

    Hello

    We have a Linux VisualGDB project which is build with crosscompile on Windows successfully.

    To easier integrate into our CI/CD it is requested to build the project directly on a Linux machine.
    (Clone diretly to the Linux Box and build the project)

    How can this get done? Digged around but did not get any idea how to do it.

     

    #31893

    support
    Keymaster

    Hi,

    This is generally possible, although might require some adjustments and troubleshooting due to differences between Windows and Linux.

    If you could let us know the build system you are using (GNU Make, CMake or MSBuild), we can point you to the right direction.

    Please also let us know the email address associated with your license key (or update the forum profile accordingly), so that we could link your support profile to the forum profile.

    #31895

    mcd
    Participant

    Hi

    Thank you for the reply. Glad to hear that there is a possibility!

    The project is a MSBuild project.

    How should i send you further information about the license i’ve?
    (I don’t want to share email or license information in the post)

    #31902

    support
    Keymaster

    Hi,

    No problem. You can simply send us your license key (or email address associated with it) and a link to this post via our support form and we will link them together.

    #31903

    mcd
    Participant

    Done. May i come back to the question and kindly ask for any hints.

    #31904

    support
    Keymaster

    Thanks for renewing your technical support.

    Locally-built MSBuild projects support generating batch files to build the projects outside Visual Studio (see this page for details). A batch file will contain a list of gcc/linker command lines referencing the response files (.rsp) that contain the actual GCC command lines. The response files are used to bypass the Windows command line length limitation.

    If you would like to build the same project on Linux, we would advise following the steps below:

    1. Enable the generation of batch files and make sure the generated batch file works on the Windows machine.
    2. Create a basic tool/script that will parse the batch file and replace Windows-specific paths with their Linux equivalents (don’t forget to convert CRLF line endings to LF and the ‘REM’ comments to ‘#’)
    3. Once the substitutions are performed, you can try running the updated script file on Linux. It will invoke gcc/linker with the same arguments that should result in a successful build. Once you confirm that it works manually, running it from the CI system should be straight-forward.

    Note that as Linux does not have a command line length limitation, you can expand the references to the .rsp files in-place, e.g.:

    where file.rsp contains

    can be expanded to just:

     

Viewing 6 posts - 1 through 6 (of 6 total)

You must be logged in to reply to this topic.