Menu

#262 Make error with CPU type

open
nobody
None
5
2020-12-09
2020-12-07
No

I am trying to install gnuplot-5.2.8 on a 2019 MacBook Pro running Mac OS 14.0.1 (Big Sur). The configure script ran without problem. However, when I tried to run make, I recieved the following messages:

make all-recursive
make: make: Bad CPU type in executable
make: *** [all] Error 1

What can I do?

Discussion

  • Ethan Merritt

    Ethan Merritt - 2020-12-07

    I am not a Mac user so I can only pass on suggestions seen elsewhere. I gather that the "Bad CPU type" usually means that you have some 32-bit executable on the machine left over from an earlier version of Mac OS. Somewhere around version 11 they stopped supporting use of 32-bit executables on a 64-bit machine, so previously working programs stopped working. I can't tell from your error message which program it is that's being complained about - "make" itself? something called by make? maybe a command-line utility like "sed"?

    It is possible that this error is triggered only at the top level of the make-recursive operation. If so you might be able to side-step it by doing
    ~~~
    cd src
    make
    ~~~

    You can probably find more knowledgeable respondents if you ask this question on a Mac forum and provide more information about your build environment - HomeBrew? MacPorts? Fink?

     
  • Hans-Bernhard Broeker

    That message seems to indicate that "make" itself is being complained about. To get more insight, it may help to run make with some of its built-in debug output enabled:

    make --trace  # report all commands and the reasons they're invoked
    make --debug  # report a good deal more
    make -d # report positively everything it can think of
    
     
  • Charles Benton Thorington

    When I ran "make --trace", make reported

    This program built for i386-apple-darwin11.3.0

    The CPU chip in my 2019 MacBook Pro ia an Intel Core i9

    When I ran "make --debug", I received the following messages.

    This program built for i386-apple-darwin11.3.0
    Reading makefiles...
    Updating goal targets....
    File all' does not exist. Must remake targetall'.
    make all-recursive
    make: make: Bad CPU type in executable
    make: *** [all] Error 1

    It would appear the gnuplot software I download was for older Macs. How can I get a download for the correct CPU?

     
    • Hans-Bernhard Broeker

      The "gnuplot software" you downloaded is a source tarball. As such it is not for any particular type of CPU. You're not even running any part of the software contained in that download at this point. You're running your installed binary of "make", and that's trying to run itself, or possibly other parts of the usual Unix toolchain, recursively.

      That "make" binary is well out of date, though. For context: darwin 11.3 would correspond to MacOS "Lion" from early 2012. "Big Sur" follows "Catalina," which ended support for 32-bit binaries.

      In other words, it's your compile environment that's too old, not the gnuplot source.

       

Log in to post a comment.