“-fpermissive” and “include ” dont work in linux c compiler

ShiraOzeri 07/30/2017. 1 answers, 44 views
android android c linux jenkins android-ndk android-ndk

I using Jenkins to Integretion a big project.

When i build the project in jenkins on windows meachine, the build successful.

But, when i build the same project in jenkins on linux meachine, the build failed.

I get a lot of error, like this:

 cc1: warning: command line option '-fpermissive' is valid for C++/ObjC++ but not for C

and problem with the name of the file:

  In file included from /var/lib/jenkins/workspace/mt-android-sdk-new/library/src/main/cpp/iprs_audio/iprs_audio_funcs.h:10:0,
                   from /var/lib/jenkins/workspace/mt-android-sdk-new/library/src/main/cpp/iprs_audio/iprs_audio_funcs.c:7:
  /var/lib/jenkins/workspace/mt-android-sdk-new/library/src/main/cpp/./iprs_audio/iprs_audio.h:15:40: fatal error: iprs_audio/iprs_audio_defs.h: No such file or directory
   #include <iprs_audio/iprs_audio_defs.h>
                                          ^

The name of the file is: Iprs_audio_defs.h (capital letter)

In windows the difference between letters doesnt matter, but in linux I got this error. I can't rename the files because this is a big project and my responsibility is just Jenkins

Any help?

4 Comments
Downvoter 07/30/2017
"In windows the difference between letters doesnt matter" The difference between which letters exactly? Also, what are your compilers on Windows and Linux, respectively?
Michael 07/30/2017
"I can't rename the files because this is a big project and my responsibility is just Jenkins" So tell the developers to fix it.
ShiraOzeri 07/30/2017
thanks a lot for the answer! @Downvoter I check this in my linux(centOS) and my compiler is: gcc (GCC) 4.8.5 20150623 (Red Hat 4.8.5-11) .but in windows i dont know what is my compiler. i check answer for this but didnt found.. the project on Android Studio with a c file, but i also have visual studio 2015 on my coputer. Sorry for the confusion..
Jonathan Leffler 07/30/2017
Windows has a case-insensitive file system (so does macOS); Linux has a case-sensitive file system. You have to spell the path for the header accurately on Linux whereas you can be sloppy on Windows.

1 Answers


Dan Albert 08/10/2017.

I can't rename the files because this is a big project and my responsibility is just Jenkins

Unfortunately this is the only option. Linux is case-sensitive.

4 comments
ShiraOzeri 08/30/2017
Thanks, are there any more differences? Maybe with NULL? I fixed the letters ... but it still runs only on Windows and not on Linux
Dan Albert 08/30/2017
NULL is not a file. C/C++ are already case sensitive. Case sensitivity of filenames is the difference.
ShiraOzeri 08/31/2017
But, even after I have corrected the case sensitive, the build falls. even that when I build the same project on Windows machine, it's successful. But with the Linux machine(centOS) failed.) .The code is compiled, then starts running the tests from the project and then falls. the error: Test failed to run to completion. Reason: 'Instrumentation run failed due to 'java.lang.IllegalArgumentException'
Dan Albert 08/31/2017
Sounds like a different issue, and one that isn't NDK related. You'll probably want to ask a new question for that issue, but a quick google search for that error finds: stackoverflow.com/questions/22085760/…

HighResolutionMusic.com - Download Hi-Res Songs

1 (G)I-DLE

POP/STARS flac

(G)I-DLE. 2018. Writer: Riot Music Team;Harloe.
2 The Chainsmokers

Beach House flac

The Chainsmokers. 2018. Writer: Andrew Taggart.
3 Ariana Grande

​Thank U, Next flac

Ariana Grande. 2018. Writer: Crazy Mike;Scootie;Victoria Monét;Tayla Parx;TBHits;Ariana Grande.
4 Nicki Minaj

No Candle No Light flac

Nicki Minaj. 2018. Writer: Denisia “Blu June” Andrews;Kathryn Ostenberg;Brittany "Chi" Coney;Brian Lee;TJ Routon;Tushar Apte;ZAYN;Nicki Minaj.
5 Clean Bandit

Baby flac

Clean Bandit. 2018. Writer: Jack Patterson;Kamille;Jason Evigan;Matthew Knott;Marina;Luis Fonsi.
6 Imagine Dragons

Bad Liar flac

Imagine Dragons. 2018. Writer: Jorgen Odegard;Daniel Platzman;Ben McKee;Wayne Sermon;Aja Volkman;Dan Reynolds.
7 Halsey

Without Me flac

Halsey. 2018. Writer: Halsey;Delacey;Louis Bell;Amy Allen;Justin Timberlake;Timbaland;Scott Storch.
8 BTS

Waste It On Me flac

BTS. 2018. Writer: Steve Aoki;Jeff Halavacs;Ryan Ogren;Michael Gazzo;Nate Cyphert;Sean Foreman;RM.
9 BlackPink

Kiss And Make Up flac

BlackPink. 2018. Writer: Soke;Kny Factory;Billboard;Chelcee Grimes;Teddy Park;Marc Vincent;Dua Lipa.
10 Fitz And The Tantrums

HandClap flac

Fitz And The Tantrums. 2017. Writer: Fitz And The Tantrums;Eric Frederic;Sam Hollander.
11 Backstreet Boys

Chances flac

Backstreet Boys. 2018.
12 Kelly Clarkson

Never Enough flac

Kelly Clarkson. 2018. Writer: Benj Pasek;Justin Paul.
13 Diplo

Close To Me flac

Diplo. 2018. Writer: Ellie Goulding;Savan Kotecha;Peter Svensson;Ilya;Swae Lee;Diplo.
14 Anne-Marie

Rewrite The Stars flac

Anne-Marie. 2018. Writer: Benj Pasek;Justin Paul.
15 Little Mix

Woman Like Me flac

Little Mix. 2018. Writer: Nicki Minaj;Steve Mac;Ed Sheeran;Jess Glynne.
16 Imagine Dragons

Machine flac

Imagine Dragons. 2018. Writer: Wayne Sermon;Daniel Platzman;Dan Reynolds;Ben McKee;Alex Da Kid.
17 Little Mix

The Cure flac

Little Mix. 2018.
18 Bradley Cooper

Always Remember Us This Way flac

Bradley Cooper. 2018. Writer: Lady Gaga;Dave Cobb.
19 Rita Ora

Velvet Rope flac

Rita Ora. 2018.
20 Lady Gaga

I'll Never Love Again flac

Lady Gaga. 2018. Writer: Benjamin Rice;Lady Gaga.

Related questions

Hot questions

Language

Popular Tags