--- ./src/Makefile.orig 2019-04-16 14:41:09.000000000 +0000 +++ ./src/Makefile 2019-05-07 01:09:58.583727894 +0000 @@ -60,7 +60,7 @@ # Try to auto-detect target OS. OS = $(shell uname) -USR = /usr +USR = $(PREFIX) LIB = lib BIN = bin INCLUDE = include @@ -146,9 +146,7 @@ endif ifdef NOSTRIP -STRIP = echo skip strip -else -STRIP = strip +STRIP = echo skip stripe endif ifndef QMAKE @@ -199,7 +197,7 @@ # Enable multi-threading support. PARALLEL_CFLAGS = -Dgmic_is_parallel ifneq ($(OS),Windows) -PARALLEL_LIBS = -lpthread +PARALLEL_LIBS = #-lpthread endif # Enable parallelization in CImg, using OpenMP. @@ -339,8 +337,8 @@ GMIC_CLI_CFLAGS = $(MANDATORY_CFLAGS) $(ABORT_CFLAGS) $(PARALLEL_CFLAGS) $(EIGEN_CFLAGS) $(FFTW_CFLAGS) $(CURL_CFLAGS) $(PNG_CFLAGS) $(JPEG_CFLAGS) $(TIFF_CFLAGS) GMIC_CLI_LIBS = $(MANDATORY_LIBS) $(PARALLEL_LIBS) $(EIGEN_LIBS) $(FFTW_LIBS) $(CURL_LIBS) $(PNG_LIBS) $(JPEG_LIBS) $(TIFF_LIBS) ifeq ($(OS),Unix) # Unix. -GMIC_CLI_CFLAGS += $(OPENMP_CFLAGS) $(X11_CFLAGS) $(OPENEXR_CFLAGS) $(OPENCV_CFLAGS) # $(XSHM_CFLAGS) $(MAGICK_CFLAGS) -GMIC_CLI_LIBS += $(OPENMP_LIBS) $(X11_LIBS) $(OPENEXR_LIBS) $(OPENCV_LIBS) # $(XSHM_LIBS) # $(MAGICK_LIBS) +GMIC_CLI_CFLAGS += $(MAGICK_CFLAGS) # $(OPENMP_CFLAGS) $(X11_CFLAGS) $(OPENEXR_CFLAGS) $(OPENCV_CFLAGS) # $(XSHM_CFLAGS) $(MAGICK_CFLAGS) +GMIC_CLI_LIBS += $(MAGICK_LIBS) # $(OPENMP_LIBS) $(X11_LIBS) $(OPENEXR_LIBS) $(OPENCV_LIBS) # $(XSHM_LIBS) # $(MAGICK_LIBS) else ifeq ($(OS),Darwin) # MacOSX. GMIC_CLI_CFLAGS += $(X11_CFLAGS) $(OPENEXR_CFLAGS) $(OPENCV_CFLAGS) @@ -352,15 +350,14 @@ endif cli: - $(MAKE) "CFLAGS+=$(GMIC_CLI_CFLAGS) $(OPT_CFLAGS)" "LIBS+=$(GMIC_CLI_LIBS)" _cli - $(STRIP) gmic$(EXE) + $(MAKE) "CFLAGS+= $(CXXFLAGS) $(GMIC_CLI_CFLAGS) $(OPT_CFLAGS)" "LIBS+=$(GMIC_CLI_LIBS)" _cli debug: $(MAKE) "CFLAGS+=$(GMIC_CLI_CFLAGS) $(DEBUG_CFLAGS)" "LIBS+=$(GMIC_CLI_LIBS)" _cli _cli: check_versions gmic.cpp gmic.h gmic_stdlib.h CImg.h $(CXX) -o gmic_cli.o -c gmic.cpp $(CFLAGS) - $(CXX) -o gmic gmic_cli.cpp gmic_cli.o $(CFLAGS) $(LIBS) + $(CXX) -o gmic gmic_cli.cpp gmic_cli.o $(CFLAGS) $(LIBS) $(LDFLAGS) # CLI (static) #-------------