Skip to content

GitLab

  • Projects
  • Groups
  • Snippets
  • Help
    • Loading...
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
CMake
CMake
  • Project overview
    • Project overview
    • Details
    • Activity
    • Releases
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 3,195
    • Issues 3,195
    • List
    • Boards
    • Labels
    • Service Desk
    • Milestones
  • Merge Requests 15
    • Merge Requests 15
  • CI / CD
    • CI / CD
    • Pipelines
    • Jobs
    • Schedules
  • Operations
    • Operations
    • Incidents
    • Environments
  • Packages & Registries
    • Packages & Registries
    • Container Registry
  • Analytics
    • Analytics
    • CI / CD
    • Repository
    • Value Stream
  • External Wiki
    • External Wiki
  • Members
    • Members
  • Collapse sidebar
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
  • CMake
  • CMakeCMake
  • Issues
  • #17372

Closed
Open
Opened Oct 19, 2017 by fenugrec@fenugrec

CodeBlocks: Drive letter missing on Windows

On Windows, there is some minor inconsistency in treating a leading backspace '' character for the source path, when using the "CodeBlocks + minGW makefile" generator.

Example project structure:

d:\dev\builddir\   (empty; we run cmake + make from here)
d:\projects\srcdir\   (project source repo)

from the CLI, running d:\dev\builddir> cmake-gui \projects\srcdir will generate correct makefiles which work as intended, but a broken .cbp file that has relative paths for every source file, (in the .cbp XML, they are noted as <Unit filename="/projects/srcdir/....."> . These paths are then appended by CodeBlocks to the builddir absolute path. This of course results in an unusable .cbp project file where none of the source files can be located.

The obvious workaround is to instead use cmake-gui d:\projects\srcdir with the full absolute path, but I believe the first form is correct and should be treated as an absolute path, just as the windows CLI does.

I have a minimal test case uploaded here: https://gitlab.kitware.com/fenugrec/cmake_tests/tree/master/cbp_gen/orig_src

Edited Oct 25, 2017 by Brad King
To upload designs, you'll need to enable LFS and have admin enable hashed storage. More information
Assignee
Assign to
None
Milestone
None
Assign milestone
Time tracking
None
Due date
None
Reference: cmake/cmake#17372