Author Topic: TIGCC include issue  (Read 5591 times)

0 Members and 1 Guest are viewing this topic.

Offline Jonson26

  • LV4 Regular (Next: 200)
  • ****
  • Posts: 118
  • Rating: +1/-0
  • Follow cat! Do what cat! Into tree! Now!
    • View Profile
TIGCC include issue
« on: December 08, 2017, 05:24:16 pm »
So, after a while of testing it seems to me as if my tigcc was unable to locate any files outside of the main file. In other words: i do #include <file>, compiler does: Error :file "file" not found. :(
Does anyone have an idea on how to fix this problem?
P.S.: Here's my path:
Spoiler For Spoiler:
"%GTK_BASEPATH%\bin;C:\ProgramData\Oracle\Java\javapath;%SystemRoot%\system32;%SystemRoot%;%SystemRoot%\System32\Wbem;%SYSTEMROOT%\System32\WindowsPowerShell\v1.0\;C:\Program Files\Java\jdk1.8.0_144\bin;C:\Program Files\Java\jre1.8.0_144\bin;..;.;C:\Program Files\Skype\Phone\;C:\Program Files\TIGCC"
. I'm running Win7 Pro 32bit.

Offline TravisE

  • LV4 Regular (Next: 200)
  • ****
  • Posts: 182
  • Rating: +33/-0
    • View Profile
    • ticalc.org
Re: TIGCC include issue
« Reply #1 on: December 10, 2017, 06:10:39 pm »
Are you trying to include a library header or a header file that you created as part of your project? There are two types of syntax for #include: “#include <file>” and “#include "file"”. The former should only be used for system library includes. For your own project headers, you should replace the angle brackets (< >) with double quotes (").
ticalc.org staff member—http://www.ticalc.org/

Offline Jonson26

  • LV4 Regular (Next: 200)
  • ****
  • Posts: 118
  • Rating: +1/-0
  • Follow cat! Do what cat! Into tree! Now!
    • View Profile
Re: TIGCC include issue
« Reply #2 on: December 11, 2017, 09:42:36 am »
It's a header for my own project, and you were right i did use <>. But, guess what? It still doesn't work! I'm pretty sure, that it's something with my path variable, since when i placed the absolute path into the include statement it compiled properly. Maybe i'll try it on my winxp machine...

Offline TravisE

  • LV4 Regular (Next: 200)
  • ****
  • Posts: 182
  • Rating: +33/-0
    • View Profile
    • ticalc.org
Re: TIGCC include issue
« Reply #3 on: December 11, 2017, 01:17:39 pm »
Weird, I don't recall messing with PATH ever being necessary. If you're using the IDE, did you properly add all the files to your project using the GUI? (It's been a while, but I think I remember there being a left sidebar that lists all the files in the project and a toolbar button to add them.)
ticalc.org staff member—http://www.ticalc.org/

Offline Jonson26

  • LV4 Regular (Next: 200)
  • ****
  • Posts: 118
  • Rating: +1/-0
  • Follow cat! Do what cat! Into tree! Now!
    • View Profile
Re: TIGCC include issue
« Reply #4 on: December 14, 2017, 07:57:54 am »
The IDE sees the files (they're listed on the sidebar, yes). It's the compiler, that tells me, that the files are missing.