[cs631apue] Problems with makefile

Jan Schaumann jschauma at stevens.edu
Sat Oct 13 13:40:11 EDT 2018


Marlon Seaton <mseaton at stevens.edu> wrote:
 
> Not sure what is going on with my makefile on BSD. Works 100% on the
> command line in ubuntu. Here's my makefile contents:

NetBSD's make does not support pattern rules as supported by GNU make.

Use a regular suffix rule instead.  In fact, you don't even need to
specify a suffix rule, since make(1) has a built-in suffix rule to
compile a .c file into a .o file; see e.g.,
https://stevens.netmeister.org/631/make-examples/Makefile.4

Please also use the '-Wextra' flag in addition to the other compiler
flags you have.

-Jan


More information about the cs631apue mailing list