@@ -211,23 +211,12 @@ if(NOT EXT_GD_EXTERNAL)
211211 libgd/wbmp.h
212212 )
213213
214- set (HAVE_GD_BUNDLED 1 CACHE INTERNAL "Whether the bundled libgd is used" )
214+ set (HAVE_GD_BUNDLED 1)
215215
216216 # With bundled GD library these are always available.
217- set (
218- HAVE_GD_PNG 1
219- CACHE INTERNAL "Whether the PNG functionality can be used with libgd"
220- )
221-
222- set (
223- HAVE_GD_BMP 1
224- CACHE INTERNAL "Whether the BMP functionality can be used with libgd"
225- )
226-
227- set (
228- HAVE_GD_TGA 1
229- CACHE INTERNAL "Whether the TGA functionality can be used with libgd"
230- )
217+ set (HAVE_GD_PNG 1)
218+ set (HAVE_GD_BMP 1)
219+ set (HAVE_GD_TGA 1)
231220
232221 php_search_libraries(
233222 floorf
@@ -269,7 +258,7 @@ if(NOT EXT_GD_EXTERNAL)
269258
270259 target_link_libraries (php_gd PRIVATE PNG::PNG)
271260
272- set (HAVE_LIBPNG 1 CACHE INTERNAL "Whether the libpng is available" )
261+ set (HAVE_LIBPNG 1)
273262
274263 if (EXT_GD_AVIF)
275264 find_package (libavif 0.8.2)
@@ -282,8 +271,8 @@ if(NOT EXT_GD_EXTERNAL)
282271
283272 target_link_libraries (php_gd PRIVATE libavif::libavif)
284273
285- set (HAVE_LIBAVIF 1 CACHE INTERNAL "Whether the libavif is available" )
286- set (HAVE_GD_AVIF 1 CACHE INTERNAL "Whether the AVIF support is enabled" )
274+ set (HAVE_LIBAVIF 1)
275+ set (HAVE_GD_AVIF 1)
287276 endif ()
288277
289278 if (EXT_GD_WEBP)
@@ -297,8 +286,8 @@ if(NOT EXT_GD_EXTERNAL)
297286
298287 target_link_libraries (php_gd PRIVATE WebP::WebP)
299288
300- set (HAVE_LIBWEBP 1 CACHE INTERNAL "Whether the libwebp is available" )
301- set (HAVE_GD_WEBP 1 CACHE INTERNAL "Whether the WebP support is enabled" )
289+ set (HAVE_LIBWEBP 1)
290+ set (HAVE_GD_WEBP 1)
302291 endif ()
303292
304293 if (EXT_GD_JPEG)
@@ -312,8 +301,8 @@ if(NOT EXT_GD_EXTERNAL)
312301
313302 target_link_libraries (php_gd PRIVATE JPEG::JPEG)
314303
315- set (HAVE_LIBJPEG 1 CACHE INTERNAL "Whether the libjpeg is available" )
316- set (HAVE_GD_JPG 1 CACHE INTERNAL "Whether the JPEG support is enabled" )
304+ set (HAVE_LIBJPEG 1)
305+ set (HAVE_GD_JPG 1)
317306 endif ()
318307
319308 if (EXT_GD_XPM)
@@ -327,8 +316,8 @@ if(NOT EXT_GD_EXTERNAL)
327316
328317 target_link_libraries (php_gd PRIVATE XPM::XPM)
329318
330- set (HAVE_XPM 1 CACHE INTERNAL "Whether the libXpm library is available" )
331- set (HAVE_GD_XPM 1 CACHE INTERNAL "Whether the XPM support is enabled" )
319+ set (HAVE_XPM 1)
320+ set (HAVE_GD_XPM 1)
332321 endif ()
333322
334323 if (EXT_GD_FREETYPE)
@@ -342,27 +331,13 @@ if(NOT EXT_GD_EXTERNAL)
342331
343332 target_link_libraries (php_gd PRIVATE Freetype::Freetype)
344333
345- set (
346- HAVE_LIBFREETYPE 1
347- CACHE INTERNAL "Whether the FreeType library is available"
348- )
349-
350- set (
351- HAVE_GD_FREETYPE 1
352- CACHE INTERNAL "Whether the FreeType support is enabled"
353- )
334+ set (HAVE_LIBFREETYPE 1)
335+ set (HAVE_GD_FREETYPE 1)
354336 endif ()
355337
356338 if (EXT_GD_JIS)
357- set (
358- JISX0208 1
359- CACHE INTERNAL "Whether the JIS-mapped Japanese font support is available"
360- )
361-
362- set (
363- USE_GD_JISX0208 1
364- CACHE INTERNAL "Whether the JIS-mapped Japanese font support is enabled"
365- )
339+ set (JISX0208 1)
340+ set (USE_GD_JISX0208 1)
366341 endif ()
367342
368343 # Do sanity check when all required packages are found.
0 commit comments