CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > ANSYS > FLUENT > Fluent UDF and Scheme Programming

UDF link fortran source

Register Blogs Members List Search Today's Posts Mark Forums Read

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   February 7, 2013, 04:44
Default UDF link fortran source
  #1
Senior Member
 
christine
Join Date: Jul 2009
Location: europe
Posts: 125
Rep Power: 16
yorelchr is on a distinguished road
Hi everyone,

Do anyone know how to compile a UDF calling a fortran source? I have tried to follow the User guide for UDF but I think my problem is coming from the duo "Microsoft Visual Studio 10.0" and "Compaq Visual Fortran6". There must be some kind of problem between the libraries. I've tried to look for a solution on the net, but it's very confusing to me, explanations are for "specialists" and I'm not..
I have the following error message when launching nmake in the MVS10.0 command terminal :
Quote:
Microsoft (R) Program Maintenance Utility Version 10.00.30319.01
Copyright (C) Microsoft Corporation. All rights reserved.

# Generating ud_io1.h
resolve.exe -udf ..\..\src\rate_driver.c -head_file ud_io1.h
cl /c /Za /DUDF_EXPORTING /DUDF_NT -I. -I"c:\programmi\ansys inc\v130\f
luent"\fluent13.0.0\ntx86\2ddp -I"c:\programmi\ansys inc\v130\fluent"\fluent13.
0.0\src -I"c:\programmi\ansys inc\v130\fluent"\fluent13.0.0\cortex\src -I"c:\p
rogrammi\ansys inc\v130\fluent"\fluent13.0.0\client\src -I"c:\programmi\ansys i
nc\v130\fluent"\fluent13.0.0\tgrid\src -I"c:\programmi\ansys inc\v130\fluent"\f
luent13.0.0\multiport\src ..\..\src\rate_driver.c
Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 16.00.30319.01 for 80x86
Copyright (C) Microsoft Corporation. All rights reserved.

rate_driver.c
# Generating udf_names.c because of makefile rate_driver.obj
cl /c /Za /DUDF_EXPORTING /DUDF_NT -I. -I"c:\programmi\ansys inc\v130\f
luent"\fluent13.0.0\ntx86\2ddp -I"c:\programmi\ansys inc\v130\fluent"\fluent13.
0.0\src -I"c:\programmi\ansys inc\v130\fluent"\fluent13.0.0\cortex\src -I"c:\p
rogrammi\ansys inc\v130\fluent"\fluent13.0.0\client\src -I"c:\programmi\ansys i
nc\v130\fluent"\fluent13.0.0\tgrid\src -I"c:\programmi\ansys inc\v130\fluent"\f
luent13.0.0\multiport\src udf_names.c
Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 16.00.30319.01 for 80x86
Copyright (C) Microsoft Corporation. All rights reserved.

udf_names.c
# Linking libudf.dll because of makefile user_nt.udf udf_names.obj rate_driver.o
bj
link /Libpath:"c:\programmi\ansys inc\v130\fluent"\fluent13.0.0\ntx86\2
ddp /dll /out:libudf.dll udf_names.obj rate_driver.obj arm9.obj fl1300s.lib
Microsoft (R) Incremental Linker Version 10.00.30319.01
Copyright (C) Microsoft Corporation. All rights reserved.

libc.lib(dllcrt0.obj) : error LNK2005: __CRT_INIT@12 already defined in LIBCMT.l
ib(dllcrt0.obj)
libc.lib(dllcrt0.obj) : error LNK2005: __DllMainCRTStartup@12 already defined in
LIBCMT.lib(dllcrt0.obj)
libc.lib(dllcrt0.obj) : error LNK2005: __amsg_exit already defined in LIBCMT.lib
(crt0dat.obj)
libc.lib(dllcrt0.obj) : error LNK2005: ___app_type already defined in LIBCMT.lib
(dllcrt0.obj)
libc.lib(dllcrt0.obj) : error LNK2005: ___error_mode already defined in LIBCMT.l
ib(dllcrt0.obj)
libc.lib(dllcrt0.obj) : error LNK2005: __wenvptr already defined in LIBCMT.lib(d
llcrt0.obj)
libc.lib(dllcrt0.obj) : error LNK2005: __aenvptr already defined in LIBCMT.lib(d
llcrt0.obj)
libc.lib(crt0dat.obj) : error LNK2005: __cinit already defined in LIBCMT.lib(crt
0dat.obj)
libc.lib(crt0dat.obj) : error LNK2005: _exit already defined in LIBCMT.lib(crt0d
at.obj)
libc.lib(crt0dat.obj) : error LNK2005: __exit already defined in LIBCMT.lib(crt0
dat.obj)
libc.lib(crt0dat.obj) : error LNK2005: __cexit already defined in LIBCMT.lib(crt
0dat.obj)
libc.lib(crt0dat.obj) : error LNK2005: __c_exit already defined in LIBCMT.lib(cr
t0dat.obj)
libc.lib(crt0dat.obj) : error LNK2005: __C_Exit_Done already defined in LIBCMT.l
ib(crt0dat.obj)
libc.lib(crt0dat.obj) : error LNK2005: __C_Termination_Done already defined in L
IBCMT.lib(crt0dat.obj)
libc.lib(crt0dat.obj) : error LNK2005: __exitflag already defined in LIBCMT.lib(
crt0dat.obj)
libc.lib(crt0dat.obj) : error LNK2005: __wpgmptr already defined in LIBCMT.lib(c
rt0dat.obj)
libc.lib(crt0dat.obj) : error LNK2005: __pgmptr already defined in LIBCMT.lib(cr
t0dat.obj)
libc.lib(crt0dat.obj) : error LNK2005: ___winitenv already defined in LIBCMT.lib
(crt0dat.obj)
libc.lib(crt0dat.obj) : error LNK2005: __wenviron already defined in LIBCMT.lib(
crt0dat.obj)
libc.lib(crt0dat.obj) : error LNK2005: ___initenv already defined in LIBCMT.lib(
crt0dat.obj)
libc.lib(crt0dat.obj) : error LNK2005: __environ already defined in LIBCMT.lib(c
rt0dat.obj)
libc.lib(crt0dat.obj) : error LNK2005: ___wargv already defined in LIBCMT.lib(cr
t0dat.obj)
libc.lib(crt0dat.obj) : error LNK2005: ___argv already defined in LIBCMT.lib(crt
0dat.obj)
libc.lib(crt0dat.obj) : error LNK2005: ___argc already defined in LIBCMT.lib(crt
0dat.obj)
libc.lib(crt0dat.obj) : error LNK2005: __umaskval already defined in LIBCMT.lib(
crt0dat.obj)
Creating library libudf.lib and object libudf.exp
rate_driver.obj : error LNK2019: unresolved external symbol _chemrate_ reference
d in function _arm9_rate
libudf.dll : fatal error LNK1120: 1 unresolved externals
NMAKE : fatal error U1077: '"C:\Programmi\Microsoft Visual Studio 10.0\VC\BIN\li
nk.EXE"' : return code '0x460'
Stop.
Thank you for any help.
yorelchr is offline   Reply With Quote

Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
CFX11 + Fortran compiler ? Mohan CFX 20 March 30, 2011 19:56
UDF - Source Term Question Jacques FLUENT 0 December 8, 2008 14:40
UDF for energy source João Fernandes FLUENT 4 October 17, 2008 05:53
UDF: PROFILE + SOURCE Nuno FLUENT 0 September 1, 2008 16:31
UDF Scalar Code: HT 1 Greg Perkins FLUENT 8 October 20, 2000 13:40


All times are GMT -4. The time now is 09:21.