thimes has asked for the wisdom of the Perl Monks concerning the following question:

Installed Perlbrew on 2019 Macbook Pro (Intel core i9) 32GB RAM. MacOS Sonoma 14.4.1. Tested and works well. Tried to install Tk using cpanm Tk. Recieved ERRORS in build.log configure: error: installation or configuration problem: C compiler cannot create executables.

Writing MYMETA.yml and MYMETA.json Building jpeg/libjpeg.a checking for gcc... cc checking whether the C compiler (cc -fno-common -DPERL_DARWIN -mmacosx +-version-min=14.4 -DNO_POSIX_2008_LOCALE -fno-strict-aliasing -pipe - +fstack-protector-strong -I/usr/local/include -fno-common -DPERL_DAR +WIN -mmacosx-version-min=14.4 -DNO_POSIX_2008_LOCALE -fno-strict-alia +sing -pipe -fstack-protector-strong -I/usr/local/include -mmacosx-ve +rsion-min=14.4 -fstack-protector-strong -L/usr/local/lib) works... no configure: error: installation or configuration problem: C compiler ca +nnot create executables. ERROR from evaluation of /Users/terryhimes/.cpanm/work/1716015046.9428 +1/Tk-804.036/JPEG/Makefile.PL: ERROR from evaluation of /Users/terryh +imes/.cpanm/work/1716015046.94281/Tk-804.036/JPEG/jpeg/Makefile.PL: E +rror opening Makefile: No such file or directory at ./Makefile.PL lin +e 41. at ./Makefile.PL line 41. require ./Makefile.PL called at /Users/terryhimes/perl5/perlbrew/p +erls/perl-5.38.2/lib/5.38.2/ExtUtils/MakeMaker.pm line 258 ExtUtils::MakeMaker::eval_in_x(PACK021=HASH(0x7fe6d883bef0), "/Use +rs/terryhimes/.cpanm/work/1716015046.94281/Tk-804.036/JPE"...) called + at /Users/terryhimes/perl5/perlbrew/perls/perl-5.38.2/lib/5.38.2/Ext +Utils/MakeMaker.pm line 245 eval {...} called at /Users/terryhimes/perl5/perlbrew/perls/perl-5 +.38.2/lib/5.38.2/ExtUtils/MakeMaker.pm line 245 ExtUtils::MakeMaker::eval_in_subdirs(PACK021=HASH(0x7fe6d883bef0)) + called at /Users/terryhimes/perl5/perlbrew/perls/perl-5.38.2/lib/5.3 +8.2/ExtUtils/MakeMaker.pm line 823 ExtUtils::MakeMaker::new("MM", PACK021=HASH(0x7fe6d883bef0)) calle +d at /Users/terryhimes/perl5/perlbrew/perls/perl-5.38.2/lib/5.38.2/Ex +tUtils/MakeMaker.pm line 78 ExtUtils::MakeMaker::WriteMakefile("VERSION", 804.036, "XS_VERSION +", 804.036, "DEFINE", "", "INC", "-I.. -Ijpeg -I/usr/X11R6/include -I +/opt/X11/include/freetype2", ...)
I have installed Perlbrew on a new 2023 Macbook Pro, then Tk with no problems, works great. I followed the same instructions in both cases. Any ideas?

Replies are listed 'Best First'.
Re: cpanm Tk build errors
by cavac (Prior) on May 22, 2024 at 02:54 UTC

    C compiler cannot create executables

    Uhm, that's a new one i haven't seen before. I doubt that your compiler is borked (i doubt even Apple would be so bold as to break the compiler just to keep up their walled garden), but just to make sure, write a file "hello.c":

    #include <stdio.h> int main() { printf("Hello, World!\n"); return 0; }

    Then compile it with mininal arguments and execute it:

    $ cc -o hello hello.c $ ./hello Hello, World!

    If that works, you could try with the whole kaboodle of flags that the compile script thinks it should use:

    $ cc -fno-common -DPERL_DARWIN -mmacosx-version-min=14.4 -DNO_POSIX_20 +08_LOCALE -fno-strict-aliasing -pipe -fstack-protector-strong -I/usr/ +local/include -fno-common -DPERL_DARWIN -mmacosx-version-min=14.4 - +DNO_POSIX_2008_LOCALE -fno-strict-aliasing -pipe -fstack-protector-st +rong -I/usr/local/include -mmacosx-version-min=14.4 -fstack-protecto +r-strong -L/usr/local/lib -o hello hello.c $ ./hello

    Does this also work or do you get any errors?

    PerlMonks XP is useless? Not anymore: XPD - Do more with your PerlMonks XP
      All built with no errors. Executed perfectly.
Re: cpanm Tk build errors
by syphilis (Archbishop) on May 22, 2024 at 03:33 UTC
    I have installed Perlbrew on a new 2023 Macbook Pro, then Tk with no problems, works great. I followed the same instructions in both cases. Any ideas?

    I wonder:
    1) Is it the same version of Tk in both cases ?
    2) Did the build of Tk that worked also have have to build libjpeg ? ... or did it locate and use a suitable previously installed version of libjpeg ?
    3) Is it appropriate that all of those perl compiler flags be specified for the building of libjpeg ? As cavac has subtly hinted, maybe one or more of those flags has rendered "cc" unusable for that task.
    If those flags are actually specified in $Config{cc}, then I think that's wrong. What is the output of perl -V:cc ?

    But I don't think that I really have much in the way of ideas ;-)

    Cheers,
    Rob
      terryhimes@Users-MacBook-Pro perltk % perl -V:cc cc='cc'; Also compiled and ran hello.c and it worked perfectly. I will investigate your other suggestions comparing the successful build next.
Re: cpanm Tk build errors
by afoken (Chancellor) on May 22, 2024 at 12:59 UTC
    configure: error: installation or configuration problem: C compiler cannot create executables.

    The test compiles a hello-world-style program and tries to run it. If that fails, you get this error message. One reason is compiling for a different platform or set of libraries. That's a typical problem when cross-compiling. Another problems I can imagine is a filesystem mounted with the noexec option.

    Alexander

    --
    Today I will gladly share my knowledge and experience, for there are no sweeter words than "I told you so". ;-)
      I've built hello_world.c and ran it with no issues. Also, Removed Perl Downloaded latest version of Xcode v16 Beta Used Perlbrew to reinstall Perl perlbrew install perl-5.38.2 perlbrew switch perl-5.38.2 All installed and tested Ok. Tried installing Tk again. FAIL cpanm Tk Same errors. Grrrr.

        Try cpanm --look Tk . This will take you to the Tk build dir. If you are versed with autotools edit ./configure to find the position where it fails. It should be creating a C test program to compile and saving it to a tmp dir. And also there should be the compilation command line (which is also printed on the console). Halt it there and add lines to tell you where that test C program is AND what is the path of cc with which cc.

        Also run ./configure with explicitly specifying the fullpath to the compiler: ./confgure CC=/x/y/z/cc (or something like this)

        The possible reasons for the errors you get are: 1) test C program includes files which are not found, 2) the compiler executable is not what you think it is (note that it does not use the fullpath to the compiler), 3) compiler flags are wrong (note that you may already have ENV vars in your shell which specify CFLAGS, LDFLAGS, CC etc. 4) the compilation fails at the linking stage because LIBRARIES are not found or wrong ones are used. This is/was controlled with LD_LIBRARY_PATH and apple-specific DYLD_LIBRARY_PATH. Do you have those set in your ENV? Their use is frowned upon but sometimes is the last resort.

        Far fetched but: check what user the compilation is run under (whoami) and whether it has in its path the specific compiler and uses that compiler with no extra CFLAGS, library paths etc. from login settings e.g. in bashrc

Re: cpanm Tk build errors
by srini@pm (Initiate) on Feb 18, 2025 at 17:16 UTC
    For future visitors, who is facing this problem, this is a problem with new versions Mac OS where the CC compiler is defaulted to use C99 standard. Tk modules make files have test code that is not compatible with this standard. So, add following env variable to your bashrc or zshrc to solve this problem. There are other places where compiler flags can be passed.. google around for those.
    export CFLAGS="-ansi" export LDFLAGS="-ansi" export CPPFLAGS="-ansi"
Re: cpanm Tk build errors
by seawolf (Novice) on Aug 20, 2024 at 22:56 UTC

    Introduction

    Hi There,
    • I am experiencing what I think is a similar issue (see below); was this ever resolved?
    • I included the whole log file as maybe there is something of interest.
    • I have sent a private message to user thimes in parallel.

    Background Information

    • running on "macOS Sonoma 14.6.1 (23G93)"
    • following MacOS instructions on https://github.com/DistributedProofreaders/guiguts/blob/master/INSTALL.md
    • executing perl install_cpan_modules.pl

    Issue when running the following

    hughdagg@Hughs-iMac guiguts % pwd /Users/hughdagg/guiguts hughdagg@Hughs-iMac guiguts % perl install_cpan_modules.pl cpanm (App::cpanminus) version 1.7047 (/opt/homebrew/bin/cpanm) perl version 5.038002 (/opt/homebrew/Cellar/perl/5.38.2_1/bin/perl) %Config: archname=darwin-thread-multi-2level installsitelib=/opt/homebrew/Cellar/perl/5.38.2_1/lib/perl5/site_p +erl/5.38 installsitebin=/opt/homebrew/Cellar/perl/5.38.2_1/bin installman1dir=/opt/homebrew/Cellar/perl/5.38.2_1/share/man/man1 installman3dir=/opt/homebrew/Cellar/perl/5.38.2_1/share/man/man3 sitearchexp=/opt/homebrew/opt/perl/lib/perl5/site_perl/5.38/darwin +-thread-multi-2level sitelibexp=/opt/homebrew/opt/perl/lib/perl5/site_perl/5.38 archlibexp=/opt/homebrew/opt/perl/lib/perl5/5.38/darwin-thread-mul +ti-2level privlibexp=/opt/homebrew/opt/perl/lib/perl5/5.38 %ENV: PERL5LIB=/Users/hughdagg/perl5/lib/perl5 PERL_LOCAL_LIB_ROOT=/Users/hughdagg/perl5 PERL_MB_OPT=--install_base "/Users/hughdagg/perl5" PERL_MM_OPT=INSTALL_BASE=/Users/hughdagg/perl5 @INC: FatPacked::4983002120=HASH(0x129029408) /Users/hughdagg/perl5/lib/perl5/5.38.2/darwin-thread-multi-2level /Users/hughdagg/perl5/lib/perl5/5.38.2 /Users/hughdagg/perl5/lib/perl5/darwin-thread-multi-2level /Users/hughdagg/perl5/lib/perl5 /opt/homebrew/opt/perl/lib/perl5/site_perl/5.38/darwin-thread-mult +i-2level /opt/homebrew/opt/perl/lib/perl5/site_perl/5.38 /opt/homebrew/opt/perl/lib/perl5/5.38/darwin-thread-multi-2level /opt/homebrew/opt/perl/lib/perl5/5.38 /opt/homebrew/lib/perl5/site_perl/5.38/darwin-thread-multi-2level /opt/homebrew/lib/perl5/site_perl/5.38 File::HomeDir is up to date. (1.006) --> Working on Tk Fetching http://www.cpan.org/authors/id/S/SR/SREZIC/Tk-804.036.tar.gz +... OK Configuring Tk-804.036 ... N/A ! Configure failed for Tk-804.036. See /Users/hughdagg/.cpanm/work/172 +4193754.77888/build.log for details. Failed trying to install Tk hughdagg@Hughs-iMac guiguts % perl --version This is perl 5, version 38, subversion 2 (v5.38.2) built for darwin-th +read-multi-2level Copyright 1987-2023, Larry Wall Perl may be copied only under the terms of either the Artistic License + or the GNU General Public License, which may be found in the Perl 5 source ki +t. Complete documentation for Perl, including FAQ lists, should be found +on this system using "man perl" or "perldoc perl". If you have access to + the Internet, point your browser at https://www.perl.org/, the Perl Home P +age. hughdagg@Hughs-iMac guiguts %

    Log File

    hughdagg@Hughs-iMac guiguts % cat /Users/hughdagg/.cpanm/work/17241937 +54.77888/build.log cpanm (App::cpanminus) 1.7047 on perl 5.038002 built for darwin-thread +-multi-2level Work directory is /Users/hughdagg/.cpanm/work/1724193754.77888 You have make /usr/bin/make You have /usr/bin/curl You have /usr/bin/tar: bsdtar 3.5.3 - libarchive 3.5.3 zlib/1.2.12 lib +lzma/5.4.3 bz2lib/1.0.8 You have /usr/bin/unzip Searching Tk () on cpanmetadb ... --> Working on Tk Fetching http://www.cpan.org/authors/id/S/SR/SREZIC/Tk-804.036.tar.gz -> OK Unpacking Tk-804.036.tar.gz Entering Tk-804.036 Checking configure dependencies from META.json Checking if you have ExtUtils::MakeMaker 6.58 ... Yes (7.70) Configuring Tk-804.036 Running Makefile.PL PPM for perl5.038002 Test Compiling config/perlrx.c /opt/homebrew/Cellar/perl/5.38.2_1/bin/perl is installed in /opt/homeb +rew/opt/perl/lib/perl5/5.38/darwin-thread-multi-2level okay Test Compiling config/pmop.c Test Compiling config/pregcomp2.c Test Compiling config/regexp511.c Test Compiling config/signedchar.c Test Compile/Run config/unsigned.c Test Compiling config/Ksprintf.c Test Compiling config/svtrv.c Test Compiling config/copstashset.c Test Compiling config/tod.c Generic gettimeofday() Test Compile/Run config/xft.c Using -L/usr/X11R6/lib to find /usr/X11R6/lib/libX11.dylib Using -I/usr/X11R6/include to find /usr/X11R6/include/X11/Xlib.h Using -I/opt/X11/include/freetype2 to find /opt/X11/include/freetype2/ +freetype/freetype.h xlib='-L/usr/X11R6/lib' xinc='-I/usr/X11R6/include' Seem to have -lXft Writing Tk/Config.pm Writing pTk/tkConfig.h Checking if your kit is complete... Looks good Generating Dependencies for darwin, win_arch=x Test Compiling config/Hstrtoul.c Test Compiling config/Hstrdup.c Test Compiling config/Hstrcasecmp.c Extracting ClientWin.c Extracting default.h Extracting exWinHandle.c Extracting img.h Extracting imgBMP.c Extracting imgInit.c Extracting imgInt.h Extracting imgObj.c Extracting imgUtil.c Extracting imgWindow.c Extracting imgXBM.c Extracting imgXPM.c Extracting ks_names.h Extracting moredefs.h Extracting port.h Extracting stbDItem.c Extracting stbDiStyle.c Extracting tclAsync.c Extracting tclDecls.h Extracting tclEvent.c Extracting tclHash.c Extracting tclIntDecls.h Extracting tclIntPlatDecls.h Extracting tclMath.h Extracting tclNotify.c Extracting tclPlatDecls.h Extracting tclPreserve.c Extracting tclTimer.c Extracting tclUnixEvent.c Extracting tclUnixNotfy.c Extracting tclUnixTime.c Extracting tix.h Extracting tixBitmaps.h Extracting tixCompat.c Extracting tixDItem.c Extracting tixDef.h Extracting tixDiITxt.c Extracting tixDiImg.c Extracting tixDiStyle.c Extracting tixDiText.c Extracting tixDiWin.c Extracting tixError.c Extracting tixForm.c Extracting tixForm.h Extracting tixFormMisc.c Extracting tixGrData.c Extracting tixGrData.h Extracting tixGrFmt.c Extracting tixGrRC.c Extracting tixGrSel.c Extracting tixGrSort.c Extracting tixGrUtl.c Extracting tixGrid.c Extracting tixGrid.h Extracting tixHLCol.c Extracting tixHLHdr.c Extracting tixHLInd.c Extracting tixHList.c Extracting tixHList.h Extracting tixImgCmp.c Extracting tixImgXpm.c Extracting tixImgXpm.h Extracting tixInputO.c Extracting tixInt.h Extracting tixList.c Extracting tixMwm.c Extracting tixNBFrame.c Extracting tixPort.h Extracting tixScroll.c Extracting tixSmpLs.c Extracting tixTList.c Extracting tixTList.h Extracting tixUnixDraw.c Extracting tixUnixInt.h Extracting tixUnixPort.h Extracting tixUnixWm.c Extracting tixUnixXpm.c Extracting tixUtils.c Extracting tk.h Extracting tk3d.c Extracting tk3d.h Extracting tkAtom.c Extracting tkBind.c Extracting tkBitmap.c Extracting tkButton.c Extracting tkButton.h Extracting tkCanvArc.c Extracting tkCanvBmap.c Extracting tkCanvImg.c Extracting tkCanvLine.c Extracting tkCanvPoly.c Extracting tkCanvPs.c Extracting tkCanvText.c Extracting tkCanvUtil.c Extracting tkCanvWind.c Extracting tkCanvas.c Extracting tkCanvas.h Extracting tkClipboard.c Extracting tkCmds.c Extracting tkColor.c Extracting tkColor.h Extracting tkConfig.c Extracting tkCursor.c Extracting tkDecls.h Extracting tkEntry.c Extracting tkError.c Extracting tkEvent.c Extracting tkFileFilter.c Extracting tkFileFilter.h Extracting tkFocus.c Extracting tkFont.c Extracting tkFont.h Extracting tkFrame.c Extracting tkGC.c Extracting tkGeometry.c Extracting tkGet.c Extracting tkGrab.c Extracting tkGrid.c Extracting tkImage.c Extracting tkImgBmap.c Extracting tkImgGIF.c Extracting tkImgPPM.c Extracting tkImgPhoto.c Extracting tkImgUtil.c Extracting tkInitScript.h Extracting tkInt.h Extracting tkIntDecls.h Extracting tkIntPlatDecls.h Extracting tkIntXlibDecls.h Extracting tkListbox.c Extracting tkMacWinMenu.c Extracting tkMenu.c Extracting tkMenu.h Extracting tkMenuDraw.c Extracting tkMenubutton.c Extracting tkMenubutton.h Extracting tkMessage.c Extracting tkObj.c Extracting tkOldConfig.c Extracting tkOption.c Extracting tkPack.c Extracting tkPanedWindow.c Extracting tkPlace.c Extracting tkPlatDecls.h Extracting tkPointer.c Extracting tkPort.h Extracting tkRectOval.c Extracting tkScale.c Extracting tkScale.h Extracting tkScrollbar.c Extracting tkScrollbar.h Extracting tkSelect.c Extracting tkSelect.h Extracting tkSquare.c Extracting tkStubImg.c Extracting tkStyle.c Extracting tkText.c Extracting tkText.h Extracting tkTextBTree.c Extracting tkTextDisp.c Extracting tkTextImage.c Extracting tkTextIndex.c Extracting tkTextMark.c Extracting tkTextTag.c Extracting tkTextWind.c Extracting tkTrig.c Extracting tkUndo.c Extracting tkUndo.h Extracting tkUnix.c Extracting tkUnix3d.c Extracting tkUnixButton.c Extracting tkUnixColor.c Extracting tkUnixConfig.c Extracting tkUnixCursor.c Extracting tkUnixDefault.h Extracting tkUnixDialog.c Extracting tkUnixDraw.c Extracting tkUnixEmbed.c Extracting tkUnixEvent.c Extracting tkUnixFocus.c Extracting tkUnixFont.c Extracting tkUnixInit.c Extracting tkUnixInt.h Extracting tkUnixKey.c Extracting tkUnixMenu.c Extracting tkUnixMenubu.c Extracting tkUnixPort.h Extracting tkUnixScale.c Extracting tkUnixScrlbr.c Extracting tkUnixSelect.c Extracting tkUnixSend.c Extracting tkUnixWm.c Extracting tkUnixXId.c Extracting tkUnixXft.c Extracting tkUtil.c Extracting tkVisual.c Extracting tkWindow.c Extracting xbytes.h Finding dependencies for ClientWin.c Finding dependencies for Lang_f.c Finding dependencies for Xlib_f.c Finding dependencies for XrmOption.c Finding dependencies for imgBMP.c Finding dependencies for imgInit.c Finding dependencies for imgInt_f.c Finding dependencies for imgObj.c Finding dependencies for imgUtil.c Finding dependencies for imgWindow.c Finding dependencies for imgXBM.c Finding dependencies for imgXPM.c Finding dependencies for ptkCanvGrid.c Finding dependencies for ptkCanvGroup.c Finding dependencies for stbDItem.c Finding dependencies for stbDashCustom.c Finding dependencies for stbDiStyle.c Finding dependencies for strGlue.c Finding dependencies for strdup.c Finding dependencies for strtoul.c Finding dependencies for tclAsync.c Finding dependencies for tclDecls_f.c Finding dependencies for tclEvent.c Finding dependencies for tclHash.c Finding dependencies for tclNotify.c Finding dependencies for tclPreserve.c Finding dependencies for tclTimer.c Finding dependencies for tclUnixEvent.c Finding dependencies for tclUnixNotfy.c Finding dependencies for tclUnixTime.c Finding dependencies for tixCompat.c Finding dependencies for tixDItem.c Finding dependencies for tixDiITxt.c Finding dependencies for tixDiImg.c Finding dependencies for tixDiStyle.c Finding dependencies for tixDiText.c Finding dependencies for tixDiWin.c Finding dependencies for tixError.c Finding dependencies for tixForm.c Finding dependencies for tixFormMisc.c Finding dependencies for tixGrData.c Finding dependencies for tixGrFmt.c Finding dependencies for tixGrRC.c Finding dependencies for tixGrSel.c Finding dependencies for tixGrSort.c Finding dependencies for tixGrUtl.c Finding dependencies for tixGrid.c Finding dependencies for tixHLCol.c Finding dependencies for tixHLHdr.c Finding dependencies for tixHLInd.c Finding dependencies for tixHList.c Finding dependencies for tixImgCmp.c Finding dependencies for tixImgXpm.c Finding dependencies for tixImgXpm_f.c Finding dependencies for tixInputO.c Finding dependencies for tixInt_f.c Finding dependencies for tixList.c Finding dependencies for tixMwm.c Finding dependencies for tixNBFrame.c Finding dependencies for tixScroll.c Finding dependencies for tixSmpLs.c Finding dependencies for tixTList.c Finding dependencies for tixUnixDraw.c Finding dependencies for tixUnixWm.c Finding dependencies for tixUnixXpm.c Finding dependencies for tixUtils.c Finding dependencies for tixVars.c Finding dependencies for tix_f.c Finding dependencies for tk3d.c Finding dependencies for tkAtom.c Finding dependencies for tkBind.c Finding dependencies for tkBitmap.c Finding dependencies for tkButton.c Finding dependencies for tkCanvArc.c Finding dependencies for tkCanvBmap.c Finding dependencies for tkCanvImg.c Finding dependencies for tkCanvLine.c Finding dependencies for tkCanvPoly.c Finding dependencies for tkCanvPs.c Finding dependencies for tkCanvText.c Finding dependencies for tkCanvUtil.c Finding dependencies for tkCanvWind.c Finding dependencies for tkCanvas.c Finding dependencies for tkClipboard.c Finding dependencies for tkCmds.c Finding dependencies for tkColor.c Finding dependencies for tkConfig.c Finding dependencies for tkCursor.c Finding dependencies for tkDecls_f.c Finding dependencies for tkEntry.c Finding dependencies for tkError.c Finding dependencies for tkEvent.c Finding dependencies for tkEvent_f.c Finding dependencies for tkFileFilter.c Finding dependencies for tkFocus.c Finding dependencies for tkFont.c Finding dependencies for tkFrame.c Finding dependencies for tkGC.c Finding dependencies for tkGeometry.c Finding dependencies for tkGet.c Finding dependencies for tkGrab.c Finding dependencies for tkGrid.c Finding dependencies for tkImage.c Finding dependencies for tkImgBmap.c Finding dependencies for tkImgGIF.c Finding dependencies for tkImgPPM.c Finding dependencies for tkImgPhoto.c Finding dependencies for tkImgPhoto_f.c Finding dependencies for tkIntDecls_f.c Finding dependencies for tkIntPlatDecls_f.c Finding dependencies for tkIntXlibDecls_f.c Finding dependencies for tkInt_f.c Finding dependencies for tkListbox.c Finding dependencies for tkMenu.c Finding dependencies for tkMenuDraw.c Finding dependencies for tkMenubutton.c Finding dependencies for tkMessage.c Finding dependencies for tkObj.c Finding dependencies for tkOldConfig.c Finding dependencies for tkOption.c Finding dependencies for tkOption_f.c Finding dependencies for tkPack.c Finding dependencies for tkPanedWindow.c Finding dependencies for tkPlace.c Finding dependencies for tkPlatDecls_f.c Finding dependencies for tkPointer.c Finding dependencies for tkProperty.c Finding dependencies for tkRectOval.c Finding dependencies for tkScale.c Finding dependencies for tkScrollbar.c Finding dependencies for tkSelect.c Finding dependencies for tkSquare.c Finding dependencies for tkStubImg.c Finding dependencies for tkStyle.c Finding dependencies for tkText.c Finding dependencies for tkTextBTree.c Finding dependencies for tkTextDisp.c Finding dependencies for tkTextImage.c Finding dependencies for tkTextIndex.c Finding dependencies for tkTextMark.c Finding dependencies for tkTextTag.c Finding dependencies for tkTextWind.c Finding dependencies for tkTrig.c Finding dependencies for tkUndo.c Finding dependencies for tkUnix.c Finding dependencies for tkUnix3d.c Finding dependencies for tkUnixButton.c Finding dependencies for tkUnixColor.c Finding dependencies for tkUnixConfig.c Finding dependencies for tkUnixCursor.c Finding dependencies for tkUnixDialog.c Finding dependencies for tkUnixDraw.c Finding dependencies for tkUnixEmbed.c Finding dependencies for tkUnixEvent.c Finding dependencies for tkUnixFocus.c Finding dependencies for tkUnixFont.c Finding dependencies for tkUnixInit.c Finding dependencies for tkUnixKey.c Finding dependencies for tkUnixMenu.c Finding dependencies for tkUnixMenubu.c Finding dependencies for tkUnixScale.c Finding dependencies for tkUnixScrlbr.c Finding dependencies for tkUnixSelect.c Finding dependencies for tkUnixSend.c Finding dependencies for tkUnixWm.c Finding dependencies for tkUnixXId.c Finding dependencies for tkUnixXft.c Finding dependencies for tkUtil.c Finding dependencies for tkVisual.c Finding dependencies for tkWindow.c Finding dependencies for tk_f.c Writing MYMETA.yml and MYMETA.json Warning: LINKTYPE set to '', no longer necessary Writing MYMETA.yml and MYMETA.json Checking if your kit is complete... Looks good Writing MYMETA.yml and MYMETA.json Finding dependencies for X.xs Finding dependencies for Xlib.xs Finding dependencies for WinPhoto.xs Finding dependencies for Pixmap.xs Finding dependencies for TixGrid.xs Finding dependencies for Text.xs Finding dependencies for TList.xs Finding dependencies for Scrollbar.xs Writing MYMETA.yml and MYMETA.json Writing MYMETA.yml and MYMETA.json Writing MYMETA.yml and MYMETA.json Writing MYMETA.yml and MYMETA.json Writing MYMETA.yml and MYMETA.json Writing MYMETA.yml and MYMETA.json Writing MYMETA.yml and MYMETA.json Writing MYMETA.yml and MYMETA.json Writing MYMETA.yml and MYMETA.json Writing MYMETA.yml and MYMETA.json Finding dependencies for Scale.xs Writing MYMETA.yml and MYMETA.json 'pkg-config libpng' failed, continue with fallback values for cflags a +nd libs... 'pkg-config zlib' failed, continue with fallback values for cflags and + libs... Test Compile/Run config/has_png.c Building libpng.a checking for a BSD-compatible install... /usr/bin/install -c checking whether build environment is sane... yes checking for gawk... no checking for mawk... no checking for nawk... no checking for awk... awk checking whether make sets $(MAKE)... yes checking whether to enable maintainer-specific portions of Makefiles.. +. no checking for gcc... cc checking for C compiler default output file name... a.out checking whether the C compiler works... yes checking whether we are cross compiling... no checking for suffix of executables... checking for suffix of object files... o checking whether we are using the GNU C compiler... yes checking whether cc accepts -g... yes checking for cc option to accept ANSI C... none needed checking for style of include used by make... GNU checking dependency style of cc... gcc3 checking for a sed that does not truncate output... /usr/bin/sed checking build system type... arm-apple-darwin23.6.0 checking host system type... arm-apple-darwin23.6.0 checking for egrep... grep -E checking for ld used by cc... /Library/Developer/CommandLineTools/usr/ +bin/ld checking if the linker (/Library/Developer/CommandLineTools/usr/bin/ld +) is GNU ld... no checking how to run the C preprocessor... cc -E checking for sed... /usr/bin/sed checking for a BSD-compatible install... /usr/bin/install -c checking whether ln -s works... yes checking whether make sets $(MAKE)... (cached) yes checking for /Library/Developer/CommandLineTools/usr/bin/ld option to +reload object files... -r checking for BSD-compatible nm... /usr/bin/nm -B checking how to recognise dependent libraries... pass_all checking for ANSI C header files... no checking for sys/types.h... yes checking for sys/stat.h... yes checking for stdlib.h... yes checking for string.h... yes checking for memory.h... yes checking for strings.h... yes checking for inttypes.h... yes checking for stdint.h... yes checking for unistd.h... yes checking dlfcn.h usability... yes checking dlfcn.h presence... yes checking for dlfcn.h... yes checking for g++... g++ checking whether we are using the GNU C++ compiler... yes checking whether g++ accepts -g... yes checking dependency style of g++... gcc3 checking how to run the C++ preprocessor... g++ -E checking for g77... no checking for f77... no checking for xlf... no checking for frt... no checking for pgf77... no checking for fort77... no checking for fl32... no checking for af77... no checking for f90... no checking for xlf90... no checking for pgf90... no checking for epcf90... no checking for f95... no checking for fort... no checking for xlf95... no checking for ifc... no checking for efc... no checking for pgf95... no checking for lf95... no checking for gfortran... no checking whether we are using the GNU Fortran 77 compiler... no checking whether accepts -g... no checking the maximum length of command line arguments... 786432 checking command to parse /usr/bin/nm -B output from cc object... ok checking for objdir... .libs checking for ar... ar checking for ranlib... ranlib checking for strip... strip checking if cc supports -fno-rtti -fno-exceptions... yes checking for cc option to produce PIC... -fno-common checking if cc PIC flag -fno-common works... yes checking if cc static flag -static works... no checking if cc supports -c -o file.o... yes checking whether the cc linker (/Library/Developer/CommandLineTools/us +r/bin/ld) supports shared libraries... yes checking dynamic linker characteristics... darwin23.6.0 dyld checking how to hardcode library paths into programs... immediate checking whether stripping libraries is possible... yes checking if libtool supports shared libraries... yes checking whether to build shared libraries... yes checking whether to build static libraries... yes configure: creating libtool appending configuration tag "CXX" to libtool rm: conftest.dSYM: is a directory checking for ld used by g++... /Library/Developer/CommandLineTools/usr +/bin/ld checking if the linker (/Library/Developer/CommandLineTools/usr/bin/ld +) is GNU ld... no checking whether the g++ linker (/Library/Developer/CommandLineTools/u +sr/bin/ld) supports shared libraries... yes checking for g++ option to produce PIC... -fno-common checking if g++ PIC flag -fno-common works... rm: conftest.dSYM: is a +directory yes checking if g++ static flag -static works... rm: conftest.dSYM: is a d +irectory no checking if g++ supports -c -o file.o... rm: conftest.dSYM: is a direc +tory yes checking whether the g++ linker (/Library/Developer/CommandLineTools/u +sr/bin/ld) supports shared libraries... yes checking dynamic linker characteristics... darwin23.6.0 dyld checking how to hardcode library paths into programs... immediate appending configuration tag "F77" to libtool checking for ANSI C header files... (cached) no checking malloc.h usability... no checking malloc.h presence... no checking for malloc.h... no checking for stdlib.h... (cached) yes checking for string.h... (cached) yes checking for strings.h... (cached) yes checking for an ANSI C-conforming const... yes checking for size_t... yes checking whether struct tm is in sys/time.h or time.h... time.h checking for stdlib.h... (cached) yes checking for GNU libc compatible malloc... yes checking for working strtod... no checking for pow... yes checking for memset... yes checking for pow... (cached) yes checking for zlibVersion in -lz... yes checking if assembler code in pnggccrd.c can be compiled... yes checking if libraries can be versioned... no configure: WARNING: *** You have not enabled versioned symbols. configure: pkgconfig directory is ${libdir}/pkgconfig configure: creating ./config.status config.status: creating Makefile config.status: creating libpng.pc config.status: creating libpng-config config.status: creating config.h config.status: executing depfiles commands Building static library libz.a version 1.2.3 with cc. Checking for unistd.h... Yes. Checking whether to use vs[n]printf() or s[n]printf()... using vs[n]pr +intf() Checking for vsnprintf() in stdio.h... Yes. Checking for return value of vsnprintf()... Yes. Checking for errno.h... Yes. Checking for mmap support... Yes. Finding dependencies for PNG.xs Finding dependencies for imgPNG.c Finding dependencies for NBFrame.xs Finding dependencies for Mwm.xs Finding dependencies for Menubutton.xs Finding dependencies for Listbox.xs Test Compile/Run config/has_jpeg.c Writing MYMETA.yml and MYMETA.json Writing MYMETA.yml and MYMETA.json Writing MYMETA.yml and MYMETA.json Writing MYMETA.yml and MYMETA.json Writing MYMETA.yml and MYMETA.json Building jpeg/libjpeg.a checking for gcc... cc checking whether the C compiler (cc -fno-common -DPERL_DARWIN -mmacosx +-version-min=14.2 -DNO_POSIX_2008_LOCALE -fno-strict-aliasing -pipe - +fstack-protector-strong -fno-common -DPERL_DARWIN -mmacosx-version- +min=14.2 -DNO_POSIX_2008_LOCALE -fno-strict-aliasing -pipe -fstack-pr +otector-strong -mmacosx-version-min=14.2 -fstack-protector-strong) w +orks... no configure: error: installation or configuration problem: C compiler ca +nnot create executables. ERROR from evaluation of /Users/hughdagg/.cpanm/work/1724193754.77888/ +Tk-804.036/JPEG/Makefile.PL: ERROR from evaluation of /Users/hughdagg +/.cpanm/work/1724193754.77888/Tk-804.036/JPEG/jpeg/Makefile.PL: Error + opening Makefile: No such file or directory at ./Makefile.PL line 41 +. at ./Makefile.PL line 41. require ./Makefile.PL called at /opt/homebrew/opt/perl/lib/perl5/5 +.38/ExtUtils/MakeMaker.pm line 258 ExtUtils::MakeMaker::eval_in_x(PACK021=HASH(0x128c09818), "/Users/ +hughdagg/.cpanm/work/1724193754.77888/Tk-804.036/JPEG/"...) called at + /opt/homebrew/opt/perl/lib/perl5/5.38/ExtUtils/MakeMaker.pm line 245 eval {...} called at /opt/homebrew/opt/perl/lib/perl5/5.38/ExtUtil +s/MakeMaker.pm line 245 ExtUtils::MakeMaker::eval_in_subdirs(PACK021=HASH(0x128c09818)) ca +lled at /opt/homebrew/opt/perl/lib/perl5/5.38/ExtUtils/MakeMaker.pm l +ine 823 ExtUtils::MakeMaker::new("MM", PACK021=HASH(0x128c09818)) called a +t /opt/homebrew/opt/perl/lib/perl5/5.38/ExtUtils/MakeMaker.pm line 78 ExtUtils::MakeMaker::WriteMakefile("VERSION", 804.036, "XS_VERSION +", 804.036, "DEFINE", "", "INC", "-I.. -Ijpeg -I/usr/X11R6/include -I +/opt/X11/include/freetype2", ...) called at /Users/hughdagg/.cpanm/wo +rk/1724193754.77888/Tk-804.036/Tk/MMutil.pm line 588 Tk::MMutil::TkExtMakefile("MYEXTLIB", "jpeg/libjpeg.a", "INC", "-I +jpeg", "NAME", "Tk::JPEG", "EXE_FILES", ARRAY(0x128c26b40), ...) call +ed at ./Makefile.PL line 26 require ./Makefile.PL called at /opt/homebrew/opt/perl/lib/perl5/5 +.38/ExtUtils/MakeMaker.pm line 258 ExtUtils::MakeMaker::eval_in_x(PACK001=HASH(0x128833250), "/Users/ +hughdagg/.cpanm/work/1724193754.77888/Tk-804.036/JPEG") called at /op +t/homebrew/opt/perl/lib/perl5/5.38/ExtUtils/MakeMaker.pm line 245 eval {...} called at /opt/homebrew/opt/perl/lib/perl5/5.38/ExtUtil +s/MakeMaker.pm line 245 ExtUtils::MakeMaker::eval_in_subdirs(PACK001=HASH(0x128833250)) ca +lled at /opt/homebrew/opt/perl/lib/perl5/5.38/ExtUtils/MakeMaker.pm l +ine 823 ExtUtils::MakeMaker::new("MM", PACK001=HASH(0x128833250)) called a +t /opt/homebrew/opt/perl/lib/perl5/5.38/ExtUtils/MakeMaker.pm line 78 ExtUtils::MakeMaker::WriteMakefile("VERSION", 804.036, "XS_VERSION +", 804.036, "DEFINE", "", "INC", "-I/usr/X11R6/include -I/opt/X11/inc +lude/freetype2", ...) called at /Users/hughdagg/.cpanm/work/172419375 +4.77888/Tk-804.036/Tk/MMutil.pm line 588 Tk::MMutil::TkExtMakefile("VERSION", 804.036, "EXE_FILES", ARRAY(0 +x13960afa0), "NAME", "Tk", "DIR", ARRAY(0x1388297e0), ...) called at +Makefile.PL line 80 at /opt/homebrew/opt/perl/lib/perl5/5.38/ExtUtils/MakeMaker.pm line 2 +66. ExtUtils::MakeMaker::eval_in_x(PACK021=HASH(0x128c09818), "/Users/ +hughdagg/.cpanm/work/1724193754.77888/Tk-804.036/JPEG/"...) called at + /opt/homebrew/opt/perl/lib/perl5/5.38/ExtUtils/MakeMaker.pm line 245 eval {...} called at /opt/homebrew/opt/perl/lib/perl5/5.38/ExtUtil +s/MakeMaker.pm line 245 ExtUtils::MakeMaker::eval_in_subdirs(PACK021=HASH(0x128c09818)) ca +lled at /opt/homebrew/opt/perl/lib/perl5/5.38/ExtUtils/MakeMaker.pm l +ine 823 ExtUtils::MakeMaker::new("MM", PACK021=HASH(0x128c09818)) called a +t /opt/homebrew/opt/perl/lib/perl5/5.38/ExtUtils/MakeMaker.pm line 78 ExtUtils::MakeMaker::WriteMakefile("VERSION", 804.036, "XS_VERSION +", 804.036, "DEFINE", "", "INC", "-I.. -Ijpeg -I/usr/X11R6/include -I +/opt/X11/include/freetype2", ...) called at /Users/hughdagg/.cpanm/wo +rk/1724193754.77888/Tk-804.036/Tk/MMutil.pm line 588 Tk::MMutil::TkExtMakefile("MYEXTLIB", "jpeg/libjpeg.a", "INC", "-I +jpeg", "NAME", "Tk::JPEG", "EXE_FILES", ARRAY(0x128c26b40), ...) call +ed at ./Makefile.PL line 26 require ./Makefile.PL called at /opt/homebrew/opt/perl/lib/perl5/5 +.38/ExtUtils/MakeMaker.pm line 258 ExtUtils::MakeMaker::eval_in_x(PACK001=HASH(0x128833250), "/Users/ +hughdagg/.cpanm/work/1724193754.77888/Tk-804.036/JPEG") called at /op +t/homebrew/opt/perl/lib/perl5/5.38/ExtUtils/MakeMaker.pm line 245 eval {...} called at /opt/homebrew/opt/perl/lib/perl5/5.38/ExtUtil +s/MakeMaker.pm line 245 ExtUtils::MakeMaker::eval_in_subdirs(PACK001=HASH(0x128833250)) ca +lled at /opt/homebrew/opt/perl/lib/perl5/5.38/ExtUtils/MakeMaker.pm l +ine 823 ExtUtils::MakeMaker::new("MM", PACK001=HASH(0x128833250)) called a +t /opt/homebrew/opt/perl/lib/perl5/5.38/ExtUtils/MakeMaker.pm line 78 ExtUtils::MakeMaker::WriteMakefile("VERSION", 804.036, "XS_VERSION +", 804.036, "DEFINE", "", "INC", "-I/usr/X11R6/include -I/opt/X11/inc +lude/freetype2", ...) called at /Users/hughdagg/.cpanm/work/172419375 +4.77888/Tk-804.036/Tk/MMutil.pm line 588 Tk::MMutil::TkExtMakefile("VERSION", 804.036, "EXE_FILES", ARRAY(0 +x13960afa0), "NAME", "Tk", "DIR", ARRAY(0x1388297e0), ...) called at +Makefile.PL line 80 at /opt/homebrew/opt/perl/lib/perl5/5.38/ExtUtils/MakeMaker.pm line 2 +49. ExtUtils::MakeMaker::eval_in_subdirs(PACK021=HASH(0x128c09818)) ca +lled at /opt/homebrew/opt/perl/lib/perl5/5.38/ExtUtils/MakeMaker.pm l +ine 823 ExtUtils::MakeMaker::new("MM", PACK021=HASH(0x128c09818)) called a +t /opt/homebrew/opt/perl/lib/perl5/5.38/ExtUtils/MakeMaker.pm line 78 ExtUtils::MakeMaker::WriteMakefile("VERSION", 804.036, "XS_VERSION +", 804.036, "DEFINE", "", "INC", "-I.. -Ijpeg -I/usr/X11R6/include -I +/opt/X11/include/freetype2", ...) called at /Users/hughdagg/.cpanm/wo +rk/1724193754.77888/Tk-804.036/Tk/MMutil.pm line 588 Tk::MMutil::TkExtMakefile("MYEXTLIB", "jpeg/libjpeg.a", "INC", "-I +jpeg", "NAME", "Tk::JPEG", "EXE_FILES", ARRAY(0x128c26b40), ...) call +ed at ./Makefile.PL line 26 require ./Makefile.PL called at /opt/homebrew/opt/perl/lib/perl5/5 +.38/ExtUtils/MakeMaker.pm line 258 ExtUtils::MakeMaker::eval_in_x(PACK001=HASH(0x128833250), "/Users/ +hughdagg/.cpanm/work/1724193754.77888/Tk-804.036/JPEG") called at /op +t/homebrew/opt/perl/lib/perl5/5.38/ExtUtils/MakeMaker.pm line 245 eval {...} called at /opt/homebrew/opt/perl/lib/perl5/5.38/ExtUtil +s/MakeMaker.pm line 245 ExtUtils::MakeMaker::eval_in_subdirs(PACK001=HASH(0x128833250)) ca +lled at /opt/homebrew/opt/perl/lib/perl5/5.38/ExtUtils/MakeMaker.pm l +ine 823 ExtUtils::MakeMaker::new("MM", PACK001=HASH(0x128833250)) called a +t /opt/homebrew/opt/perl/lib/perl5/5.38/ExtUtils/MakeMaker.pm line 78 ExtUtils::MakeMaker::WriteMakefile("VERSION", 804.036, "XS_VERSION +", 804.036, "DEFINE", "", "INC", "-I/usr/X11R6/include -I/opt/X11/inc +lude/freetype2", ...) called at /Users/hughdagg/.cpanm/work/172419375 +4.77888/Tk-804.036/Tk/MMutil.pm line 588 Tk::MMutil::TkExtMakefile("VERSION", 804.036, "EXE_FILES", ARRAY(0 +x13960afa0), "NAME", "Tk", "DIR", ARRAY(0x1388297e0), ...) called at +Makefile.PL line 80 at /opt/homebrew/opt/perl/lib/perl5/5.38/ExtUtils/MakeMaker.pm line 2 +66. ExtUtils::MakeMaker::eval_in_x(PACK001=HASH(0x128833250), "/Users/ +hughdagg/.cpanm/work/1724193754.77888/Tk-804.036/JPEG") called at /op +t/homebrew/opt/perl/lib/perl5/5.38/ExtUtils/MakeMaker.pm line 245 eval {...} called at /opt/homebrew/opt/perl/lib/perl5/5.38/ExtUtil +s/MakeMaker.pm line 245 ExtUtils::MakeMaker::eval_in_subdirs(PACK001=HASH(0x128833250)) ca +lled at /opt/homebrew/opt/perl/lib/perl5/5.38/ExtUtils/MakeMaker.pm l +ine 823 ExtUtils::MakeMaker::new("MM", PACK001=HASH(0x128833250)) called a +t /opt/homebrew/opt/perl/lib/perl5/5.38/ExtUtils/MakeMaker.pm line 78 ExtUtils::MakeMaker::WriteMakefile("VERSION", 804.036, "XS_VERSION +", 804.036, "DEFINE", "", "INC", "-I/usr/X11R6/include -I/opt/X11/inc +lude/freetype2", ...) called at /Users/hughdagg/.cpanm/work/172419375 +4.77888/Tk-804.036/Tk/MMutil.pm line 588 Tk::MMutil::TkExtMakefile("VERSION", 804.036, "EXE_FILES", ARRAY(0 +x13960afa0), "NAME", "Tk", "DIR", ARRAY(0x1388297e0), ...) called at +Makefile.PL line 80 at /opt/homebrew/opt/perl/lib/perl5/5.38/ExtUtils/MakeMaker.pm line 2 +49. ExtUtils::MakeMaker::eval_in_subdirs(PACK001=HASH(0x128833250)) ca +lled at /opt/homebrew/opt/perl/lib/perl5/5.38/ExtUtils/MakeMaker.pm l +ine 823 ExtUtils::MakeMaker::new("MM", PACK001=HASH(0x128833250)) called a +t /opt/homebrew/opt/perl/lib/perl5/5.38/ExtUtils/MakeMaker.pm line 78 ExtUtils::MakeMaker::WriteMakefile("VERSION", 804.036, "XS_VERSION +", 804.036, "DEFINE", "", "INC", "-I/usr/X11R6/include -I/opt/X11/inc +lude/freetype2", ...) called at /Users/hughdagg/.cpanm/work/172419375 +4.77888/Tk-804.036/Tk/MMutil.pm line 588 Tk::MMutil::TkExtMakefile("VERSION", 804.036, "EXE_FILES", ARRAY(0 +x13960afa0), "NAME", "Tk", "DIR", ARRAY(0x1388297e0), ...) called at +Makefile.PL line 80 -> N/A -> FAIL Configure failed for Tk-804.036. See /Users/hughdagg/.cpanm/wo +rk/1724193754.77888/build.log for details. hughdagg@Hughs-iMac guiguts %
    Thanks on advance for any assitance!, Hugh :)

      Contents of config.log

      Here is the config.log file from the above issue:

      hughdagg@Hughs-iMac guiguts % cat /Users/hughdagg/.cpanm/work/17246004 +27.93037/Tk-804.036/JPEG/jpeg/./config.log This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. configure:538: checking for gcc configure:615: checking whether the C compiler (cc -fno-common -DPERL_ +DARWIN -mmacosx-version-min=14.2 -DNO_POSIX_2008_LOCALE -fno-strict-a +liasing -pipe -fstack-protector-strong -fno-common -DPERL_DARWIN -m +macosx-version-min=14.2 -DNO_POSIX_2008_LOCALE -fno-strict-aliasing - +pipe -fstack-protector-strong -mmacosx-version-min=14.2 -fstack-prot +ector-strong) works configure:629: cc -o conftest -fno-common -DPERL_DARWIN -mmacosx-versi +on-min=14.2 -DNO_POSIX_2008_LOCALE -fno-strict-aliasing -pipe -fstack +-protector-strong -fno-common -DPERL_DARWIN -mmacosx-version-min=1 +4.2 -DNO_POSIX_2008_LOCALE -fno-strict-aliasing -pipe -fstack-protect +or-strong -mmacosx-version-min=14.2 -fstack-protector-strong conftes +t.c 1>&5 configure:626:1: error: type specifier missing, defaults to 'int'; ISO + C99 and later do not support implicit int [-Wimplicit-int] main(){return(0);} ^ int 1 error generated. configure: failed program was: #line 625 "configure" #include "confdefs.h" main(){return(0);} hughdagg@Hughs-iMac guiguts %

      Thanks for any help in advance, Hugh :)

        Background

        So I did a little more digging and think the issue revolves around the fact that Clang version 15 and 16 come with new warnings;
        for more information see https://www.redhat.com/en/blog/new-warnings-and-errors-clang-16. In particular error "ISO C99 and later do not support implicit int -Wimplicit-int"

        Question

        Is there any way to pass CFLAGS into the "perl install_cpan_modules.pl"?

        Current Directory

        hughdagg@Hughs-iMac jpeg % pwd /Users/hughdagg/.cpanm/work/1724625386.12184/Tk-804.036/JPEG/jpeg

        Run Default Configure

        hughdagg@Hughs-iMac jpeg % ./configure checking for gcc... gcc checking whether the C compiler (gcc ) works... no configure: error: installation or configuration problem: C compiler ca +nnot create executables.

        Log File

        hughdagg@Hughs-iMac jpeg % cat config.log This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. configure:538: checking for gcc configure:615: checking whether the C compiler (gcc ) works configure:629: gcc -o conftest conftest.c 1>&5 configure:626:1: error: type specifier missing, defaults to 'int'; ISO + C99 and later do not support implicit int [-Wimplicit-int] main(){return(0);} ^ int 1 error generated. configure: failed program was: #line 625 "configure" #include "confdefs.h" main(){return(0);}

        Run Configure with c89 standard

        hughdagg@Hughs-iMac jpeg % ./configure "CFLAGS=-std=c89" checking for gcc... gcc checking whether the C compiler (gcc -std=c89 ) works... yes checking whether the C compiler (gcc -std=c89 ) is a cross-compiler... + no checking whether we are using GNU C... yes checking how to run the C preprocessor... gcc -E checking for function prototypes... yes checking for stddef.h... yes checking for stdlib.h... yes checking for string.h... yes checking for size_t... yes checking for type unsigned char... yes checking for type unsigned short... yes checking for type void... yes checking for working const... yes checking for inline... __inline__ checking for broken incomplete types... ok checking for short external names... ok checking to see if char is signed... yes checking to see if right shift is signed... yes checking to see if fopen accepts b spec... no checking for a BSD compatible install... /usr/bin/install -c checking for ranlib... ranlib checking libjpeg version number... 62 creating ./config.status creating Makefile creating jconfig.h jconfig.h is unchanged hughdagg@Hughs-iMac jpeg %

        Log File

        There are issues but the compiler flags turn them into warnings

        hughdagg@Hughs-iMac jpeg % cat config.log This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. configure:538: checking for gcc configure:615: checking whether the C compiler (gcc -std=c89 ) works configure:629: gcc -o conftest -std=c89 conftest.c 1>&5 configure:649: checking whether the C compiler (gcc -std=c89 ) is a cr +oss-compiler configure:654: checking whether we are using GNU C configure:663: gcc -E conftest.c configure:681: checking how to run the C preprocessor configure:702: gcc -E conftest.c >/dev/null 2>conftest.out configure:742: checking for function prototypes configure:765: gcc -c -std=c89 conftest.c 1>&5 configure:792: checking for stddef.h configure:802: gcc -E conftest.c >/dev/null 2>conftest.out configure:828: checking for stdlib.h configure:838: gcc -E conftest.c >/dev/null 2>conftest.out configure:864: checking for string.h configure:874: gcc -E conftest.c >/dev/null 2>conftest.out configure:900: checking for size_t configure:923: gcc -c -std=c89 conftest.c 1>&5 configure:994: checking for type unsigned char configure:1003: gcc -c -std=c89 conftest.c 1>&5 configure:1018: checking for type unsigned short configure:1027: gcc -c -std=c89 conftest.c 1>&5 configure:1042: checking for type void configure:1072: gcc -c -std=c89 conftest.c 1>&5 configure:1088: checking for working const configure:1142: gcc -c -std=c89 conftest.c 1>&5 configure:1163: checking for inline configure:1174: gcc -c -std=c89 conftest.c 1>&5 configure:1224: checking for broken incomplete types configure:1233: gcc -c -std=c89 conftest.c 1>&5 configure:1248: checking for short external names configure:1260: gcc -o conftest -std=c89 conftest.c 1>&5 configure:1275: checking to see if char is signed configure:1306: gcc -o conftest -std=c89 conftest.c 1>&5 configure:1295:5: error: implicitly declaring library function 'printf +' with type 'int (const char *, ...)' [-Werror,-Wimplicit-function-de +claration] printf("Hmm, it seems 'char' is not eight bits wide on your machin +e.\n"); ^ configure:1295:5: note: include the header <stdio.h> or explicitly pro +vide a declaration for 'printf' configure:1302:3: error: implicitly declaring library function 'exit' +with type 'void (int) __attribute__((noreturn))' [-Werror,-Wimplicit- +function-declaration] exit(is_char_signed((int) signed_char_check)); ^ configure:1302:3: note: include the header <stdlib.h> or explicitly pr +ovide a declaration for 'exit' 2 errors generated. configure: failed program was: #line 1282 "configure" #include "confdefs.h" #ifdef HAVE_PROTOTYPES int is_char_signed (int arg) #else int is_char_signed (arg) int arg; #endif { if (arg == 189) { /* expected result for unsigned char */ return 0; /* type char is unsigned */ } else if (arg != -67) { /* expected result for signed char */ printf("Hmm, it seems 'char' is not eight bits wide on your machin +e.\n"); printf("I fear the JPEG software will not work at all.\n\n"); } return 1; /* assume char is signed otherwise */ } char signed_char_check = (char) (-67); main() { exit(is_char_signed((int) signed_char_check)); } configure:1323: checking to see if right shift is signed configure:1358: gcc -o conftest -std=c89 conftest.c 1>&5 configure:1349:3: error: implicitly declaring library function 'printf +' with type 'int (const char *, ...)' [-Werror,-Wimplicit-function-de +claration] printf("Right shift isn't acting as I expect it to.\n"); ^ configure:1349:3: note: include the header <stdio.h> or explicitly pro +vide a declaration for 'printf' configure:1345:16: warning: shifting a negative signed value is undefi +ned [-Wshift-negative-value] res |= (~0L) << (32-4); ~~~~~ ^ configure:1354:3: error: implicitly declaring library function 'exit' +with type 'void (int) __attribute__((noreturn))' [-Werror,-Wimplicit- +function-declaration] exit(is_shifting_signed(-0x7F7E80B1L)); ^ configure:1354:3: note: include the header <stdlib.h> or explicitly pr +ovide a declaration for 'exit' 1 warning and 2 errors generated. configure: failed program was: #line 1328 "configure" #include "confdefs.h" #ifdef HAVE_PROTOTYPES int is_shifting_signed (long arg) #else int is_shifting_signed (arg) long arg; #endif /* See whether right-shift on a long is signed or not. */ { long res = arg >> 4; if (res == -0x7F7E80CL) { /* expected result for signed shift */ return 1; /* right shift is signed */ } /* see if unsigned-shift hack will fix it. */ /* we can't just test exact value since it depends on width of long. +.. */ res |= (~0L) << (32-4); if (res == -0x7F7E80CL) { /* expected result now? */ return 0; /* right shift is unsigned */ } printf("Right shift isn't acting as I expect it to.\n"); printf("I fear the JPEG software will not work at all.\n\n"); return 0; /* try it with unsigned anyway */ } main() { exit(is_shifting_signed(-0x7F7E80B1L)); } configure:1375: checking to see if fopen accepts b spec configure:1390: gcc -o conftest -std=c89 conftest.c 1>&5 configure:1385:5: error: implicitly declaring library function 'exit' +with type 'void (int) __attribute__((noreturn))' [-Werror,-Wimplicit- +function-declaration] exit(0); ^ configure:1385:5: note: include the header <stdlib.h> or explicitly pr +ovide a declaration for 'exit' 1 error generated. configure: failed program was: #line 1380 "configure" #include "confdefs.h" #include <stdio.h> main() { if (fopen("conftestdata", "wb") != NULL) exit(0); exit(1); } configure:1436: checking for a BSD compatible install configure:1488: checking for ranlib configure:1650: checking libjpeg version number hughdagg@Hughs-iMac jpeg %