[packages] vips: Bump to 7.28.9
[packages.git] / libs / vips / patches / 001-no_cpp.patch
1 diff -u --recursive vips-7.28.9-vanilla/configure.in vips-7.28.9/configure.in
2 --- vips-7.28.9-vanilla/configure.in    2012-07-14 22:35:08.209029299 -0500
3 +++ vips-7.28.9/configure.in    2012-07-14 22:36:25.634927858 -0500
4 @@ -182,7 +182,6 @@
5  AC_PROG_AWK
6  AC_PROG_CC
7  AC_PROG_CC_STDC
8 -AC_PROG_CXX
9  AC_C_CONST
10  AC_C_RESTRICT
11  AC_PROG_RANLIB
12 @@ -190,45 +189,6 @@
13  AC_PROG_LN_S
14  AM_WITH_DMALLOC
15  
16 -# vips_PROG_CXX_WORKS
17 -# Check whether the C++ compiler works.
18 -AC_DEFUN([vips_PROG_CXX_WORKS],
19 -  [AC_REQUIRE([AC_PROG_CXX])dnl
20 -   AC_CACHE_CHECK([whether the C++ compiler works],
21 -   [vips_cv_prog_cxx_works],
22 -   [AC_LANG_PUSH([C++])
23 -    AC_LINK_IFELSE([AC_LANG_PROGRAM([], [])],
24 -                   [vips_cv_prog_cxx_works=yes],
25 -                   [vips_cv_prog_cxx_works=no])
26 -    AC_LANG_POP([C++])])
27 -])
28 -
29 -# option to build without C++
30 -# handy for some embedded applications
31 -# also, including C++ source causes link problems on some
32 -# platforms, so have an option to disable it
33 -AC_ARG_ENABLE(cxx, 
34 -  AS_HELP_STRING([--enable-cxx], [build C++ components (default: test)]))
35 -
36 -if test x"$enable_cxx" != x"no"; then
37 -  vips_PROG_CXX_WORKS
38 -  if test x"$vips_cv_prog_cxx_works" = x"yes"; then 
39 -    AC_DEFINE(ENABLE_CXX,1,[build C++ components])
40 -    AM_CONDITIONAL(ENABLE_CXX, true)
41 -    # need -lstdc++ for (eg.) the C++ format loaders
42 -    # this gets added to vips-7.xx.pc to help mingw and friends link programs
43 -    # using libvips
44 -    VIPS_CXX_LIBS="-lstdc++"
45 -    enable_cxx=yes
46 -  fi
47 -fi
48 -
49 -if test x"$enable_cxx" != x"yes"; then
50 -  AM_CONDITIONAL(ENABLE_CXX, false)
51 -  VIPS_CXX_LIBS=""
52 -  enable_cxx=no
53 -fi
54 -
55  # we need a fully expanded version of $libdir
56  # without this we get something like
57  #    define VIPS_LIBDIR ${exec_prefix}/lib
58 @@ -681,7 +641,6 @@
59  AC_SUBST(VIPS_CFLAGS)
60  AC_SUBST(VIPS_INCLUDES)
61  AC_SUBST(VIPS_LIBS)
62 -AC_SUBST(VIPS_CXX_LIBS)
63  AC_SUBST(PACKAGES_USED)
64  
65  # you'd think we could have 
66 @@ -689,14 +648,12 @@
67  # in AC_OUTPUT, but that seems to break for some combinations of sh/m4
68  AC_OUTPUT([
69         vips-7.28.pc
70 -       vipsCC-7.28.pc
71         Makefile 
72         libvips/include/vips/version.h 
73         libvips/include/Makefile 
74         libvips/include/vips/Makefile 
75         libvips/Makefile 
76         libvips/arithmetic/Makefile 
77 -       libvips/cimg/Makefile 
78         libvips/colour/Makefile 
79         libvips/conversion/Makefile 
80         libvips/convolution/Makefile 
81 @@ -711,9 +668,6 @@
82         libvips/other/Makefile 
83         libvips/resample/Makefile 
84         libvips/video/Makefile 
85 -       libvipsCC/include/Makefile 
86 -       libvipsCC/include/vips/Makefile 
87 -       libvipsCC/Makefile 
88         tools/Makefile 
89         tools/batch_crop 
90         tools/batch_image_convert 
91 @@ -721,7 +675,6 @@
92         tools/light_correct 
93         tools/shrink_width 
94         swig/Makefile 
95 -       swig/vipsCC/Makefile 
96         swig/python/setup.py 
97         man/Makefile
98         doc/Makefile
99 diff -u --recursive vips-7.28.9-vanilla/libvips/Makefile.am vips-7.28.9/libvips/Makefile.am
100 --- vips-7.28.9-vanilla/libvips/Makefile.am     2012-07-14 22:35:08.206029420 -0500
101 +++ vips-7.28.9/libvips/Makefile.am     2012-07-14 22:37:24.446571912 -0500
102 @@ -1,14 +1,4 @@
103  # only build in the cimg dir if C++ is enabled
104 -if ENABLE_CXX
105 -C_COMPILE_DIR = cimg
106 -C_DIST_DIR =
107 -C_LIB = cimg/libcimg.la
108 -else
109 -C_COMPILE_DIR =
110 -C_DIST_DIR = cimg
111 -C_LIB = 
112 -endif
113 -
114  SUBDIRS = \
115         include \
116         foreign \
117 @@ -18,7 +8,6 @@
118         conversion \
119         deprecated \
120         convolution \
121 -       $(C_COMPILE_DIR) \
122         freq_filt \
123         histograms_lut \
124         inplace \
125 @@ -34,14 +23,6 @@
126  # empty means default to C linking
127  libvips_la_SOURCES = 
128  
129 -# if we have C++ components enabled, make sure we link the top-level with c++
130 -#
131 -# sadly the if/endif isn't enough to stop automake detecting a c++ link even
132 -# when c++ is disabled ... comment out this line if you have linking problems
133 -if ENABLE_CXX
134 -nodist_EXTRA_libvips_la_SOURCES = cimg/dummy2.cc
135 -endif
136 -
137  # DLLs need dependant libs there too ... put @VIPS_LIBS@ at the end
138  libvips_la_LIBADD = \
139         resample/libresample.la \
140 @@ -50,7 +31,6 @@
141         conversion/libconversion.la \
142         convolution/libconvolution.la \
143         deprecated/libdeprecated.la \
144 -       $(C_LIB) \
145         foreign/libforeign.la \
146         freq_filt/libfreq_filt.la \
147         histograms_lut/libhistograms_lut.la \
148 @@ -62,17 +42,10 @@
149         video/libvideo.la \
150         @VIPS_LIBS@
151  
152 -if ENABLE_CXX
153 -libvips_la_LIBADD += @VIPS_CXX_LIBS@
154 -endif
155 -
156  libvips_la_LDFLAGS = \
157         -no-undefined \
158         -version-info @LIBRARY_CURRENT@:@LIBRARY_REVISION@:@LIBRARY_AGE@ 
159  
160 -EXTRA_DIST = \
161 -       $(C_DIST_DIR)
162 -
163  CLEANFILES = 
164  
165  -include $(INTROSPECTION_MAKEFILE)
166 diff -u --recursive vips-7.28.9-vanilla/libvips/resample/Makefile.am vips-7.28.9/libvips/resample/Makefile.am
167 --- vips-7.28.9-vanilla/libvips/resample/Makefile.am    2012-07-14 22:35:08.191030020 -0500
168 +++ vips-7.28.9/libvips/resample/Makefile.am    2012-07-14 22:37:49.470569578 -0500
169 @@ -2,22 +2,6 @@
170  # you'd think we could just define a couple of variables, but that seems to
171  # confuse libtool and make it link the library with g++
172  # instead, have two completely different paths
173 -if ENABLE_CXX
174 -
175 -libresample_la_SOURCES = \
176 -       im_affine.c \
177 -       interpolate.c \
178 -       im_shrink.c \
179 -       im_rightshift_size.c \
180 -       transform.c \
181 -       resample_dispatch.c \
182 -       bicubic.cpp \
183 -       lbb.cpp \
184 -       nohalo.cpp \
185 -       vsqbs.cpp \
186 -       templates.h 
187 -
188 -else
189  
190  libresample_la_SOURCES = \
191         im_affine.c \
192 @@ -27,15 +11,6 @@
193         transform.c \
194         resample_dispatch.c 
195  
196 -EXTRA_DIST = \
197 -       bicubic.cpp \
198 -       lbb.cpp \
199 -       nohalo.cpp \
200 -       vsqbs.cpp \
201 -       templates.h 
202 -
203 -endif
204 -
205  noinst_LTLIBRARIES = libresample.la
206  
207  INCLUDES = -I${top_srcdir}/libvips/include @VIPS_CFLAGS@ @VIPS_INCLUDES@ 
208 diff -u --recursive vips-7.28.9-vanilla/Makefile.am vips-7.28.9/Makefile.am
209 --- vips-7.28.9-vanilla/Makefile.am     2012-07-14 22:35:08.220028859 -0500
210 +++ vips-7.28.9/Makefile.am     2012-07-14 22:38:43.217417048 -0500
211 @@ -1,43 +1,17 @@
212 -
213 -# turn off libvipsCC if C++ is disabled
214 -if ENABLE_CXX
215 -C_COMPILE_DIR = libvipsCC
216 -C_DIST_DIR =
217 -C_PKGCONFIG = vipsCC-7.${VIPS_MINOR_VERSION}.pc
218 -
219 -# turn on Python if we can (requires C++)
220 -if HAVE_PYTHON
221 -P_COMPILE_DIR = swig
222 -P_DIST_DIR =
223 -endif
224 -
225 -else
226 -C_COMPILE_DIR =
227 -C_DIST_DIR = libvipsCC 
228 -C_PKGCONFIG =
229 -P_COMPILE_DIR =
230 -P_DIST_DIR = swig
231 -endif
232 -
233  SUBDIRS = \
234         libvips \
235         tools \
236         po \
237         man \
238 -       doc \
239 -       $(C_COMPILE_DIR) \
240 -       $(P_COMPILE_DIR) 
241 +       doc
242  
243  EXTRA_DIST = \
244         m4 \
245         benchmark \
246         bootstrap.sh \
247         vips-7.${VIPS_MINOR_VERSION}.pc.in \
248 -       vipsCC-7.${VIPS_MINOR_VERSION}.pc.in \
249         acinclude.m4 \
250 -       depcomp \
251 -       $(C_DIST_DIR) \
252 -       $(P_DIST_DIR)
253 +       depcomp
254  
255  pkgconfigdir = $(libdir)/pkgconfig
256  pkgconfig_DATA = vips-7.${VIPS_MINOR_VERSION}.pc $(C_PKGCONFIG)
257 diff -u --recursive vips-7.28.9-vanilla/tools/Makefile.am vips-7.28.9/tools/Makefile.am
258 --- vips-7.28.9-vanilla/tools/Makefile.am       2012-07-14 22:35:08.221028819 -0500
259 +++ vips-7.28.9/tools/Makefile.am       2012-07-14 22:40:51.397283833 -0500
260 @@ -16,9 +16,6 @@
261  INCLUDES = -I${top_srcdir}/libvips/include @VIPS_CFLAGS@ @VIPS_INCLUDES@
262  AM_LDFLAGS = @LDFLAGS@ 
263  LDADD = @VIPS_CFLAGS@ ${top_builddir}/libvips/libvips.la @VIPS_LIBS@
264 -if ENABLE_CXX
265 -LDADD += @VIPS_CXX_LIBS@
266 -endif
267  
268  bin_SCRIPTS = \
269         light_correct \
270 diff -u --recursive vips-7.28.9-vanilla/vips-7.28.pc.in vips-7.28.9/vips-7.28.pc.in
271 --- vips-7.28.9-vanilla/vips-7.28.pc.in 2012-07-14 22:35:08.208029340 -0500
272 +++ vips-7.28.9/vips-7.28.pc.in 2012-07-14 22:41:03.591795535 -0500
273 @@ -7,5 +7,5 @@
274  Description: Image processing library
275  Version: @VERSION@
276  Requires: @PACKAGES_USED@
277 -Libs: -L${libdir} -lvips @VIPS_LIBS@ @VIPS_CXX_LIBS@
278 +Libs: -L${libdir} -lvips @VIPS_LIBS@
279  Cflags: -I${includedir}