CFD Online Discussion Forums

CFD Online Discussion Forums (
-   FLUENT (
-   -   HELP: udf compiling mistake (

Siyu June 25, 2006 08:39

HELP: udf compiling mistake
udf userguide (eg. 4.6.12)

when I compiled the udf, mistake occured and libudf.dll could not be built. Who can tell me what wrong with it?

..\..\src\condense.c(64) : warning C4047: 'initializing' : 'struct thread_struct *' differs in levels of indirection from 'int ' # Generating udf_names.c because of makefile condense.obj udf_names.c # Linking libudf.dll because of makefile user_nt.udf udf_names.obj condense.obj Microsoft (R) Incremental Linker Version 6.00.8447 Copyright (C) Microsoft Corp 1992-1998. All rights reserved.

Creating library libudf.lib and object libudf.exp condense.obj : error LNK2001: unresolved external symbol _P_THREAD libudf.dll : fatal error LNK1120: 1 unresolved externals

DEFINE_DPM_LAW(condenshumidlaw,p,coupled) { real area; real mp_dot; cell_t c = P_CELL(p); /* Get Cell and Thread from */ Thread *t = P_THREAD(p); /* Particle Structure using new macros*/

(this is the warning line.)

area = 4.0* M_PI * (P_DIAM(p)*P_DIAM(p));

/* Note This law only used if Humidity > 1.0 so mp_dot always positive*/ mp_dot = CONDENS*sqrt(area)*(myHumidity(c,t)-1.0);

if(mp_dot>0.0) {

P_MASS(p) = P_MASS(p) + mp_dot*P_DT(p);

P_DIAM(p) = pow(6.0*P_MASS(p)/(P_RHO(p)* M_PI), 1./3.);

P_T(p)=C_T(c,t); /* Assume condensing particle is in thermal

equilibrium with fluid in cell */ }

web yin June 26, 2006 06:43

Re: HELP: udf compiling mistake
what you did is the interpreted file ,not compiled files ,there are some differnces between them

Siyu June 26, 2006 06:58

Re: HELP: udf compiling mistake
Thank you. I finally found the wrong. The right marco is "P_CELL_THREAD" not the "P_thread".

All times are GMT -4. The time now is 10:06.