On Wed, 17 Jun 2015, Manish Kumar K wrote:

> Dear PETSc Team,
> 
> 
> 
>          I am trying to build couple  .c files
> 
> eg : solidification.c , solidification_solver.c , solidification_find_ijk.c 
> and so on with one header global_header.c

Normal notation for a header file is to use a '.h' notation - i.e 
global_header.h

> 
>  using makefile in Cygwin,
> 
> For that I'm invoking following command
> 
> 
> 
> make PETSC_DIR=/cygdrive/c/Scratch/petsc PETSC_ARCH=arch-mswin-c-opt cdat
> 
> 
> 
> and I have placed my c files in petsc location " 
> =/cygdrive/c/Scratch/petsc/arch-mswin-c-opt/cdat"
> 
You can have your applications files in any location [don't need to add them to 
PETSc source or install dir]

> 
> 
> I get following error
> 
> $ make PETSC_DIR=/cygdrive/c/Scratch/petsc PETSC_ARCH=arch-mswin-c-opt cdat
> 
> make: *** No rule to make target 'cdat'.  Stop.
> 
Are you sure you have the makefile in the same location as the sources?

>>>>>
include C:/Scratch/petsc/conf/variables
include C:/Scratch/petsc/conf/rules
<<<<<<<
This is not really cygwin make format.

Also you appear to link with 
/cygdrive/c/Scratch/petsc/arch-mswin-c-opt/lib/SDPFlex.lib
You would have to rebuild this with cygwin gcc/g++/gfortran compilers - for 
this to work.

If you are able to do that - the attached modified makefile is likely to work..

Satish
> 
> 
> I want and .exe file to be generated for this project of mine  eg : 
> example.exe as my end result.
> 
> I have attached makefile with this mail ,kindly help on this would be 
> appreciated.
> 
> 
> 
> Please help me in this .
> 
> 
> 
> Regards
> 
> Manish K
> 
> [https://relayq.larsentoubro.com/DigitalSignature2015.jpg]
> 
> L&T Technology Services Ltd
> 
> www.LntTechservices.com<http://www.lnttechservices.com/>
> 
> This Email may contain confidential or privileged information for the 
> intended recipient (s). If you are not the intended recipient, please do not 
> use or disseminate the information, notify the sender and delete it from your 
> system.
> 
PETSC_DIR=/cygdrive/c/Scratch/petsc
PETSC_ARCH=arch-mswin-c-opt

SPDFLEX_LIB = -lSDPFlex

CFLAGS           =
FFLAGS           =
CPPFLAGS         =
FPPFLAGS         =
EXAMPLESC        = solidification_read_mesh_CaPS.c \
                                solidification_read_mat_property.c \
                                solidification_find_ijk.c \
                                solidification_find_node_number.c \
                                solidification_solver_tmatrixb.c \
                                solidification_solver_tgradient.c \
                                solidification_solver.c \
                                solidification_print_results_first.c \
                                solidification.c \
                                solidification_find_hotspot.c \
                                solidification_read_input_data.c \
                                solidification_solver_calc_property.c \
                                solidification_solver_calc_htc.c \
                                solidification_read_htc_data.c \
                                solidification_vdg.c

CLEANFILES       = cdat

include ${PETSC_DIR}/conf/variables
include ${PETSC_DIR}/conf/rules

cdat: chkopts ${OBJSC}
        -${CLINKER} -o cdat-petsc-lic ${OBJSC} ${PETSC_LIB} ${SPDFLEX_LIB}
        ${RM} ${OBJSC}

Reply via email to