-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcommon.shi.in
More file actions
133 lines (122 loc) · 4.03 KB
/
Copy pathcommon.shi.in
File metadata and controls
133 lines (122 loc) · 4.03 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
# -*- shell-script -*-
# Copyright (C) 2012-2020 GraphicsMagick Group
# Definitions of optional features and configuration values for this build.
# Intended for use by test scripts.
MAGICK_FEATURES='@MAGICK_FEATURES@'
top_srcdir='@abs_top_srcdir@'
top_builddir='@abs_top_builddir@'
# Populate a set of shell variables with a variable per feature
# This is used to implement a poor-man's hash map.
for feature in ${MAGICK_FEATURES}
do
eval MAGICK_FEATURE_${feature}=yes
done
set -a
TOP_SRCDIR_NATIVE='@top_srcdir_native@'
GM="${MEMCHECK} @abs_top_builddir@/utilities/gm"
LD_LIBRARY_PATH="@abs_top_builddir@/magick/.libs:${LD_LIBRARY_PATH}"
MAGICK_CODER_MODULE_PATH='@abs_top_builddir@/coders'
MAGICK_CONFIGURE_PATH='@abs_top_builddir@/config:@abs_top_srcdir@/config'
MAGICK_FILTER_MODULE_PATH='@abs_top_builddir@/filters'
MAGICK_CODER_STABILITY='BROKEN'
MAGICK_FONT='@abs_top_srcdir@/PerlMagick/demo/Generic.ttf'
PATH="@abs_top_builddir@/utilities:${PATH}"
MIFF_COMPRESS=none
if [ "${MAGICK_FEATURE_BZLIB}" = "yes" ] ; then
MIFF_COMPRESS=bzip
elif [ "${MAGICK_FEATURE_ZLIB}" = "yes" ] ; then
MIFF_COMPRESS=zip
fi
# Number of bits in a pixel Quantum (8/16/32)
QuantumDepth=@QuantumDepth@
# Memory limit (in MB) for a 'Q8' build
Q8_MEMORY_LIMIT=128
# Apply some resource limits (FAX/G4 need 2592x3508 pixel image!)
if test -z "$MAGICK_LIMIT_MEMORY" ; then
export MAGICK_LIMIT_MEMORY=`expr $Q8_MEMORY_LIMIT '*' '(' $QuantumDepth / 8 ')'`MB
fi
if test -z "$MAGICK_LIMIT_WIDTH" ; then
export MAGICK_LIMIT_WIDTH=2592
fi
if test -z "$MAGICK_LIMIT_HEIGHT" ; then
export MAGICK_LIMIT_HEIGHT=3508
fi
if test -z "$MAGICK_LIMIT_DISK" ; then
export MAGICK_LIMIT_DISK=0
fi
if test -z "$MAGICK_LIMIT_WRITE" ; then
# File write/read limits are based on checking output sizes of the
# largest files. This means that tests may fail if these files
# become larger. The two largest files are:
#
# utilities/tests/HaldClutIdentity_out.miff
# utilities/tests/montage_out.miff
printf "Evaluating MAGICK_LIMIT_WRITE, MIFF_COMPRESS=${MIFF_COMPRESS}\n"
case "${MIFF_COMPRESS}" in
none)
case ${QuantumDepth} in
8)
MAGICK_LIMIT_WRITE=8.6MB
;;
16)
MAGICK_LIMIT_WRITE=18MB
;;
32)
MAGICK_LIMIT_WRITE=35MB
;;
esac
;;
rle)
case ${QuantumDepth} in
8)
MAGICK_LIMIT_WRITE=12MB
;;
16)
MAGICK_LIMIT_WRITE=20MB
;;
32)
MAGICK_LIMIT_WRITE=38MB
;;
esac
;;
zip)
case ${QuantumDepth} in
8)
MAGICK_LIMIT_WRITE=6.0MB
;;
16)
MAGICK_LIMIT_WRITE=7.3MB
;;
32)
MAGICK_LIMIT_WRITE=6.3MB
;;
esac
;;
bzip)
case ${QuantumDepth} in
8)
MAGICK_LIMIT_WRITE=3.2MB
;;
16)
MAGICK_LIMIT_WRITE=4.6MB
;;
32)
MAGICK_LIMIT_WRITE=5.6MB
;;
esac
;;
esac
export MAGICK_LIMIT_WRITE
if test -z "$MAGICK_LIMIT_READ" ; then
export MAGICK_LIMIT_READ=$MAGICK_LIMIT_WRITE
fi
fi
#if test -z "$MAGICK_LIMIT_READ" ; then
# export MAGICK_LIMIT_READ=36MB
#fi
# Enable debug traces for exceptions
if test -z "MAGICK_DEBUG" ; then
export MAGICK_DEBUG=exception
fi
printf "Resource Limits: MAGICK_LIMIT_MEMORY=%s MAGICK_LIMIT_WIDTH=%s MAGICK_LIMIT_HEIGHT=%s MAGICK_LIMIT_DISK=%s MAGICK_LIMIT_READ=%s MAGICK_LIMIT_WRITE=%s\n\n" "$MAGICK_LIMIT_MEMORY" "$MAGICK_LIMIT_WIDTH" "$MAGICK_LIMIT_HEIGHT" "$MAGICK_LIMIT_DISK" "$MAGICK_LIMIT_READ" "$MAGICK_LIMIT_WRITE"
set +a