How to let the visual GDB find the -DCMAKE_INCLUDE_PATH first?

Sysprogs forums Forums VisualGDB How to let the visual GDB find the -DCMAKE_INCLUDE_PATH first?

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #25023
    portsip
    Participant

    How to let the visual GDB find the header files and library files in -DCMAKE_INCLUDE_PATH and -DCMAKE_LIBRARY first then /usr ?

     

     

    #25024
    support
    Keymaster

    Hi,

    Normally, GCC would handle the system include directories automatically, so VisualGDB does not offer any special settings for overriding this.

    You could try adding the -nostdinc option to CFLAGS and then entering all include directories (system and regular) in the order you are trying to use, however we would advise against this, as such setup would be very fragile and could stop working if the internal directory structure of the toolchain changes in the next GCC version.

    #25031
    portsip
    Participant

    In fact if I perform the cmake command line from linux, it’s search the library in the -DCMAKE_LIBRARY first,

    but if perform from visualgdb, it’s search the /usr/lib64 before -DCMAKE_LIBRARY

    #25032
    support
    Keymaster

    Please let us know how exactly you observe the difference in the behavior (see the 3-step description format). This should help us understand what is going on and suggest steps to fix it.

Viewing 4 posts - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.