Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Handle -i{system,quote} without space before path #36

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

dobo90
Copy link

@dobo90 dobo90 commented Sep 24, 2019

  • Although manual doesn't specify this it is allowed
    to pass -isystem or -iquote like this: -isystem/opt/lib

  • If space is present before path, keep the current logic.

  • Simple test (checked with gcc 9.1.0 and 5.3.0):

    mkdir -p /tmp/lib
    touch /tmp/lib/inc.h

    cat < test.c
    #include "inc.h"

    int main(void)
    {
    return 0;
    }
    EOF

    gcc -isystem/tmp/lib test.c -o test

* Although manual doesn't specify this it is allowed
  to pass -isystem or -iquote like this: -isystem/opt/lib
* If space is present before path, keep the current logic.
* Simple test (checked with gcc 9.1.0 and 5.3.0):

  mkdir -p /tmp/lib
  touch /tmp/lib/inc.h

  cat <<EOF > test.c
  #include "inc.h"

  int main(void)
  {
    return 0;
  }
  EOF

  gcc -isystem/tmp/lib test.c -o test
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant