echo '6.6.4 Q16 '
;;
--cflags)
- echo "-I${includedir} "
+ echo "-I${includedir} -fopenmp"
;;
--cxxflags)
- echo '-g -O2'
+ echo '-g -O2 -pthread'
;;
--cppflags)
echo '-I/usr/local/include/ImageMagick'
echo '-L/usr/local/lib '
;;
--libs)
- echo "-L${libdir} -lMagick++ -lMagickWand -lMagickCore -ltiff -lfreetype -ljasper -ljpeg -lpng -lfontconfig -lXext -lXt -lSM -lICE -lX11 -lbz2 -lxml2 -lz -lm -lgomp -lltdl"
+ echo "-L${libdir} -lMagick++ -lMagickWand -lMagickCore -ltiff -lfreetype -ljasper -ljpeg -lpng -lfontconfig -lXext -lXt -lSM -lICE -lX11 -lbz2 -lxml2 -lz -lm -lgomp -lpthread -lltdl"
;;
*)
echo "${usage}" 1>&2
# defaults for LIBS & INC & CCFLAGS params that we later pass to Writemakefile
my $INC_magick = '-I../ -I.. -I/usr/include/cairo -I/usr/include/pixman-1 -I/usr/include/freetype2 -I/usr/include/libpng12 -I/usr/include/freetype2 -I/usr/include/libxml2 -I"' . $Config{'usrinc'} . '/ImageMagick"';
my $LIBS_magick = '-L../magick/.libs -lMagickCore -lperl -lm';
-my $CCFLAGS_magick = "$Config{'ccflags'} -g -O2 -Wall";
+my $CCFLAGS_magick = "$Config{'ccflags'} -fopenmp -g -O2 -Wall -pthread";
my $LDFLAGS_magick = "-L../magick/.libs -lMagickCore $Config{'ldflags'} ";
my $LDDLFLAGS_magick = "-L../magick/.libs -lMagickCore $Config{'lddlflags'} ";
# 'OPTIMIZE' => '',
# Use same compiler as ImageMagick
- 'PERLMAINCC' => ' ',
+ 'PERLMAINCC' => ' -fopenmp',
# Set Perl installation prefix to ImageMagick installation prefix
# 'PREFIX' => '/usr/local',
/* Define to 1 if you have the ANSI C header files. */
#undef STDC_HEADERS
+/* Define if you have POSIX threads libraries and header files. */
+#undef THREAD_SUPPORT
+
/* Define if you have TIFF library */
#undef TIFF_DELEGATE
<configure name="LIB_VERSION" value="0x664"/>
<configure name="LIB_VERSION_NUMBER" value="6,6,4,6"/>
<configure name="RELEASE_DATE" value="2010-09-23"/>
- <configure name="CONFIGURE" value="./configure '--without-threads'"/>
+ <configure name="CONFIGURE" value="./configure "/>
<configure name="PREFIX" value="/usr/local"/>
<configure name="EXEC-PREFIX" value="/usr/local"/>
<configure name="VERSION" value="6.6.4"/>
<configure name="CC" value="gcc -std=gnu99 -std=gnu99"/>
- <configure name="CFLAGS" value="-g -O2 -Wall"/>
+ <configure name="CFLAGS" value="-fopenmp -g -O2 -Wall -pthread"/>
<configure name="CPPFLAGS" value="-I/usr/local/include/ImageMagick"/>
- <configure name="PCFLAGS" value=""/>
+ <configure name="PCFLAGS" value="-fopenmp"/>
<configure name="DEFS" value="-DHAVE_CONFIG_H"/>
<configure name="LDFLAGS" value="-L/usr/local/lib "/>
- <configure name="LIBS" value="-lMagickCore -ltiff -lfreetype -ljasper -ljpeg -lpng -lfontconfig -lXext -lXt -lSM -lICE -lX11 -lbz2 -lxml2 -lz -lm -lgomp -lltdl"/>
+ <configure name="LIBS" value="-lMagickCore -ltiff -lfreetype -ljasper -ljpeg -lpng -lfontconfig -lXext -lXt -lSM -lICE -lX11 -lbz2 -lxml2 -lz -lm -lgomp -lpthread -lltdl"/>
<configure name="CXX" value="g++"/>
- <configure name="CXXFLAGS" value="-g -O2"/>
+ <configure name="CXXFLAGS" value="-g -O2 -pthread"/>
<configure name="DISTCHECK_CONFIG_FLAGS" value="--disable-deprecated --with-quantum-depth=16 --with-umem=no --with-autotrace=no --with-gslib=no --with-fontpath= --with-perl=no"/>
<configure name="HOST" value="x86_64-unknown-linux-gnu"/>
- <configure name="FEATURES" value=""/>
+ <configure name="FEATURES" value="OpenMP "/>
<configure name="DELEGATES" value="bzlib fontconfig freetype jpeg jng jp2 png tiff x11 xml zlib"/>
<configure name="COPYRIGHT" value="Copyright (C) 1999-2010 ImageMagick Studio LLC"/>
<configure name="WEBSITE" value="http://www.imagemagick.org"/>
$as_echo "$as_me: WARNING: Replacing compiler $CXX with compiler $PTHREAD_CXX to support pthreads." >&2;}
CXX="$PTHREAD_CXX"
fi
+
+$as_echo "#define THREAD_SUPPORT 1" >>confdefs.h
+
fi
fi
# Enable support for threads
AC_ARG_WITH([threads],
- [AC_HELP_STRING([--without-threads],
- [disable threads support])],
+ [AC_HELP_STRING([--without-threads], [disable threads support])],
[with_threads=$withval],
[with_threads='yes'])
have_threads=no
if test "$with_threads" != 'no'; then
- AX_PTHREAD()
+ AX_PTHREAD([])
if test "$ax_pthread_ok" = yes; then
have_threads=yes
DEF_THREAD="$PTHREAD_CFLAGS"
AC_MSG_WARN([Replacing compiler $CXX with compiler $PTHREAD_CXX to support pthreads.])
CXX="$PTHREAD_CXX"
fi
+ AC_DEFINE(THREAD_SUPPORT,1,[Define if you have POSIX threads libraries and header files.])
fi
fi
LTCC="gcc -std=gnu99 -std=gnu99"
# LTCC compiler flags.
-LTCFLAGS="-g -O2 -Wall"
+LTCFLAGS="-fopenmp -g -O2 -Wall -pthread"
# Take the output of nm and produce a listing of raw symbols and C names.
global_symbol_pipe="sed -n -e 's/^.*[ ]\\([ABCDGIRSTW][ABCDGIRSTW]*\\)[ ][ ]*\\([_A-Za-z][_A-Za-z0-9]*\\)\$/\\1 \\2 \\2/p'"
# ### BEGIN LIBTOOL TAG CONFIG: CXX
# The linker used to build libraries.
-LD="/usr/bin/ld -m elf_x86_64"
+LD=""
# How to create reloadable object files.
reload_flag=" -r"
old_archive_cmds="\$AR \$AR_FLAGS \$oldlib\$oldobjs~\$RANLIB \$oldlib"
# A language specific compiler.
-CC="g++"
+CC=""
# Is the compiler the GNU compiler?
-with_gcc=yes
+with_gcc=
# Compiler flag to turn off builtin functions.
-no_builtin_flag=" -fno-builtin"
+no_builtin_flag=""
# How to pass a linker flag through the compiler.
-wl="-Wl,"
+wl=""
# Additional compiler flags for building library objects.
-pic_flag=" -fPIC -DPIC"
+pic_flag=""
# Compiler flag to prevent dynamic linking.
link_static_flag=""
# Does compiler simultaneously support -c and -o options?
-compiler_c_o="yes"
+compiler_c_o=""
# Whether or not to add -lc for building shared libraries.
build_libtool_need_lc=no
allow_libtool_libs_with_static_runtimes=no
# Compiler flag to allow reflexive dlopens.
-export_dynamic_flag_spec="\${wl}--export-dynamic"
+export_dynamic_flag_spec=""
# Compiler flag to generate shared objects directly from archives.
-whole_archive_flag_spec="\${wl}--whole-archive\$convenience \${wl}--no-whole-archive"
+whole_archive_flag_spec=""
# Whether the compiler copes with passing no objects directly.
compiler_needs_object="no"
old_archive_from_expsyms_cmds=""
# Commands used to build a shared archive.
-archive_cmds="\$CC -shared -nostdlib \$predep_objects \$libobjs \$deplibs \$postdep_objects \$compiler_flags \${wl}-soname \$wl\$soname -o \$lib"
-archive_expsym_cmds="\$CC -shared -nostdlib \$predep_objects \$libobjs \$deplibs \$postdep_objects \$compiler_flags \${wl}-soname \$wl\$soname \${wl}-retain-symbols-file \$wl\$export_symbols -o \$lib"
+archive_cmds=""
+archive_expsym_cmds=""
# Commands used to build a loadable module if different from building
# a shared archive.
module_expsym_cmds=""
# Whether we are building with GNU ld or not.
-with_gnu_ld="yes"
+with_gnu_ld=""
# Flag that allows shared libraries with undefined symbols to be built.
allow_undefined_flag=""
# Flag to hardcode $libdir into a binary during linking.
# This must work even if $libdir does not exist
-hardcode_libdir_flag_spec="\${wl}-rpath \${wl}\$libdir"
+hardcode_libdir_flag_spec=""
# If ld is used when linking, flag to hardcode $libdir into a binary
# during linking. This must work even if $libdir does not exist.
always_export_symbols=no
# The commands to list exported symbols.
-export_symbols_cmds="\$NM \$libobjs \$convenience | \$global_symbol_pipe | \$SED 's/.* //' | sort | uniq > \$export_symbols"
+export_symbols_cmds=""
# Symbols that should not be listed in the preloaded symbols.
-exclude_expsyms="_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*"
+exclude_expsyms=""
# Symbols that must always be exported.
include_expsyms=""
file_list_spec=""
# How to hardcode a shared library path into an executable.
-hardcode_action=immediate
+hardcode_action=
# The directories searched by this compiler when creating a shared library.
-compiler_lib_search_dirs="/usr/lib/gcc/x86_64-redhat-linux/4.5.1 /usr/lib/gcc/x86_64-redhat-linux/4.5.1/../../../../lib64 /lib/../lib64 /usr/lib/../lib64 /usr/lib/gcc/x86_64-redhat-linux/4.5.1/../../.."
+compiler_lib_search_dirs=""
# Dependencies to place before and after the objects being linked to
# create a shared library.
-predep_objects="/usr/lib/gcc/x86_64-redhat-linux/4.5.1/../../../../lib64/crti.o /usr/lib/gcc/x86_64-redhat-linux/4.5.1/crtbeginS.o"
-postdep_objects="/usr/lib/gcc/x86_64-redhat-linux/4.5.1/crtendS.o /usr/lib/gcc/x86_64-redhat-linux/4.5.1/../../../../lib64/crtn.o"
+predep_objects=""
+postdep_objects=""
predeps=""
-postdeps="-lstdc++ -lm -lgcc_s -lc -lgcc_s"
+postdeps=""
# The library search path used internally by the compiler when linking
# a shared library.
-compiler_lib_search_path="-L/usr/lib/gcc/x86_64-redhat-linux/4.5.1 -L/usr/lib/gcc/x86_64-redhat-linux/4.5.1/../../../../lib64 -L/lib/../lib64 -L/usr/lib/../lib64 -L/usr/lib/gcc/x86_64-redhat-linux/4.5.1/../../.."
+compiler_lib_search_path=""
# ### END LIBTOOL TAG CONFIG: CXX
Description: ImageMagick - Convert, Edit, and Compose Images
Version: 6.6.4
Libs: -L${libdir} -lMagickCore
-Cflags: -I${includedir}
+Cflags: -I${includedir} -fopenmp
echo '6.6.4 Q16 '
;;
--cflags)
- echo "-I${includedir} "
+ echo "-I${includedir} -fopenmp"
;;
--cxxflags)
- echo '-g -O2'
+ echo '-g -O2 -pthread'
;;
--cppflags)
echo '-I/usr/local/include/ImageMagick'
echo '-L/usr/local/lib '
;;
--libs)
- echo "-L${libdir} -lMagickCore -ltiff -lfreetype -ljasper -ljpeg -lpng -lfontconfig -lXext -lXt -lSM -lICE -lX11 -lbz2 -lxml2 -lz -lm -lgomp -lltdl"
+ echo "-L${libdir} -lMagickCore -ltiff -lfreetype -ljasper -ljpeg -lpng -lfontconfig -lXext -lXt -lSM -lICE -lX11 -lbz2 -lxml2 -lz -lm -lgomp -lpthread -lltdl"
;;
*)
echo "${usage}" 1>&2
#define MAGICKCORE_STDC_HEADERS 1
#endif
+/* Define if you have POSIX threads libraries and header files. */
+#ifndef MAGICKCORE_THREAD_SUPPORT
+#define MAGICKCORE_THREAD_SUPPORT 1
+#endif
+
/* Define if you have TIFF library */
#ifndef MAGICKCORE_TIFF_DELEGATE
#define MAGICKCORE_TIFF_DELEGATE 1
extern "C" {
#endif
-#if defined(MAGICKCORE_HAVE_PTHREAD)
+#if defined(MAGICKCORE_THREAD_SUPPORT)
static pthread_mutex_t
semaphore_mutex = PTHREAD_MUTEX_INITIALIZER;
#elif defined(MAGICKCORE_HAVE_WINTHREADS)
static inline void LockMagickMutex(void)
{
-#if defined(MAGICKCORE_HAVE_PTHREAD)
+#if defined(MAGICKCORE_THREAD_SUPPORT)
{
int
status;
static inline void UnlockMagickMutex(void)
{
-#if defined(MAGICKCORE_HAVE_PTHREAD)
+#if defined(MAGICKCORE_THREAD_SUPPORT)
{
int
status;
/*
Initialize the semaphore.
*/
-#if defined(MAGICKCORE_HAVE_PTHREAD)
+#if defined(MAGICKCORE_THREAD_SUPPORT)
{
int
status;
assert((*semaphore_info) != (SemaphoreInfo *) NULL);
assert((*semaphore_info)->signature == MagickSignature);
LockMagickMutex();
-#if defined(MAGICKCORE_HAVE_PTHREAD)
+#if defined(MAGICKCORE_THREAD_SUPPORT)
{
int
status;
{
assert(semaphore_info != (SemaphoreInfo *) NULL);
assert(semaphore_info->signature == MagickSignature);
-#if defined(MAGICKCORE_HAVE_PTHREAD)
+#if defined(MAGICKCORE_THREAD_SUPPORT)
{
int
status;
}
semaphore_info->reference_count--;
#endif
-#if defined(MAGICKCORE_HAVE_PTHREAD)
+#if defined(MAGICKCORE_THREAD_SUPPORT)
{
int
status;
#include <signal.h>
#include <assert.h>
-#if defined(MAGICKCORE_HAVE_PTHREAD)
+#if defined(MAGICKCORE_THREAD_SUPPORT)
# include <pthread.h>
#elif defined(MAGICKCORE_WINDOWS_SUPPORT)
# define MAGICKCORE_HAVE_WINTHREADS 1
#define MagickCachePrefetch(address,mode,locality)
#endif
-#if defined(MAGICKCORE_HAVE_PTHREAD)
+#if defined(MAGICKCORE_THREAD_SUPPORT)
typedef pthread_mutex_t MagickMutexType;
#elif defined(MAGICKCORE_WINDOWS_SUPPORT)
typedef CRITICAL_SECTION MagickMutexType;
static inline MagickThreadType GetMagickThreadId(void)
{
-#if defined(MAGICKCORE_HAVE_PTHREAD)
+#if defined(MAGICKCORE_THREAD_SUPPORT)
return(pthread_self());
#elif defined(MAGICKCORE_WINDOWS_SUPPORT)
return(GetCurrentThreadId());
static inline size_t GetMagickThreadSignature(void)
{
-#if defined(MAGICKCORE_HAVE_PTHREAD)
+#if defined(MAGICKCORE_THREAD_SUPPORT)
{
union
{
static inline MagickBooleanType IsMagickThreadEqual(const MagickThreadType id)
{
-#if defined(MAGICKCORE_HAVE_PTHREAD)
+#if defined(MAGICKCORE_THREAD_SUPPORT)
if (pthread_equal(id,pthread_self()) != 0)
return(MagickTrue);
#elif defined(MAGICKCORE_WINDOWS_SUPPORT)
*/
MagickExport MagickBooleanType MagickCreateThreadKey(MagickThreadKey *key)
{
-#if defined(MAGICKCORE_HAVE_PTHREAD)
+#if defined(MAGICKCORE_THREAD_SUPPORT)
return(pthread_key_create(key,NULL) == 0 ? MagickTrue : MagickFalse);
#elif defined(MAGICKCORE_HAVE_WINTHREADS)
*key=TlsAlloc();
*/
MagickExport MagickBooleanType MagickDeleteThreadKey(MagickThreadKey key)
{
-#if defined(MAGICKCORE_HAVE_PTHREAD)
+#if defined(MAGICKCORE_THREAD_SUPPORT)
return(pthread_key_delete(key) == 0 ? MagickTrue : MagickFalse);
#elif defined(MAGICKCORE_HAVE_WINTHREADS)
return(TlsFree(key) != 0 ? MagickTrue : MagickFalse);
*/
MagickExport void *MagickGetThreadValue(MagickThreadKey key)
{
-#if defined(MAGICKCORE_HAVE_PTHREAD)
+#if defined(MAGICKCORE_THREAD_SUPPORT)
return(pthread_getspecific(key));
#elif defined(MAGICKCORE_HAVE_WINTHREADS)
return(TlsGetValue(key));
MagickExport MagickBooleanType MagickSetThreadValue(MagickThreadKey key,
const void *value)
{
-#if defined(MAGICKCORE_HAVE_PTHREAD)
+#if defined(MAGICKCORE_THREAD_SUPPORT)
return(pthread_setspecific(key,value) == 0 ? MagickTrue : MagickFalse);
#elif defined(MAGICKCORE_HAVE_WINTHREADS)
return(TlsSetValue(key,(void *) value) != 0 ? MagickTrue : MagickFalse);
extern "C" {
#endif
-#if defined(MAGICKCORE_HAVE_PTHREAD)
+#if defined(MAGICKCORE_THREAD_SUPPORT)
typedef pthread_t MagickThreadType;
#elif defined(MAGICKCORE_HAVE_WINTHREADS)
typedef DWORD MagickThreadType;
typedef pid_t MagickThreadType;
#endif
-#if defined(MAGICKCORE_HAVE_PTHREAD)
+#if defined(MAGICKCORE_THREAD_SUPPORT)
typedef pthread_key_t MagickThreadKey;
#elif defined(MAGICKCORE_HAVE_WINTHREADS)
typedef DWORD MagickThreadKey;
#define MagickReleaseDate "2010-09-23"
#define MagickChangeDate "20100912"
#define MagickAuthoritativeURL "http://www.imagemagick.org"
-#define MagickFeatures ""
+#define MagickFeatures "OpenMP "
#define MagickHomeURL "file:///usr/local/share/doc/ImageMagick-6.6.4/index.html"
#if (MAGICKCORE_QUANTUM_DEPTH == 8)
#define MagickQuantumDepth "Q8"
echo '6.6.4 Q16 '
;;
--cflags)
- echo "-I${includedir} "
+ echo "-I${includedir} -fopenmp"
;;
--cxxflags)
- echo '-g -O2'
+ echo '-g -O2 -pthread'
;;
--cppflags)
echo '-I/usr/local/include/ImageMagick'
echo '-L/usr/local/lib '
;;
--libs)
- echo "-L${libdir} -lMagickWand -lMagickCore -ltiff -lfreetype -ljasper -ljpeg -lpng -lfontconfig -lXext -lXt -lSM -lICE -lX11 -lbz2 -lxml2 -lz -lm -lgomp -lltdl"
+ echo "-L${libdir} -lMagickWand -lMagickCore -ltiff -lfreetype -ljasper -ljpeg -lpng -lfontconfig -lXext -lXt -lSM -lICE -lX11 -lbz2 -lxml2 -lz -lm -lgomp -lpthread -lltdl"
;;
*)
echo "${usage}" 1>&2
Description: MagickWand - C API for ImageMagick
Requires: ImageMagick
Libs: -L${libdir} -lMagickWand -lMagickCore
-Cflags: -I${includedir}
+Cflags: -I${includedir} -fopenmp
#include <signal.h>
#include <assert.h>
-#if defined(MAGICKCORE_HAVE_PTHREAD)
+#if defined(MAGICKCORE_THREAD_SUPPORT)
# include <pthread.h>
#elif defined(MAGICKCORE_WINDOWS_SUPPORT)
# define MAGICKCORE_HAVE_WINTHREADS 1