[petsc-users] make file issues

Jed Brown jed at jedbrown.org
Wed Feb 22 21:27:32 CST 2017


Gideon Simpson <gideon.simpson at gmail.com> writes:

> I’ve been trying to use some code that was originally developed under petsc 3.6.x with my new 3.7.5 installation.  I’m having an issue in that the way the code is written, it’s spread across several .c files.  Here are the essential features of the makefile:
>
> all: myprog1
>
> OBJS = functions.o \
> 	utils.o
>
> include ${PETSC_DIR}/lib/petsc/conf/variables 
> include ${PETSC_DIR}/lib/petsc/conf/rules
>
> myprog1: prog1.o ${OBJS}

prog1.o or myprog1.o?

You may want to use $< or $^ to avoid duplication.

> 	${CLINKER} -o myprog1 myprog1.o ${OBJS} ${PETSC_LIB}
>
>
> make all  yields:
>
> make: *** No rule to make target `myprog1.o', needed by `myprog1'.  Stop
>
> -gideon
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 832 bytes
Desc: not available
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20170222/5188ac97/attachment-0001.pgp>


More information about the petsc-users mailing list