- DCamProf source (1.0.6 is the latest)
- Clang compiler with openmp support
- little-cms2
- libtiff
Under macOS with XCode installed typically the compiler picked up is the one shipped with XCode. It does not support openmp:
$ make
gcc -o dcamprof.o -c -I. -Wall -std=c99 -g -O2 -D_XOPEN_SOURCE=600 -D__EXTENSIONS__ -fopenmp -DDCAMPROF_VERSION=\"1.0.6\" dcamprof.c
clang: error: unsupported option '-fopenmp'
make: *** [dcamprof.o] Error 1
Use a brew-installed gcc. Figure out which version is installed:
$ brew list gcc
...
/usr/local/Cellar/gcc/11.3.0/bin/gcc-11
...
Open the DCamProf Makefile and modify the CC
variable:
CC= gcc-11
Install LittleCMS 2 if not installed yet, figure out its location:
$ brew info little-cms2
...
/usr/local/Cellar/little-cms2/2.13.1 (21 files, 1.3MB) *
...
Similarly, make sure libtiff is installed, figure out its location:
$ brew info libtiff
...
/usr/local/Cellar/libtiff/4.3.0 (249 files, 4.4MB) *
...
Update DCamProf Makefile to point out to the Include and Lib paths of either:
...
INCLUDE = -I. -I/usr/local/Cellar/little-cms2/2.13.1/include -I/usr/local/Cellar/libtiff/4.3.0/include
...
$(CC) -o $@ $(LDFLAGS) $(DCAMPROF_OBJS) -L /usr/local/Cellar/little-cms2/2.13.1/lib -llcms2 -L/usr/local/Cellar/libtiff/4.3.0/lib -ltiff -lm
...
Compile DCamProf:
$ make
Run DCamProf:
$ ./dcamprof -v
Program version: 1.0.6