jimjulian
Posts: 49
Joined: Mon Apr 04, 2016 12:09 am

color.h in gcc

Wed Jun 15, 2016 8:43 pm

Hello,

I'm trying to compile a sun path calculation program for Raspberry Pi, raspbian jessie. When I make the attempt, gcc tells me there is no file named "color.h", Is there a color.h suitable for use in the raspbian jessie gcc environment?

Thank you
Jim J

swampdog
Posts: 221
Joined: Fri Dec 04, 2015 11:22 am

Re: color.h in gcc

Wed Jun 15, 2016 10:18 pm

Not enough info. You need to at least post a link to where the source code is. Chances are it is in there.

This is probably not what you want..

Code: Select all

sudo apt-file search "color.h" | egrep "/color\.h$"

jimjulian
Posts: 49
Joined: Mon Apr 04, 2016 12:09 am

Re: color.h in gcc

Thu Jun 16, 2016 11:42 am

The program is a python code called sunpath that uses a compiled binary called gensky.c. There is a binary that comes with the package but was compiled for Mac OsX. Icould possibly find a color.h for a Mac but I would have to rest by trial and error for compatibility.
I do not believe gcc has native color.h file.

jimjulian
Posts: 49
Joined: Mon Apr 04, 2016 12:09 am

Re: color.h in gcc

Thu Jun 16, 2016 11:50 am

I tried your code but got the following instead.

sudo: apt-file: command not found

User avatar
Paeryn
Posts: 2614
Joined: Wed Nov 23, 2011 1:10 am
Location: Sheffield, England

Re: color.h in gcc

Thu Jun 16, 2016 2:46 pm

From what searches I did, all references to gensky.c look like they took the code from part of radiance, there's quite a bit more to it than just gensky.c

https://github.com/NREL/Radiance/tree/master

gensky.c is in src/gen/
color.h is in src/common/

Other files from the main project are also needed to compile gensky.c (unless the version you have is modified in any way).
She who travels light — forgot something.

swampdog
Posts: 221
Joined: Fri Dec 04, 2015 11:22 am

Re: color.h in gcc

Thu Jun 16, 2016 8:21 pm

Ah, right! ;-)

In that case, this worked for me..

Code: Select all

$ mkdir foo && cd foo
$ git clone https://github.com/NREL/Radiance.git
$ cmake .
$ make
..there were a few warnings but everything built. Note that is "cmake[space][period]" above. I didn't install the project or test it but a subsequent..

Code: Select all

$ sudo make install
..should finish the job.

jimjulian
Posts: 49
Joined: Mon Apr 04, 2016 12:09 am

Re: color.h in gcc

Thu Jun 16, 2016 8:56 pm

Thanks, I worked with Radiance back in the day. I should be able to do this.

Thanks again.

Return to “C/C++”