Skip to content

Commit 59ec80c

Browse files
committed
- MFH: [DOC] always enable imagerotate (bundled or system gd)
1 parent e9d2892 commit 59ec80c

File tree

7 files changed

+567
-543
lines changed

7 files changed

+567
-543
lines changed

ext/gd/config.m4

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -269,7 +269,8 @@ if test "$PHP_GD" = "yes"; then
269269
libgd/gdxpm.c libgd/gdfontt.c libgd/gdfonts.c libgd/gdfontmb.c libgd/gdfontl.c \
270270
libgd/gdfontg.c libgd/gdtables.c libgd/gdft.c libgd/gdcache.c libgd/gdkanji.c \
271271
libgd/wbmp.c libgd/gd_wbmp.c libgd/gdhelpers.c libgd/gd_topal.c libgd/gd_gif_in.c \
272-
libgd/xbm.c libgd/gd_gif_out.c libgd/gd_security.c libgd/gd_filter.c libgd/gd_pixelate.c libgd/gd_arc.c"
272+
libgd/xbm.c libgd/gd_gif_out.c libgd/gd_security.c libgd/gd_filter.c \
273+
libgd/gd_pixelate.c libgd/gd_arc.c libgd/gd_rotate.c"
273274

274275
dnl check for fabsf and floorf which are available since C99
275276
AC_CHECK_FUNCS(fabsf floorf)
@@ -342,7 +343,7 @@ else
342343

343344
if test "$PHP_GD" != "no"; then
344345
GD_MODULE_TYPE=external
345-
extra_sources="gdcache.c libgd/gd_compat.c libgd/gd_filter.c libgd/gd_pixelate.c libgd/gd_arc.c"
346+
extra_sources="gdcache.c libgd/gd_compat.c libgd/gd_filter.c libgd/gd_pixelate.c libgd/gd_arc.c libgd/gd_rotate.c"
346347

347348
dnl Various checks for GD features
348349
PHP_GD_ZLIB

ext/gd/config.w32

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,8 @@ if (PHP_GD != "no") {
3333
gdcache.c gdfontg.c gdfontl.c gdfontmb.c gdfonts.c gdfontt.c \
3434
gdft.c gd_gd2.c gd_gd.c gd_gif_in.c gd_gif_out.c gdhelpers.c gd_io.c gd_io_dp.c \
3535
gd_io_file.c gd_io_ss.c gd_jpeg.c gdkanji.c gd_png.c gd_ss.c \
36-
gdtables.c gd_topal.c gd_wbmp.c gdxpm.c wbmp.c xbm.c gd_security.c gd_filter.c gd_pixelate.c gd_arc.c", "gd");
36+
gdtables.c gd_topal.c gd_wbmp.c gdxpm.c wbmp.c xbm.c gd_security.c \
37+
gd_filter.c gd_pixelate.c gd_arc.c gd_rotate.c", "gd");
3738
AC_DEFINE('HAVE_LIBGD', 1, 'GD support');
3839
ADD_FLAG("CFLAGS_GD", " \
3940
/D HAVE_GD_DYNAMIC_CTX_EX=1 \

ext/gd/gd.c

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -300,14 +300,12 @@ ZEND_BEGIN_ARG_INFO(arginfo_imagegrabscreen, 0)
300300
ZEND_END_ARG_INFO()
301301
#endif
302302

303-
#ifdef HAVE_GD_BUNDLED
304303
ZEND_BEGIN_ARG_INFO_EX(arginfo_imagerotate, 0, 0, 3)
305304
ZEND_ARG_INFO(0, im)
306305
ZEND_ARG_INFO(0, angle)
307306
ZEND_ARG_INFO(0, bgdcolor)
308307
ZEND_ARG_INFO(0, ignoretransparent)
309308
ZEND_END_ARG_INFO()
310-
#endif
311309

312310
#if HAVE_GD_IMAGESETTILE
313311
ZEND_BEGIN_ARG_INFO(arginfo_imagesettile, 0)
@@ -930,8 +928,9 @@ const zend_function_entry gd_functions[] = {
930928
PHP_FE(imagegrabscreen, arginfo_imagegrabscreen)
931929
#endif
932930

933-
#ifdef HAVE_GD_BUNDLED
934931
PHP_FE(imagerotate, arginfo_imagerotate)
932+
933+
#ifdef HAVE_GD_BUNDLED
935934
PHP_FE(imageantialias, arginfo_imageantialias)
936935
#endif
937936

@@ -2104,7 +2103,6 @@ PHP_FUNCTION(imagegrabscreen)
21042103
/* }}} */
21052104
#endif /* PHP_WIN32 */
21062105

2107-
#ifdef HAVE_GD_BUNDLED
21082106
/* {{{ proto resource imagerotate(resource src_im, float angle, int bgdcolor [, int ignoretransparent])
21092107
Rotate an image using a custom angle */
21102108
PHP_FUNCTION(imagerotate)
@@ -2130,7 +2128,6 @@ PHP_FUNCTION(imagerotate)
21302128
}
21312129
}
21322130
/* }}} */
2133-
#endif
21342131

21352132
#if HAVE_GD_IMAGESETTILE
21362133
/* {{{ proto bool imagesettile(resource image, resource tile)

0 commit comments

Comments
 (0)