comparison configure @ 6169:b9d4d6d80369

- keeps configure from generating a core when a buggy giflib is found - swaps -lgif with -lungif to give compression preference over uncompressed by Joey Parrish <joey@yunamusic.com>
author arpi
date Thu, 23 May 2002 20:38:27 +0000
parents bb0679dd3195
children 26a980dbc9a5
comparison
equal deleted inserted replaced
6168:741712dcfa0d 6169:b9d4d6d80369
2395 #include <gif_lib.h> 2395 #include <gif_lib.h>
2396 int main(void) { 2396 int main(void) {
2397 return 0; 2397 return 0;
2398 } 2398 }
2399 EOF 2399 EOF
2400 if cc_check -lungif && "$TMPO" >> "$TMPLOG" ; then 2400 if cc_check -lgif && "$TMPO" >> "$TMPLOG" ; then
2401 _gif=yes
2402 _ld_gif="-lgif"
2403 elif cc_check -lungif && "$TMPO" >> "$TMPLOG" ; then
2401 _gif=yes 2404 _gif=yes
2402 _ld_gif="-lungif" 2405 _ld_gif="-lungif"
2403 elif cc_check -lgif && "$TMPO" >> "$TMPLOG" ; then 2406 elif cc_check -lgif $_ld_x11 && "$TMPO" >> "$TMPLOG" ; then
2404 _gif=yes 2407 _gif=yes
2405 _ld_gif="-lgif" 2408 _ld_gif="-lgif $_ld_x11"
2406 elif cc_check -lungif $_ld_x11 && "$TMPO" >> "$TMPLOG" ; then 2409 elif cc_check -lungif $_ld_x11 && "$TMPO" >> "$TMPLOG" ; then
2407 _gif=yes 2410 _gif=yes
2408 _ld_gif="-lungif $_ld_x11" 2411 _ld_gif="-lungif $_ld_x11"
2409 elif cc_check -lgif $_ld_x11 && "$TMPO" >> "$TMPLOG" ; then
2410 _gif=yes
2411 _ld_gif="-lgif $_ld_x11"
2412 fi 2412 fi
2413 fi 2413 fi
2414 2414
2415 if test "$_gif" = yes ; then 2415 if test "$_gif" = yes ; then
2416 _def_gif='#define HAVE_GIF 1' 2416 _def_gif='#define HAVE_GIF 1'
2419 _mkf_gif="yes" 2419 _mkf_gif="yes"
2420 _gif="yes (old version, some functions disabled)" 2420 _gif="yes (old version, some functions disabled)"
2421 _def_gif_4='#undef HAVE_GIF_4' 2421 _def_gif_4='#undef HAVE_GIF_4'
2422 2422
2423 cat > $TMPC << EOF 2423 cat > $TMPC << EOF
2424 #include <signal.h>
2424 #include <gif_lib.h> 2425 #include <gif_lib.h>
2426 void catch() { exit(1); }
2425 int main(void) { 2427 int main(void) {
2428 signal(SIGSEGV, catch); // catch segfault
2426 printf("EGifPutExtensionFirst is at address %p\n", EGifPutExtensionFirst); 2429 printf("EGifPutExtensionFirst is at address %p\n", EGifPutExtensionFirst);
2427 EGifSetGifVersion("89a"); // this will segfault a buggy gif lib. 2430 EGifSetGifVersion("89a"); // this will segfault a buggy gif lib.
2428 return 0; 2431 return 0;
2429 } 2432 }
2430 EOF 2433 EOF