#include "MagickCore/segment.h"
#include "MagickCore/shear.h"
#include "MagickCore/signature-private.h"
+#include "MagickCore/statistic.h"
#include "MagickCore/string_.h"
#include "MagickCore/thread-private.h"
#include "MagickCore/transform.h"
% %
% %
% %
-% S t a t i s t i c I m a g e %
-% %
-% %
-% %
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-%
-% StatisticImage() makes each pixel the min / max / median / mode / etc. of
-% the neighborhood of the specified width and height.
-%
-% The format of the StatisticImage method is:
-%
-% Image *StatisticImage(const Image *image,const StatisticType type,
-% const size_t width,const size_t height,ExceptionInfo *exception)
-%
-% A description of each parameter follows:
-%
-% o image: the image.
-%
-% o type: the statistic type (median, mode, etc.).
-%
-% o width: the width of the pixel neighborhood.
-%
-% o height: the height of the pixel neighborhood.
-%
-% o exception: return any errors or warnings in this structure.
-%
-*/
-
-typedef struct _SkipNode
-{
- size_t
- next[9],
- count,
- signature;
-} SkipNode;
-
-typedef struct _SkipList
-{
- ssize_t
- level;
-
- SkipNode
- *nodes;
-} SkipList;
-
-typedef struct _PixelList
-{
- size_t
- length,
- seed;
-
- SkipList
- skip_list;
-
- size_t
- signature;
-} PixelList;
-
-static PixelList *DestroyPixelList(PixelList *pixel_list)
-{
- if (pixel_list == (PixelList *) NULL)
- return((PixelList *) NULL);
- if (pixel_list->skip_list.nodes != (SkipNode *) NULL)
- pixel_list->skip_list.nodes=(SkipNode *) RelinquishMagickMemory(
- pixel_list->skip_list.nodes);
- pixel_list=(PixelList *) RelinquishMagickMemory(pixel_list);
- return(pixel_list);
-}
-
-static PixelList **DestroyPixelListThreadSet(PixelList **pixel_list)
-{
- register ssize_t
- i;
-
- assert(pixel_list != (PixelList **) NULL);
- for (i=0; i < (ssize_t) GetOpenMPMaximumThreads(); i++)
- if (pixel_list[i] != (PixelList *) NULL)
- pixel_list[i]=DestroyPixelList(pixel_list[i]);
- pixel_list=(PixelList **) RelinquishMagickMemory(pixel_list);
- return(pixel_list);
-}
-
-static PixelList *AcquirePixelList(const size_t width,const size_t height)
-{
- PixelList
- *pixel_list;
-
- pixel_list=(PixelList *) AcquireMagickMemory(sizeof(*pixel_list));
- if (pixel_list == (PixelList *) NULL)
- return(pixel_list);
- (void) ResetMagickMemory((void *) pixel_list,0,sizeof(*pixel_list));
- pixel_list->length=width*height;
- pixel_list->skip_list.nodes=(SkipNode *) AcquireQuantumMemory(65537UL,
- sizeof(*pixel_list->skip_list.nodes));
- if (pixel_list->skip_list.nodes == (SkipNode *) NULL)
- return(DestroyPixelList(pixel_list));
- (void) ResetMagickMemory(pixel_list->skip_list.nodes,0,65537UL*
- sizeof(*pixel_list->skip_list.nodes));
- pixel_list->signature=MagickSignature;
- return(pixel_list);
-}
-
-static PixelList **AcquirePixelListThreadSet(const size_t width,
- const size_t height)
-{
- PixelList
- **pixel_list;
-
- register ssize_t
- i;
-
- size_t
- number_threads;
-
- number_threads=GetOpenMPMaximumThreads();
- pixel_list=(PixelList **) AcquireQuantumMemory(number_threads,
- sizeof(*pixel_list));
- if (pixel_list == (PixelList **) NULL)
- return((PixelList **) NULL);
- (void) ResetMagickMemory(pixel_list,0,number_threads*sizeof(*pixel_list));
- for (i=0; i < (ssize_t) number_threads; i++)
- {
- pixel_list[i]=AcquirePixelList(width,height);
- if (pixel_list[i] == (PixelList *) NULL)
- return(DestroyPixelListThreadSet(pixel_list));
- }
- return(pixel_list);
-}
-
-static void AddNodePixelList(PixelList *pixel_list,const size_t color)
-{
- register SkipList
- *p;
-
- register ssize_t
- level;
-
- size_t
- search,
- update[9];
-
- /*
- Initialize the node.
- */
- p=(&pixel_list->skip_list);
- p->nodes[color].signature=pixel_list->signature;
- p->nodes[color].count=1;
- /*
- Determine where it belongs in the list.
- */
- search=65536UL;
- for (level=p->level; level >= 0; level--)
- {
- while (p->nodes[search].next[level] < color)
- search=p->nodes[search].next[level];
- update[level]=search;
- }
- /*
- Generate a pseudo-random level for this node.
- */
- for (level=0; ; level++)
- {
- pixel_list->seed=(pixel_list->seed*42893621L)+1L;
- if ((pixel_list->seed & 0x300) != 0x300)
- break;
- }
- if (level > 8)
- level=8;
- if (level > (p->level+2))
- level=p->level+2;
- /*
- If we're raising the list's level, link back to the root node.
- */
- while (level > p->level)
- {
- p->level++;
- update[p->level]=65536UL;
- }
- /*
- Link the node into the skip-list.
- */
- do
- {
- p->nodes[color].next[level]=p->nodes[update[level]].next[level];
- p->nodes[update[level]].next[level]=color;
- } while (level-- > 0);
-}
-
-static inline void GetMaximumPixelList(PixelList *pixel_list,Quantum *pixel)
-{
- register SkipList
- *p;
-
- size_t
- color,
- maximum;
-
- ssize_t
- count;
-
- /*
- Find the maximum value for each of the color.
- */
- p=(&pixel_list->skip_list);
- color=65536L;
- count=0;
- maximum=p->nodes[color].next[0];
- do
- {
- color=p->nodes[color].next[0];
- if (color > maximum)
- maximum=color;
- count+=p->nodes[color].count;
- } while (count < (ssize_t) pixel_list->length);
- *pixel=ScaleShortToQuantum((unsigned short) maximum);
-}
-
-static inline void GetMeanPixelList(PixelList *pixel_list,Quantum *pixel)
-{
- MagickRealType
- sum;
-
- register SkipList
- *p;
-
- size_t
- color;
-
- ssize_t
- count;
-
- /*
- Find the mean value for each of the color.
- */
- p=(&pixel_list->skip_list);
- color=65536L;
- count=0;
- sum=0.0;
- do
- {
- color=p->nodes[color].next[0];
- sum+=(MagickRealType) p->nodes[color].count*color;
- count+=p->nodes[color].count;
- } while (count < (ssize_t) pixel_list->length);
- sum/=pixel_list->length;
- *pixel=ScaleShortToQuantum((unsigned short) sum);
-}
-
-static inline void GetMedianPixelList(PixelList *pixel_list,Quantum *pixel)
-{
- register SkipList
- *p;
-
- size_t
- color;
-
- ssize_t
- count;
-
- /*
- Find the median value for each of the color.
- */
- p=(&pixel_list->skip_list);
- color=65536L;
- count=0;
- do
- {
- color=p->nodes[color].next[0];
- count+=p->nodes[color].count;
- } while (count <= (ssize_t) (pixel_list->length >> 1));
- *pixel=ScaleShortToQuantum((unsigned short) color);
-}
-
-static inline void GetMinimumPixelList(PixelList *pixel_list,Quantum *pixel)
-{
- register SkipList
- *p;
-
- size_t
- color,
- minimum;
-
- ssize_t
- count;
-
- /*
- Find the minimum value for each of the color.
- */
- p=(&pixel_list->skip_list);
- count=0;
- color=65536UL;
- minimum=p->nodes[color].next[0];
- do
- {
- color=p->nodes[color].next[0];
- if (color < minimum)
- minimum=color;
- count+=p->nodes[color].count;
- } while (count < (ssize_t) pixel_list->length);
- *pixel=ScaleShortToQuantum((unsigned short) minimum);
-}
-
-static inline void GetModePixelList(PixelList *pixel_list,Quantum *pixel)
-{
- register SkipList
- *p;
-
- size_t
- color,
- max_count,
- mode;
-
- ssize_t
- count;
-
- /*
- Make each pixel the 'predominant color' of the specified neighborhood.
- */
- p=(&pixel_list->skip_list);
- color=65536L;
- mode=color;
- max_count=p->nodes[mode].count;
- count=0;
- do
- {
- color=p->nodes[color].next[0];
- if (p->nodes[color].count > max_count)
- {
- mode=color;
- max_count=p->nodes[mode].count;
- }
- count+=p->nodes[color].count;
- } while (count < (ssize_t) pixel_list->length);
- *pixel=ScaleShortToQuantum((unsigned short) mode);
-}
-
-static inline void GetNonpeakPixelList(PixelList *pixel_list,Quantum *pixel)
-{
- register SkipList
- *p;
-
- size_t
- color,
- next,
- previous;
-
- ssize_t
- count;
-
- /*
- Finds the non peak value for each of the colors.
- */
- p=(&pixel_list->skip_list);
- color=65536L;
- next=p->nodes[color].next[0];
- count=0;
- do
- {
- previous=color;
- color=next;
- next=p->nodes[color].next[0];
- count+=p->nodes[color].count;
- } while (count <= (ssize_t) (pixel_list->length >> 1));
- if ((previous == 65536UL) && (next != 65536UL))
- color=next;
- else
- if ((previous != 65536UL) && (next == 65536UL))
- color=previous;
- *pixel=ScaleShortToQuantum((unsigned short) color);
-}
-
-static inline void GetStandardDeviationPixelList(PixelList *pixel_list,
- Quantum *pixel)
-{
- MagickRealType
- sum,
- sum_squared;
-
- register SkipList
- *p;
-
- size_t
- color;
-
- ssize_t
- count;
-
- /*
- Find the standard-deviation value for each of the color.
- */
- p=(&pixel_list->skip_list);
- color=65536L;
- count=0;
- sum=0.0;
- sum_squared=0.0;
- do
- {
- register ssize_t
- i;
-
- color=p->nodes[color].next[0];
- sum+=(MagickRealType) p->nodes[color].count*color;
- for (i=0; i < (ssize_t) p->nodes[color].count; i++)
- sum_squared+=((MagickRealType) color)*((MagickRealType) color);
- count+=p->nodes[color].count;
- } while (count < (ssize_t) pixel_list->length);
- sum/=pixel_list->length;
- sum_squared/=pixel_list->length;
- *pixel=ScaleShortToQuantum((unsigned short) sqrt(sum_squared-(sum*sum)));
-}
-
-static inline void InsertPixelList(const Image *image,const Quantum pixel,
- PixelList *pixel_list)
-{
- size_t
- signature;
-
- unsigned short
- index;
-
- index=ScaleQuantumToShort(pixel);
- signature=pixel_list->skip_list.nodes[index].signature;
- if (signature == pixel_list->signature)
- {
- pixel_list->skip_list.nodes[index].count++;
- return;
- }
- AddNodePixelList(pixel_list,index);
-}
-
-static inline MagickRealType MagickAbsoluteValue(const MagickRealType x)
-{
- if (x < 0)
- return(-x);
- return(x);
-}
-
-static inline size_t MagickMax(const size_t x,const size_t y)
-{
- if (x > y)
- return(x);
- return(y);
-}
-
-static void ResetPixelList(PixelList *pixel_list)
-{
- int
- level;
-
- register SkipNode
- *root;
-
- register SkipList
- *p;
-
- /*
- Reset the skip-list.
- */
- p=(&pixel_list->skip_list);
- root=p->nodes+65536UL;
- p->level=0;
- for (level=0; level < 9; level++)
- root->next[level]=65536UL;
- pixel_list->seed=pixel_list->signature++;
-}
-
-MagickExport Image *StatisticImage(const Image *image,const StatisticType type,
- const size_t width,const size_t height,ExceptionInfo *exception)
-{
-#define StatisticImageTag "Statistic/Image"
-
- CacheView
- *image_view,
- *statistic_view;
-
- Image
- *statistic_image;
-
- MagickBooleanType
- status;
-
- MagickOffsetType
- progress;
-
- PixelList
- **restrict pixel_list;
-
- ssize_t
- center,
- y;
-
- /*
- Initialize statistics image attributes.
- */
- assert(image != (Image *) NULL);
- assert(image->signature == MagickSignature);
- if (image->debug != MagickFalse)
- (void) LogMagickEvent(TraceEvent,GetMagickModule(),"%s",image->filename);
- assert(exception != (ExceptionInfo *) NULL);
- assert(exception->signature == MagickSignature);
- statistic_image=CloneImage(image,image->columns,image->rows,MagickTrue,
- exception);
- if (statistic_image == (Image *) NULL)
- return((Image *) NULL);
- status=SetImageStorageClass(statistic_image,DirectClass,exception);
- if (status == MagickFalse)
- {
- statistic_image=DestroyImage(statistic_image);
- return((Image *) NULL);
- }
- pixel_list=AcquirePixelListThreadSet(MagickMax(width,1),MagickMax(height,1));
- if (pixel_list == (PixelList **) NULL)
- {
- statistic_image=DestroyImage(statistic_image);
- ThrowImageException(ResourceLimitError,"MemoryAllocationFailed");
- }
- /*
- Make each pixel the min / max / median / mode / etc. of the neighborhood.
- */
- center=(ssize_t) GetPixelChannels(image)*(image->columns+MagickMax(width,1))*
- (MagickMax(height,1)/2L)+GetPixelChannels(image)*(MagickMax(width,1)/2L);
- status=MagickTrue;
- progress=0;
- image_view=AcquireCacheView(image);
- statistic_view=AcquireCacheView(statistic_image);
-#if defined(MAGICKCORE_OPENMP_SUPPORT)
- #pragma omp parallel for schedule(dynamic,4) shared(progress,status)
-#endif
- for (y=0; y < (ssize_t) statistic_image->rows; y++)
- {
- const int
- id = GetOpenMPThreadId();
-
- register const Quantum
- *restrict p;
-
- register Quantum
- *restrict q;
-
- register ssize_t
- x;
-
- if (status == MagickFalse)
- continue;
- p=GetCacheViewVirtualPixels(image_view,-((ssize_t) MagickMax(width,1)/2L),y-
- (ssize_t) (MagickMax(height,1)/2L),image->columns+MagickMax(width,1),
- MagickMax(height,1),exception);
- q=QueueCacheViewAuthenticPixels(statistic_view,0,y,statistic_image->columns, 1,exception);
- if ((p == (const Quantum *) NULL) || (q == (Quantum *) NULL))
- {
- status=MagickFalse;
- continue;
- }
- for (x=0; x < (ssize_t) statistic_image->columns; x++)
- {
- register ssize_t
- i;
-
- for (i=0; i < (ssize_t) GetPixelChannels(image); i++)
- {
- PixelChannel
- channel;
-
- PixelTrait
- statistic_traits,
- traits;
-
- Quantum
- pixel;
-
- register const Quantum
- *restrict pixels;
-
- register ssize_t
- u;
-
- ssize_t
- v;
-
- traits=GetPixelChannelMapTraits(image,i);
- channel=GetPixelChannelMapChannel(image,i);
- statistic_traits=GetPixelChannelMapTraits(statistic_image,channel);
- if ((traits == UndefinedPixelTrait) ||
- (statistic_traits == UndefinedPixelTrait))
- continue;
- if ((statistic_traits & CopyPixelTrait) != 0)
- {
- SetPixelChannel(statistic_image,channel,p[center+i],q);
- continue;
- }
- pixels=p;
- ResetPixelList(pixel_list[id]);
- for (v=0; v < (ssize_t) MagickMax(height,1); v++)
- {
- for (u=0; u < (ssize_t) MagickMax(width,1); u++)
- {
- InsertPixelList(image,pixels[i],pixel_list[id]);
- pixels+=GetPixelChannels(image);
- }
- pixels+=image->columns*GetPixelChannels(image);
- }
- switch (type)
- {
- case GradientStatistic:
- {
- MagickRealType
- maximum,
- minimum;
-
- GetMinimumPixelList(pixel_list[id],&pixel);
- minimum=(MagickRealType) pixel;
- GetMaximumPixelList(pixel_list[id],&pixel);
- maximum=(MagickRealType) pixel;
- pixel=ClampToQuantum(MagickAbsoluteValue(maximum-minimum));
- break;
- }
- case MaximumStatistic:
- {
- GetMaximumPixelList(pixel_list[id],&pixel);
- break;
- }
- case MeanStatistic:
- {
- GetMeanPixelList(pixel_list[id],&pixel);
- break;
- }
- case MedianStatistic:
- default:
- {
- GetMedianPixelList(pixel_list[id],&pixel);
- break;
- }
- case MinimumStatistic:
- {
- GetMinimumPixelList(pixel_list[id],&pixel);
- break;
- }
- case ModeStatistic:
- {
- GetModePixelList(pixel_list[id],&pixel);
- break;
- }
- case NonpeakStatistic:
- {
- GetNonpeakPixelList(pixel_list[id],&pixel);
- break;
- }
- case StandardDeviationStatistic:
- {
- GetStandardDeviationPixelList(pixel_list[id],&pixel);
- break;
- }
- }
- SetPixelChannel(statistic_image,channel,pixel,q);
- }
- p+=GetPixelChannels(image);
- q+=GetPixelChannels(statistic_image);
- }
- if (SyncCacheViewAuthenticPixels(statistic_view,exception) == MagickFalse)
- status=MagickFalse;
- if (image->progress_monitor != (MagickProgressMonitor) NULL)
- {
- MagickBooleanType
- proceed;
-
-#if defined(MAGICKCORE_OPENMP_SUPPORT)
- #pragma omp critical (MagickCore_StatisticImage)
-#endif
- proceed=SetImageProgress(image,StatisticImageTag,progress++,
- image->rows);
- if (proceed == MagickFalse)
- status=MagickFalse;
- }
- }
- statistic_view=DestroyCacheView(statistic_view);
- image_view=DestroyCacheView(image_view);
- pixel_list=DestroyPixelListThreadSet(pixel_list);
- return(statistic_image);
-}
-\f
-/*
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-% %
-% %
-% %
% U n s h a r p M a s k I m a g e %
% %
% %
JPEGPreview
} PreviewType;
-typedef enum
-{
- UndefinedStatistic,
- GradientStatistic,
- MaximumStatistic,
- MeanStatistic,
- MedianStatistic,
- MinimumStatistic,
- ModeStatistic,
- NonpeakStatistic,
- StandardDeviationStatistic
-} StatisticType;
-
extern MagickExport Image
*AdaptiveBlurImage(const Image *,const double,const double,const double,
ExceptionInfo *),
ExceptionInfo *),
*SpreadImage(const Image *,const double,const PixelInterpolateMethod,
ExceptionInfo *),
- *StatisticImage(const Image *,const StatisticType,const size_t,const size_t,
- ExceptionInfo *),
*UnsharpMaskImage(const Image *,const double,const double,const double,
const double,ExceptionInfo *);
#define MAGICKCORE_LT_OBJDIR ".libs/"
#endif
+/* Define to the shared library suffix, say, ".dylib". */
+/* #undef LT_SHARED_EXT */
+
/* Define if you have LZMA library */
#ifndef MAGICKCORE_LZMA_DELEGATE
#define MAGICKCORE_LZMA_DELEGATE 1
return(pixels);
}
-static inline double MagickMax(const double x,const double y)
+static inline double EvaluateMax(const double x,const double y)
{
if (x > y)
return(x);
}
case MaxEvaluateOperator:
{
- result=(MagickRealType) MagickMax((double) pixel,value);
+ result=(MagickRealType) EvaluateMax((double) pixel,value);
break;
}
case MeanEvaluateOperator:
}
for (i=0; i < (ssize_t) MaxPixelChannels; i++)
{
- channel_statistics[CompositePixelChannel].depth=(size_t) MagickMax((double)
- channel_statistics[CompositePixelChannel].depth,(double)
+ channel_statistics[CompositePixelChannel].depth=(size_t) EvaluateMax(
+ (double) channel_statistics[CompositePixelChannel].depth,(double)
channel_statistics[i].depth);
channel_statistics[CompositePixelChannel].minima=MagickMin(
channel_statistics[CompositePixelChannel].minima,
channel_statistics[i].minima);
- channel_statistics[CompositePixelChannel].maxima=MagickMax(
+ channel_statistics[CompositePixelChannel].maxima=EvaluateMax(
channel_statistics[CompositePixelChannel].maxima,
channel_statistics[i].maxima);
channel_statistics[CompositePixelChannel].sum+=channel_statistics[i].sum;
}
return(channel_statistics);
}
+\f
+/*
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+% %
+% %
+% %
+% S t a t i s t i c I m a g e %
+% %
+% %
+% %
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+%
+% StatisticImage() makes each pixel the min / max / median / mode / etc. of
+% the neighborhood of the specified width and height.
+%
+% The format of the StatisticImage method is:
+%
+% Image *StatisticImage(const Image *image,const StatisticType type,
+% const size_t width,const size_t height,ExceptionInfo *exception)
+%
+% A description of each parameter follows:
+%
+% o image: the image.
+%
+% o type: the statistic type (median, mode, etc.).
+%
+% o width: the width of the pixel neighborhood.
+%
+% o height: the height of the pixel neighborhood.
+%
+% o exception: return any errors or warnings in this structure.
+%
+*/
+
+typedef struct _SkipNode
+{
+ size_t
+ next[9],
+ count,
+ signature;
+} SkipNode;
+
+typedef struct _SkipList
+{
+ ssize_t
+ level;
+
+ SkipNode
+ *nodes;
+} SkipList;
+
+typedef struct _PixelList
+{
+ size_t
+ length,
+ seed;
+
+ SkipList
+ skip_list;
+
+ size_t
+ signature;
+} PixelList;
+
+static PixelList *DestroyPixelList(PixelList *pixel_list)
+{
+ if (pixel_list == (PixelList *) NULL)
+ return((PixelList *) NULL);
+ if (pixel_list->skip_list.nodes != (SkipNode *) NULL)
+ pixel_list->skip_list.nodes=(SkipNode *) RelinquishMagickMemory(
+ pixel_list->skip_list.nodes);
+ pixel_list=(PixelList *) RelinquishMagickMemory(pixel_list);
+ return(pixel_list);
+}
+
+static PixelList **DestroyPixelListThreadSet(PixelList **pixel_list)
+{
+ register ssize_t
+ i;
+
+ assert(pixel_list != (PixelList **) NULL);
+ for (i=0; i < (ssize_t) GetOpenMPMaximumThreads(); i++)
+ if (pixel_list[i] != (PixelList *) NULL)
+ pixel_list[i]=DestroyPixelList(pixel_list[i]);
+ pixel_list=(PixelList **) RelinquishMagickMemory(pixel_list);
+ return(pixel_list);
+}
+
+static PixelList *AcquirePixelList(const size_t width,const size_t height)
+{
+ PixelList
+ *pixel_list;
+
+ pixel_list=(PixelList *) AcquireMagickMemory(sizeof(*pixel_list));
+ if (pixel_list == (PixelList *) NULL)
+ return(pixel_list);
+ (void) ResetMagickMemory((void *) pixel_list,0,sizeof(*pixel_list));
+ pixel_list->length=width*height;
+ pixel_list->skip_list.nodes=(SkipNode *) AcquireQuantumMemory(65537UL,
+ sizeof(*pixel_list->skip_list.nodes));
+ if (pixel_list->skip_list.nodes == (SkipNode *) NULL)
+ return(DestroyPixelList(pixel_list));
+ (void) ResetMagickMemory(pixel_list->skip_list.nodes,0,65537UL*
+ sizeof(*pixel_list->skip_list.nodes));
+ pixel_list->signature=MagickSignature;
+ return(pixel_list);
+}
+
+static PixelList **AcquirePixelListThreadSet(const size_t width,
+ const size_t height)
+{
+ PixelList
+ **pixel_list;
+
+ register ssize_t
+ i;
+
+ size_t
+ number_threads;
+
+ number_threads=GetOpenMPMaximumThreads();
+ pixel_list=(PixelList **) AcquireQuantumMemory(number_threads,
+ sizeof(*pixel_list));
+ if (pixel_list == (PixelList **) NULL)
+ return((PixelList **) NULL);
+ (void) ResetMagickMemory(pixel_list,0,number_threads*sizeof(*pixel_list));
+ for (i=0; i < (ssize_t) number_threads; i++)
+ {
+ pixel_list[i]=AcquirePixelList(width,height);
+ if (pixel_list[i] == (PixelList *) NULL)
+ return(DestroyPixelListThreadSet(pixel_list));
+ }
+ return(pixel_list);
+}
+
+static void AddNodePixelList(PixelList *pixel_list,const size_t color)
+{
+ register SkipList
+ *p;
+
+ register ssize_t
+ level;
+
+ size_t
+ search,
+ update[9];
+
+ /*
+ Initialize the node.
+ */
+ p=(&pixel_list->skip_list);
+ p->nodes[color].signature=pixel_list->signature;
+ p->nodes[color].count=1;
+ /*
+ Determine where it belongs in the list.
+ */
+ search=65536UL;
+ for (level=p->level; level >= 0; level--)
+ {
+ while (p->nodes[search].next[level] < color)
+ search=p->nodes[search].next[level];
+ update[level]=search;
+ }
+ /*
+ Generate a pseudo-random level for this node.
+ */
+ for (level=0; ; level++)
+ {
+ pixel_list->seed=(pixel_list->seed*42893621L)+1L;
+ if ((pixel_list->seed & 0x300) != 0x300)
+ break;
+ }
+ if (level > 8)
+ level=8;
+ if (level > (p->level+2))
+ level=p->level+2;
+ /*
+ If we're raising the list's level, link back to the root node.
+ */
+ while (level > p->level)
+ {
+ p->level++;
+ update[p->level]=65536UL;
+ }
+ /*
+ Link the node into the skip-list.
+ */
+ do
+ {
+ p->nodes[color].next[level]=p->nodes[update[level]].next[level];
+ p->nodes[update[level]].next[level]=color;
+ } while (level-- > 0);
+}
+
+static inline void GetMaximumPixelList(PixelList *pixel_list,Quantum *pixel)
+{
+ register SkipList
+ *p;
+
+ size_t
+ color,
+ maximum;
+
+ ssize_t
+ count;
+
+ /*
+ Find the maximum value for each of the color.
+ */
+ p=(&pixel_list->skip_list);
+ color=65536L;
+ count=0;
+ maximum=p->nodes[color].next[0];
+ do
+ {
+ color=p->nodes[color].next[0];
+ if (color > maximum)
+ maximum=color;
+ count+=p->nodes[color].count;
+ } while (count < (ssize_t) pixel_list->length);
+ *pixel=ScaleShortToQuantum((unsigned short) maximum);
+}
+
+static inline void GetMeanPixelList(PixelList *pixel_list,Quantum *pixel)
+{
+ MagickRealType
+ sum;
+
+ register SkipList
+ *p;
+
+ size_t
+ color;
+
+ ssize_t
+ count;
+
+ /*
+ Find the mean value for each of the color.
+ */
+ p=(&pixel_list->skip_list);
+ color=65536L;
+ count=0;
+ sum=0.0;
+ do
+ {
+ color=p->nodes[color].next[0];
+ sum+=(MagickRealType) p->nodes[color].count*color;
+ count+=p->nodes[color].count;
+ } while (count < (ssize_t) pixel_list->length);
+ sum/=pixel_list->length;
+ *pixel=ScaleShortToQuantum((unsigned short) sum);
+}
+
+static inline void GetMedianPixelList(PixelList *pixel_list,Quantum *pixel)
+{
+ register SkipList
+ *p;
+
+ size_t
+ color;
+
+ ssize_t
+ count;
+
+ /*
+ Find the median value for each of the color.
+ */
+ p=(&pixel_list->skip_list);
+ color=65536L;
+ count=0;
+ do
+ {
+ color=p->nodes[color].next[0];
+ count+=p->nodes[color].count;
+ } while (count <= (ssize_t) (pixel_list->length >> 1));
+ *pixel=ScaleShortToQuantum((unsigned short) color);
+}
+
+static inline void GetMinimumPixelList(PixelList *pixel_list,Quantum *pixel)
+{
+ register SkipList
+ *p;
+
+ size_t
+ color,
+ minimum;
+
+ ssize_t
+ count;
+
+ /*
+ Find the minimum value for each of the color.
+ */
+ p=(&pixel_list->skip_list);
+ count=0;
+ color=65536UL;
+ minimum=p->nodes[color].next[0];
+ do
+ {
+ color=p->nodes[color].next[0];
+ if (color < minimum)
+ minimum=color;
+ count+=p->nodes[color].count;
+ } while (count < (ssize_t) pixel_list->length);
+ *pixel=ScaleShortToQuantum((unsigned short) minimum);
+}
+
+static inline void GetModePixelList(PixelList *pixel_list,Quantum *pixel)
+{
+ register SkipList
+ *p;
+
+ size_t
+ color,
+ max_count,
+ mode;
+
+ ssize_t
+ count;
+
+ /*
+ Make each pixel the 'predominant color' of the specified neighborhood.
+ */
+ p=(&pixel_list->skip_list);
+ color=65536L;
+ mode=color;
+ max_count=p->nodes[mode].count;
+ count=0;
+ do
+ {
+ color=p->nodes[color].next[0];
+ if (p->nodes[color].count > max_count)
+ {
+ mode=color;
+ max_count=p->nodes[mode].count;
+ }
+ count+=p->nodes[color].count;
+ } while (count < (ssize_t) pixel_list->length);
+ *pixel=ScaleShortToQuantum((unsigned short) mode);
+}
+
+static inline void GetNonpeakPixelList(PixelList *pixel_list,Quantum *pixel)
+{
+ register SkipList
+ *p;
+
+ size_t
+ color,
+ next,
+ previous;
+
+ ssize_t
+ count;
+
+ /*
+ Finds the non peak value for each of the colors.
+ */
+ p=(&pixel_list->skip_list);
+ color=65536L;
+ next=p->nodes[color].next[0];
+ count=0;
+ do
+ {
+ previous=color;
+ color=next;
+ next=p->nodes[color].next[0];
+ count+=p->nodes[color].count;
+ } while (count <= (ssize_t) (pixel_list->length >> 1));
+ if ((previous == 65536UL) && (next != 65536UL))
+ color=next;
+ else
+ if ((previous != 65536UL) && (next == 65536UL))
+ color=previous;
+ *pixel=ScaleShortToQuantum((unsigned short) color);
+}
+
+static inline void GetStandardDeviationPixelList(PixelList *pixel_list,
+ Quantum *pixel)
+{
+ MagickRealType
+ sum,
+ sum_squared;
+
+ register SkipList
+ *p;
+
+ size_t
+ color;
+
+ ssize_t
+ count;
+
+ /*
+ Find the standard-deviation value for each of the color.
+ */
+ p=(&pixel_list->skip_list);
+ color=65536L;
+ count=0;
+ sum=0.0;
+ sum_squared=0.0;
+ do
+ {
+ register ssize_t
+ i;
+
+ color=p->nodes[color].next[0];
+ sum+=(MagickRealType) p->nodes[color].count*color;
+ for (i=0; i < (ssize_t) p->nodes[color].count; i++)
+ sum_squared+=((MagickRealType) color)*((MagickRealType) color);
+ count+=p->nodes[color].count;
+ } while (count < (ssize_t) pixel_list->length);
+ sum/=pixel_list->length;
+ sum_squared/=pixel_list->length;
+ *pixel=ScaleShortToQuantum((unsigned short) sqrt(sum_squared-(sum*sum)));
+}
+
+static inline void InsertPixelList(const Image *image,const Quantum pixel,
+ PixelList *pixel_list)
+{
+ size_t
+ signature;
+
+ unsigned short
+ index;
+
+ index=ScaleQuantumToShort(pixel);
+ signature=pixel_list->skip_list.nodes[index].signature;
+ if (signature == pixel_list->signature)
+ {
+ pixel_list->skip_list.nodes[index].count++;
+ return;
+ }
+ AddNodePixelList(pixel_list,index);
+}
+
+static inline MagickRealType MagickAbsoluteValue(const MagickRealType x)
+{
+ if (x < 0)
+ return(-x);
+ return(x);
+}
+
+static inline size_t MagickMax(const size_t x,const size_t y)
+{
+ if (x > y)
+ return(x);
+ return(y);
+}
+
+static void ResetPixelList(PixelList *pixel_list)
+{
+ int
+ level;
+
+ register SkipNode
+ *root;
+
+ register SkipList
+ *p;
+
+ /*
+ Reset the skip-list.
+ */
+ p=(&pixel_list->skip_list);
+ root=p->nodes+65536UL;
+ p->level=0;
+ for (level=0; level < 9; level++)
+ root->next[level]=65536UL;
+ pixel_list->seed=pixel_list->signature++;
+}
+
+MagickExport Image *StatisticImage(const Image *image,const StatisticType type,
+ const size_t width,const size_t height,ExceptionInfo *exception)
+{
+#define StatisticImageTag "Statistic/Image"
+
+ CacheView
+ *image_view,
+ *statistic_view;
+
+ Image
+ *statistic_image;
+
+ MagickBooleanType
+ status;
+
+ MagickOffsetType
+ progress;
+
+ PixelList
+ **restrict pixel_list;
+
+ ssize_t
+ center,
+ y;
+
+ /*
+ Initialize statistics image attributes.
+ */
+ assert(image != (Image *) NULL);
+ assert(image->signature == MagickSignature);
+ if (image->debug != MagickFalse)
+ (void) LogMagickEvent(TraceEvent,GetMagickModule(),"%s",image->filename);
+ assert(exception != (ExceptionInfo *) NULL);
+ assert(exception->signature == MagickSignature);
+ statistic_image=CloneImage(image,image->columns,image->rows,MagickTrue,
+ exception);
+ if (statistic_image == (Image *) NULL)
+ return((Image *) NULL);
+ status=SetImageStorageClass(statistic_image,DirectClass,exception);
+ if (status == MagickFalse)
+ {
+ statistic_image=DestroyImage(statistic_image);
+ return((Image *) NULL);
+ }
+ pixel_list=AcquirePixelListThreadSet(MagickMax(width,1),MagickMax(height,1));
+ if (pixel_list == (PixelList **) NULL)
+ {
+ statistic_image=DestroyImage(statistic_image);
+ ThrowImageException(ResourceLimitError,"MemoryAllocationFailed");
+ }
+ /*
+ Make each pixel the min / max / median / mode / etc. of the neighborhood.
+ */
+ center=(ssize_t) GetPixelChannels(image)*(image->columns+MagickMax(width,1))*
+ (MagickMax(height,1)/2L)+GetPixelChannels(image)*(MagickMax(width,1)/2L);
+ status=MagickTrue;
+ progress=0;
+ image_view=AcquireCacheView(image);
+ statistic_view=AcquireCacheView(statistic_image);
+#if defined(MAGICKCORE_OPENMP_SUPPORT)
+ #pragma omp parallel for schedule(dynamic,4) shared(progress,status)
+#endif
+ for (y=0; y < (ssize_t) statistic_image->rows; y++)
+ {
+ const int
+ id = GetOpenMPThreadId();
+
+ register const Quantum
+ *restrict p;
+
+ register Quantum
+ *restrict q;
+
+ register ssize_t
+ x;
+
+ if (status == MagickFalse)
+ continue;
+ p=GetCacheViewVirtualPixels(image_view,-((ssize_t) MagickMax(width,1)/2L),y-
+ (ssize_t) (MagickMax(height,1)/2L),image->columns+MagickMax(width,1),
+ MagickMax(height,1),exception);
+ q=QueueCacheViewAuthenticPixels(statistic_view,0,y,statistic_image->columns, 1,exception);
+ if ((p == (const Quantum *) NULL) || (q == (Quantum *) NULL))
+ {
+ status=MagickFalse;
+ continue;
+ }
+ for (x=0; x < (ssize_t) statistic_image->columns; x++)
+ {
+ register ssize_t
+ i;
+
+ for (i=0; i < (ssize_t) GetPixelChannels(image); i++)
+ {
+ PixelChannel
+ channel;
+
+ PixelTrait
+ statistic_traits,
+ traits;
+
+ Quantum
+ pixel;
+
+ register const Quantum
+ *restrict pixels;
+
+ register ssize_t
+ u;
+
+ ssize_t
+ v;
+
+ traits=GetPixelChannelMapTraits(image,i);
+ channel=GetPixelChannelMapChannel(image,i);
+ statistic_traits=GetPixelChannelMapTraits(statistic_image,channel);
+ if ((traits == UndefinedPixelTrait) ||
+ (statistic_traits == UndefinedPixelTrait))
+ continue;
+ if ((statistic_traits & CopyPixelTrait) != 0)
+ {
+ SetPixelChannel(statistic_image,channel,p[center+i],q);
+ continue;
+ }
+ pixels=p;
+ ResetPixelList(pixel_list[id]);
+ for (v=0; v < (ssize_t) MagickMax(height,1); v++)
+ {
+ for (u=0; u < (ssize_t) MagickMax(width,1); u++)
+ {
+ InsertPixelList(image,pixels[i],pixel_list[id]);
+ pixels+=GetPixelChannels(image);
+ }
+ pixels+=image->columns*GetPixelChannels(image);
+ }
+ switch (type)
+ {
+ case GradientStatistic:
+ {
+ MagickRealType
+ maximum,
+ minimum;
+
+ GetMinimumPixelList(pixel_list[id],&pixel);
+ minimum=(MagickRealType) pixel;
+ GetMaximumPixelList(pixel_list[id],&pixel);
+ maximum=(MagickRealType) pixel;
+ pixel=ClampToQuantum(MagickAbsoluteValue(maximum-minimum));
+ break;
+ }
+ case MaximumStatistic:
+ {
+ GetMaximumPixelList(pixel_list[id],&pixel);
+ break;
+ }
+ case MeanStatistic:
+ {
+ GetMeanPixelList(pixel_list[id],&pixel);
+ break;
+ }
+ case MedianStatistic:
+ default:
+ {
+ GetMedianPixelList(pixel_list[id],&pixel);
+ break;
+ }
+ case MinimumStatistic:
+ {
+ GetMinimumPixelList(pixel_list[id],&pixel);
+ break;
+ }
+ case ModeStatistic:
+ {
+ GetModePixelList(pixel_list[id],&pixel);
+ break;
+ }
+ case NonpeakStatistic:
+ {
+ GetNonpeakPixelList(pixel_list[id],&pixel);
+ break;
+ }
+ case StandardDeviationStatistic:
+ {
+ GetStandardDeviationPixelList(pixel_list[id],&pixel);
+ break;
+ }
+ }
+ SetPixelChannel(statistic_image,channel,pixel,q);
+ }
+ p+=GetPixelChannels(image);
+ q+=GetPixelChannels(statistic_image);
+ }
+ if (SyncCacheViewAuthenticPixels(statistic_view,exception) == MagickFalse)
+ status=MagickFalse;
+ if (image->progress_monitor != (MagickProgressMonitor) NULL)
+ {
+ MagickBooleanType
+ proceed;
+
+#if defined(MAGICKCORE_OPENMP_SUPPORT)
+ #pragma omp critical (MagickCore_StatisticImage)
+#endif
+ proceed=SetImageProgress(image,StatisticImageTag,progress++,
+ image->rows);
+ if (proceed == MagickFalse)
+ status=MagickFalse;
+ }
+ }
+ statistic_view=DestroyCacheView(statistic_view);
+ image_view=DestroyCacheView(image_view);
+ pixel_list=DestroyPixelListThreadSet(pixel_list);
+ return(statistic_image);
+}
ArctanFunction
} MagickFunction;
+typedef enum
+{
+ UndefinedStatistic,
+ GradientStatistic,
+ MaximumStatistic,
+ MeanStatistic,
+ MedianStatistic,
+ MinimumStatistic,
+ ModeStatistic,
+ NonpeakStatistic,
+ StandardDeviationStatistic
+} StatisticType;
+
extern MagickExport ChannelStatistics
*GetImageStatistics(const Image *,ExceptionInfo *);
extern MagickExport Image
- *EvaluateImages(const Image *,const MagickEvaluateOperator,ExceptionInfo *);
+ *EvaluateImages(const Image *,const MagickEvaluateOperator,ExceptionInfo *),
+ *StatisticImage(const Image *,const StatisticType,const size_t,const size_t,
+ ExceptionInfo *);
extern MagickExport MagickBooleanType
EvaluateImage(Image *,const MagickEvaluateOperator,const double,
*/
#define MagickPackageName "ImageMagick"
#define MagickCopyright "Copyright (C) 1999-2011 ImageMagick Studio LLC"
-#define MagickSVNRevision "6118"
+#define MagickSVNRevision "6141"
#define MagickLibVersion 0x700
#define MagickLibVersionText "7.0.0"
#define MagickLibVersionNumber 7,0,0
#define MagickLibAddendum "-0"
#define MagickLibInterface 7
#define MagickLibMinInterface 7
-#define MagickReleaseDate "2011-12-06"
+#define MagickReleaseDate "2011-12-07"
#define MagickChangeDate "20110801"
#define MagickAuthoritativeURL "http://www.imagemagick.org"
#if defined(MAGICKCORE_OPENMP_SUPPORT)
print "Median Filter...\n";
$example=$model->Clone();
$example->Label('Median Filter');
-$example->MedianFilter();
+$example->MedianFilter('3x3');
push(@$images,$example);
print "Mode...\n";
*/
#undef LT_OBJDIR
+/* Define to the shared library suffix, say, ".dylib". */
+#undef LT_SHARED_EXT
+
/* Define if you have LZMA library */
#undef LZMA_DELEGATE
<configure name="VERSION" value="7.0.0"/>
<configure name="LIB_VERSION" value="0x700"/>
<configure name="LIB_VERSION_NUMBER" value="7,0,0,0"/>
- <configure name="SVN_REVISION" value="6118" />
- <configure name="RELEASE_DATE" value="2011-12-06"/>
+ <configure name="SVN_REVISION" value="6141" />
+ <configure name="RELEASE_DATE" value="2011-12-07"/>
<configure name="CONFIGURE" value="./configure "/>
<configure name="PREFIX" value="/usr/local"/>
<configure name="EXEC-PREFIX" value="/usr/local"/>
--includearch-dir=DIR ARCH specific include directory
--sharearch-dir=DIR ARCH specific config directory
--without-threads disable threads support
- --with-pic try to use only PIC/non-PIC objects [default=use
+ --with-pic[=PKGS] try to use only PIC/non-PIC objects [default=use
both]
--with-sysroot=DIR Search for dependent libraries within DIR
(or the compiler's sysroot if not specified).
MAGICK_LIBRARY_VERSION_INFO=$MAGICK_LIBRARY_CURRENT:$MAGICK_LIBRARY_REVISION:$MAGICK_LIBRARY_AGE
-MAGICK_SVN_REVISION=6118
+MAGICK_SVN_REVISION=6141
-macro_version='2.4'
-macro_revision='1.3293'
+macro_version='2.4.2'
+macro_revision='1.3337'
lt_cv_sys_max_cmd_len=196608
;;
+ os2*)
+ # The test takes a long time on OS/2.
+ lt_cv_sys_max_cmd_len=8192
+ ;;
+
osf*)
# Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
# due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
# If test is not a shell built-in, we'll probably end up computing a
# maximum length that is only half of the actual maximum length, but
# we can't tell.
- while { test "X"`func_fallback_echo "$teststring$teststring" 2>/dev/null` \
+ while { test "X"`env echo "$teststring$teststring" 2>/dev/null` \
= "X$teststring$teststring"; } >/dev/null 2>&1 &&
test $i != 17 # 1/2 MB should be enough
do
lt_cv_deplibs_check_method=pass_all
;;
-# This must be Linux ELF.
+# This must be glibc/ELF.
linux* | k*bsd*-gnu | kopensolaris*-gnu)
lt_cv_deplibs_check_method=pass_all
;;
if test -n "$RANLIB"; then
case $host_os in
openbsd*)
- old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib"
+ old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib"
;;
*)
- old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib"
+ old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib"
;;
esac
- old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib"
+ old_archive_cmds="$old_archive_cmds~\$RANLIB \$tool_oldlib"
fi
case $host_os in
# which start with @ or ?.
lt_cv_sys_global_symbol_pipe="$AWK '"\
" {last_section=section; section=\$ 3};"\
+" /^COFF SYMBOL TABLE/{for(i in hide) delete hide[i]};"\
" /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\
" \$ 0!~/External *\|/{next};"\
" / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\
CFLAGS="$SAVE_CFLAGS"
fi
;;
-sparc*-*solaris*)
+*-*solaris*)
# Find out which ABI we are using.
echo 'int i;' > conftest.$ac_ext
if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
case `/usr/bin/file conftest.o` in
*64-bit*)
case $lt_cv_prog_gnu_ld in
- yes*) LD="${LD-ld} -m elf64_sparc" ;;
+ yes*)
+ case $host in
+ i?86-*-solaris*)
+ LD="${LD-ld} -m elf_x86_64"
+ ;;
+ sparc*-*-solaris*)
+ LD="${LD-ld} -m elf64_sparc"
+ ;;
+ esac
+ # GNU ld 2.21 introduced _sol2 emulations. Use them if available.
+ if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then
+ LD="${LD-ld}_sol2"
+ fi
+ ;;
*)
if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then
LD="${LD-ld} -64"
$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
-dynamiclib -Wl,-single_module conftest.c 2>conftest.err
_lt_result=$?
- if test -f libconftest.dylib && test ! -s conftest.err && test $_lt_result = 0; then
+ # If there is a non-empty error log, and "single_module"
+ # appears in it, assume the flag caused a linker warning
+ if test -s conftest.err && $GREP single_module conftest.err; then
+ cat conftest.err >&5
+ # Otherwise, if the output was created with a 0 exit code from
+ # the compiler, it worked.
+ elif test -f libconftest.dylib && test $_lt_result -eq 0; then
lt_cv_apple_cc_single_mod=yes
else
cat conftest.err >&5
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_apple_cc_single_mod" >&5
$as_echo "$lt_cv_apple_cc_single_mod" >&6; }
+
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for -exported_symbols_list linker flag" >&5
$as_echo_n "checking for -exported_symbols_list linker flag... " >&6; }
if ${lt_cv_ld_exported_symbols_list+:} false; then :
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_exported_symbols_list" >&5
$as_echo "$lt_cv_ld_exported_symbols_list" >&6; }
+
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for -force_load linker flag" >&5
$as_echo_n "checking for -force_load linker flag... " >&6; }
if ${lt_cv_ld_force_load+:} false; then :
echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&5
$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err
_lt_result=$?
- if test -f conftest && test ! -s conftest.err && test $_lt_result = 0 && $GREP forced_load conftest 2>&1 >/dev/null; then
+ if test -s conftest.err && $GREP force_load conftest.err; then
+ cat conftest.err >&5
+ elif test -f conftest && test $_lt_result -eq 0 && $GREP forced_load conftest >/dev/null 2>&1 ; then
lt_cv_ld_force_load=yes
else
cat conftest.err >&5
# Check whether --with-pic was given.
if test "${with_pic+set}" = set; then :
- withval=$with_pic; pic_mode="$withval"
+ withval=$with_pic; lt_p=${PACKAGE-default}
+ case $withval in
+ yes|no) pic_mode=$withval ;;
+ *)
+ pic_mode=default
+ # Look at the argument we got. We use all the common list separators.
+ lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
+ for lt_pkg in $withval; do
+ IFS="$lt_save_ifs"
+ if test "X$lt_pkg" = "X$lt_p"; then
+ pic_mode=yes
+ fi
+ done
+ IFS="$lt_save_ifs"
+ ;;
+ esac
else
pic_mode=default
fi
+
+
+
+
case $cc_basename in
nvcc*) # Cuda Compiler Driver 2.2
lt_prog_compiler_wl='-Xlinker '
- lt_prog_compiler_pic='-Xcompiler -fPIC'
+ if test -n "$lt_prog_compiler_pic"; then
+ lt_prog_compiler_pic="-Xcompiler $lt_prog_compiler_pic"
+ fi
;;
esac
else
;;
*)
case `$CC -V 2>&1 | sed 5q` in
- *Sun\ F* | *Sun*Fortran*)
+ *Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [1-7].* | *Sun*Fortran*\ 8.[0-3]*)
# Sun Fortran 8.3 passes all unrecognized flags to the linker
lt_prog_compiler_pic='-KPIC'
lt_prog_compiler_static='-Bstatic'
lt_prog_compiler_wl=''
;;
+ *Sun\ F* | *Sun*Fortran*)
+ lt_prog_compiler_pic='-KPIC'
+ lt_prog_compiler_static='-Bstatic'
+ lt_prog_compiler_wl='-Qoption ld '
+ ;;
*Sun\ C*)
# Sun C 5.9
lt_prog_compiler_pic='-KPIC'
lt_prog_compiler_static='-Bstatic'
lt_prog_compiler_wl='-Wl,'
;;
+ *Intel*\ [CF]*Compiler*)
+ lt_prog_compiler_wl='-Wl,'
+ lt_prog_compiler_pic='-fPIC'
+ lt_prog_compiler_static='-static'
+ ;;
+ *Portland\ Group*)
+ lt_prog_compiler_wl='-Wl,'
+ lt_prog_compiler_pic='-fpic'
+ lt_prog_compiler_static='-Bstatic'
+ ;;
esac
;;
esac
hardcode_direct=no
hardcode_direct_absolute=no
hardcode_libdir_flag_spec=
- hardcode_libdir_flag_spec_ld=
hardcode_libdir_separator=
hardcode_minus_L=no
hardcode_shlibpath_var=unsupported
xlf* | bgf* | bgxlf* | mpixlf*)
# IBM XL Fortran 10.1 on PPC cannot create shared libs itself
whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive'
- hardcode_libdir_flag_spec=
- hardcode_libdir_flag_spec_ld='-rpath $libdir'
+ hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
archive_cmds='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib'
if test "x$supports_anon_versioning" = xyes; then
archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
# The linker will not automatically build a static lib if we build a DLL.
# _LT_TAGVAR(old_archive_from_new_cmds, )='true'
enable_shared_with_static_runtimes=yes
+ exclude_expsyms='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*'
export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1,DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
# Don't use ranlib
old_postinstall_cmds='chmod 644 $oldlib'
hardcode_shlibpath_var=unsupported
if test "$lt_cv_ld_force_load" = "yes"; then
whole_archive_flag_spec='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience ${wl}-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`'
+
else
whole_archive_flag_spec=''
fi
hardcode_shlibpath_var=no
;;
- freebsd1*)
- ld_shlibs=no
- ;;
-
# FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
# support. Future versions do this automatically, but an explicit c++rt0.o
# does not break anything, and helps significantly (at the cost of a little
;;
# Unfortunately, older versions of FreeBSD 2 do not have this feature.
- freebsd2*)
+ freebsd2.*)
archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
hardcode_direct=yes
hardcode_minus_L=yes
fi
if test "$with_gnu_ld" = no; then
hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
- hardcode_libdir_flag_spec_ld='+b $libdir'
hardcode_libdir_separator=:
hardcode_direct=yes
hardcode_direct_absolute=yes
-
-
-
-
-
case $host_os in
aix3*)
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
shlibpath_var=LIBPATH
;;
aix[4-9]*)
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
need_lib_prefix=no
need_version=no
hardcode_into_libs=yes
;;
bsdi[45]*)
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
need_version=no
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
soname_spec='${libname}${release}${shared_ext}$major'
;;
dgux*)
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
need_lib_prefix=no
need_version=no
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
shlibpath_var=LD_LIBRARY_PATH
;;
-freebsd1*)
- dynamic_linker=no
- ;;
-
freebsd* | dragonfly*)
# DragonFly does not have aout. When/if they implement a new
# versioning mechanism, adjust this.
objformat=`/usr/bin/objformat`
else
case $host_os in
- freebsd[123]*) objformat=aout ;;
+ freebsd[23].*) objformat=aout ;;
*) objformat=elf ;;
esac
fi
esac
shlibpath_var=LD_LIBRARY_PATH
case $host_os in
- freebsd2*)
+ freebsd2.*)
shlibpath_overrides_runpath=yes
;;
freebsd3.[01]* | freebsdelf3.[01]*)
;;
gnu*)
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
need_lib_prefix=no
need_version=no
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
soname_spec='${libname}${release}${shared_ext}$major'
shlibpath_var=LD_LIBRARY_PATH
+ shlibpath_overrides_runpath=no
hardcode_into_libs=yes
;;
haiku*)
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
need_lib_prefix=no
need_version=no
dynamic_linker="$host_os runtime_loader"
;;
interix[3-9]*)
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
need_lib_prefix=no
need_version=no
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
nonstopux*) version_type=nonstopux ;;
*)
if test "$lt_cv_prog_gnu_ld" = yes; then
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
else
version_type=irix
fi ;;
dynamic_linker=no
;;
-# This must be Linux ELF.
+# This must be glibc/ELF.
linux* | k*bsd*-gnu | kopensolaris*-gnu)
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
need_lib_prefix=no
need_version=no
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
;;
newsos6)
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
shlibpath_var=LD_LIBRARY_PATH
shlibpath_overrides_runpath=yes
;;
solaris*)
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
need_lib_prefix=no
need_version=no
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
;;
sysv4 | sysv4.3*)
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
soname_spec='${libname}${release}${shared_ext}$major'
shlibpath_var=LD_LIBRARY_PATH
sysv4*MP*)
if test -d /usr/nec ;then
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
soname_spec='$libname${shared_ext}.$major'
shlibpath_var=LD_LIBRARY_PATH
tpf*)
# TPF is a cross-target only. Preferred cross-host = GNU/Linux.
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
need_lib_prefix=no
need_version=no
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
;;
uts4*)
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
soname_spec='${libname}${release}${shared_ext}$major'
shlibpath_var=LD_LIBRARY_PATH
hardcode_direct_CXX=no
hardcode_direct_absolute_CXX=no
hardcode_libdir_flag_spec_CXX=
-hardcode_libdir_flag_spec_ld_CXX=
hardcode_libdir_separator_CXX=
hardcode_minus_L_CXX=no
hardcode_shlibpath_var_CXX=unsupported
hardcode_shlibpath_var_CXX=unsupported
if test "$lt_cv_ld_force_load" = "yes"; then
whole_archive_flag_spec_CXX='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience ${wl}-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`'
+
else
whole_archive_flag_spec_CXX=''
fi
esac
;;
- freebsd[12]*)
+ freebsd2.*)
# C++ shared libraries reported to be fairly broken before
# switch to ELF
ld_shlibs_CXX=no
case "$CC $CFLAGS " in #(
*\ -flto*\ *) CFLAGS="$CFLAGS -fno-lto" ;;
*\ -fwhopr*\ *) CFLAGS="$CFLAGS -fno-whopr" ;;
+*\ -fuse-linker-plugin*\ *) CFLAGS="$CFLAGS -fno-use-linker-plugin" ;;
esac
if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
;;
cygwin* | mingw* | cegcc*)
case $cc_basename in
- cl*) ;;
+ cl*)
+ exclude_expsyms_CXX='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*'
+ ;;
*)
export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.* //'\'' | sort | uniq > $export_symbols'
exclude_expsyms_CXX='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'
-
-
case $host_os in
aix3*)
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
shlibpath_var=LIBPATH
;;
aix[4-9]*)
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
need_lib_prefix=no
need_version=no
hardcode_into_libs=yes
;;
bsdi[45]*)
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
need_version=no
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
soname_spec='${libname}${release}${shared_ext}$major'
;;
dgux*)
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
need_lib_prefix=no
need_version=no
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
shlibpath_var=LD_LIBRARY_PATH
;;
-freebsd1*)
- dynamic_linker=no
- ;;
-
freebsd* | dragonfly*)
# DragonFly does not have aout. When/if they implement a new
# versioning mechanism, adjust this.
objformat=`/usr/bin/objformat`
else
case $host_os in
- freebsd[123]*) objformat=aout ;;
+ freebsd[23].*) objformat=aout ;;
*) objformat=elf ;;
esac
fi
esac
shlibpath_var=LD_LIBRARY_PATH
case $host_os in
- freebsd2*)
+ freebsd2.*)
shlibpath_overrides_runpath=yes
;;
freebsd3.[01]* | freebsdelf3.[01]*)
;;
gnu*)
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
need_lib_prefix=no
need_version=no
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
soname_spec='${libname}${release}${shared_ext}$major'
shlibpath_var=LD_LIBRARY_PATH
+ shlibpath_overrides_runpath=no
hardcode_into_libs=yes
;;
haiku*)
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
need_lib_prefix=no
need_version=no
dynamic_linker="$host_os runtime_loader"
;;
interix[3-9]*)
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
need_lib_prefix=no
need_version=no
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
nonstopux*) version_type=nonstopux ;;
*)
if test "$lt_cv_prog_gnu_ld" = yes; then
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
else
version_type=irix
fi ;;
dynamic_linker=no
;;
-# This must be Linux ELF.
+# This must be glibc/ELF.
linux* | k*bsd*-gnu | kopensolaris*-gnu)
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
need_lib_prefix=no
need_version=no
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
;;
newsos6)
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
shlibpath_var=LD_LIBRARY_PATH
shlibpath_overrides_runpath=yes
;;
solaris*)
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
need_lib_prefix=no
need_version=no
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
;;
sysv4 | sysv4.3*)
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
soname_spec='${libname}${release}${shared_ext}$major'
shlibpath_var=LD_LIBRARY_PATH
sysv4*MP*)
if test -d /usr/nec ;then
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
soname_spec='$libname${shared_ext}.$major'
shlibpath_var=LD_LIBRARY_PATH
tpf*)
# TPF is a cross-target only. Preferred cross-host = GNU/Linux.
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
need_lib_prefix=no
need_version=no
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
;;
uts4*)
- version_type=linux
+ version_type=linux # correct to gnu/linux during the next big refactor
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
soname_spec='${libname}${release}${shared_ext}$major'
shlibpath_var=LD_LIBRARY_PATH
+
+
ac_config_commands="$ac_config_commands libtool"
module=yes
eval libltdl_cv_shlibext=$shrext_cmds
+module=no
+eval libltdl_cv_shrext=$shrext_cmds
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libltdl_cv_shlibext" >&5
#define LT_MODULE_EXT "$libltdl_cv_shlibext"
_ACEOF
+fi
+if test "$libltdl_cv_shrext" != "$libltdl_cv_shlibext"; then
+
+cat >>confdefs.h <<_ACEOF
+#define LT_SHARED_EXT "$libltdl_cv_shrext"
+_ACEOF
+
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking which variable specifies run-time module search path" >&5
enable_static='`$ECHO "$enable_static" | $SED "$delay_single_quote_subst"`'
pic_mode='`$ECHO "$pic_mode" | $SED "$delay_single_quote_subst"`'
enable_fast_install='`$ECHO "$enable_fast_install" | $SED "$delay_single_quote_subst"`'
+PATH_SEPARATOR='`$ECHO "$PATH_SEPARATOR" | $SED "$delay_single_quote_subst"`'
host_alias='`$ECHO "$host_alias" | $SED "$delay_single_quote_subst"`'
host='`$ECHO "$host" | $SED "$delay_single_quote_subst"`'
host_os='`$ECHO "$host_os" | $SED "$delay_single_quote_subst"`'
allow_undefined_flag='`$ECHO "$allow_undefined_flag" | $SED "$delay_single_quote_subst"`'
no_undefined_flag='`$ECHO "$no_undefined_flag" | $SED "$delay_single_quote_subst"`'
hardcode_libdir_flag_spec='`$ECHO "$hardcode_libdir_flag_spec" | $SED "$delay_single_quote_subst"`'
-hardcode_libdir_flag_spec_ld='`$ECHO "$hardcode_libdir_flag_spec_ld" | $SED "$delay_single_quote_subst"`'
hardcode_libdir_separator='`$ECHO "$hardcode_libdir_separator" | $SED "$delay_single_quote_subst"`'
hardcode_direct='`$ECHO "$hardcode_direct" | $SED "$delay_single_quote_subst"`'
hardcode_direct_absolute='`$ECHO "$hardcode_direct_absolute" | $SED "$delay_single_quote_subst"`'
allow_undefined_flag_CXX='`$ECHO "$allow_undefined_flag_CXX" | $SED "$delay_single_quote_subst"`'
no_undefined_flag_CXX='`$ECHO "$no_undefined_flag_CXX" | $SED "$delay_single_quote_subst"`'
hardcode_libdir_flag_spec_CXX='`$ECHO "$hardcode_libdir_flag_spec_CXX" | $SED "$delay_single_quote_subst"`'
-hardcode_libdir_flag_spec_ld_CXX='`$ECHO "$hardcode_libdir_flag_spec_ld_CXX" | $SED "$delay_single_quote_subst"`'
hardcode_libdir_separator_CXX='`$ECHO "$hardcode_libdir_separator_CXX" | $SED "$delay_single_quote_subst"`'
hardcode_direct_CXX='`$ECHO "$hardcode_direct_CXX" | $SED "$delay_single_quote_subst"`'
hardcode_direct_absolute_CXX='`$ECHO "$hardcode_direct_absolute_CXX" | $SED "$delay_single_quote_subst"`'
AS \
DLLTOOL \
OBJDUMP \
+PATH_SEPARATOR \
NM \
LN_S \
lt_SP2NL \
allow_undefined_flag \
no_undefined_flag \
hardcode_libdir_flag_spec \
-hardcode_libdir_flag_spec_ld \
hardcode_libdir_separator \
exclude_expsyms \
include_expsyms \
allow_undefined_flag_CXX \
no_undefined_flag_CXX \
hardcode_libdir_flag_spec_CXX \
-hardcode_libdir_flag_spec_ld_CXX \
hardcode_libdir_separator_CXX \
exclude_expsyms_CXX \
include_expsyms_CXX \
# NOTE: Changes made to this file will be lost: look at ltmain.sh.
#
# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
-# 2006, 2007, 2008, 2009, 2010 Free Software Foundation,
-# Inc.
+# 2006, 2007, 2008, 2009, 2010, 2011 Free Software
+# Foundation, Inc.
# Written by Gordon Matzigkeit, 1996
#
# This file is part of GNU Libtool.
# Whether or not to optimize for fast installation.
fast_install=$enable_fast_install
+# The PATH separator for the build system.
+PATH_SEPARATOR=$lt_PATH_SEPARATOR
+
# The host system.
host_alias=$host_alias
host=$host
# This must work even if \$libdir does not exist
hardcode_libdir_flag_spec=$lt_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.
-hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld
-
# Whether we need a single "-rpath" flag with a separated argument.
hardcode_libdir_separator=$lt_hardcode_libdir_separator
# This must work even if \$libdir does not exist
hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec_CXX
-# If ld is used when linking, flag to hardcode \$libdir into a binary
-# during linking. This must work even if \$libdir does not exist.
-hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld_CXX
-
# Whether we need a single "-rpath" flag with a separated argument.
hardcode_libdir_separator=$lt_hardcode_libdir_separator_CXX
# NOTE: Changes made to this file will be lost: look at ltmain.sh.
#
# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
-# 2006, 2007, 2008, 2009, 2010 Free Software Foundation,
-# Inc.
+# 2006, 2007, 2008, 2009, 2010, 2011 Free Software
+# Foundation, Inc.
# Written by Gordon Matzigkeit, 1996
#
# This file is part of GNU Libtool.
ECHO="printf %s\\n"
# Which release of libtool.m4 was used?
-macro_version=2.4
-macro_revision=1.3293
+macro_version=2.4.2
+macro_revision=1.3337
# Assembler program.
AS="as"
# Whether or not to optimize for fast installation.
fast_install=yes
+# The PATH separator for the build system.
+PATH_SEPARATOR=":"
+
# The host system.
host_alias=
host=x86_64-unknown-linux-gnu
# Commands used to install an old-style archive.
RANLIB="ranlib"
-old_postinstall_cmds="chmod 644 \$oldlib~\$RANLIB \$oldlib"
+old_postinstall_cmds="chmod 644 \$oldlib~\$RANLIB \$tool_oldlib"
old_postuninstall_cmds=""
# Whether to use a lock for old archive extraction.
reload_cmds="\$LD\$reload_flag -o \$output\$reload_objs"
# Commands used to build an old-style archive.
-old_archive_cmds="\$AR \$AR_FLAGS \$oldlib\$oldobjs~\$RANLIB \$oldlib"
+old_archive_cmds="\$AR \$AR_FLAGS \$oldlib\$oldobjs~\$RANLIB \$tool_oldlib"
# A language specific compiler.
CC="gcc -std=gnu99 -std=gnu99"
# This must work even if $libdir does not exist
hardcode_libdir_flag_spec="\${wl}-rpath \${wl}\$libdir"
-# If ld is used when linking, flag to hardcode $libdir into a binary
-# during linking. This must work even if $libdir does not exist.
-hardcode_libdir_flag_spec_ld=""
-
# Whether we need a single "-rpath" flag with a separated argument.
hardcode_libdir_separator=""
reload_cmds="\$LD\$reload_flag -o \$output\$reload_objs"
# Commands used to build an old-style archive.
-old_archive_cmds="\$AR \$AR_FLAGS \$oldlib\$oldobjs~\$RANLIB \$oldlib"
+old_archive_cmds="\$AR \$AR_FLAGS \$oldlib\$oldobjs~\$RANLIB \$tool_oldlib"
# A language specific compiler.
CC="g++"
# This must work even if $libdir does not exist
hardcode_libdir_flag_spec="\${wl}-rpath \${wl}\$libdir"
-# If ld is used when linking, flag to hardcode $libdir into a binary
-# during linking. This must work even if $libdir does not exist.
-hardcode_libdir_flag_spec_ld=""
-
# Whether we need a single "-rpath" flag with a separated argument.
hardcode_libdir_separator=""