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

UDF on SGI

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   August 7, 2000, 11:06
Default UDF on SGI
  #1
Diana
Guest
 
Posts: n/a
Hello

I am trying to write a UDF (Fluent 5.1) to run on my SGI Octane computer. I only have the GNU compilers - I do not have the SGI ones.

I have real problems (i.e. it doesn't work) trying to get either the interpreted or compiled udf's to 'compile'. I get an error message saying:

/Fluent.Inc/fluent5.1/src/mem.h:49: conflicting types for `cell_t'

/usr/include/sys/types.h:202: previous declaration of `cell_t'

This is for basic examples copied exactly from the examples given in the Fluent UDF guide. If I add other things, there are even more errors and conflicts.

Please Help me.
  Reply With Quote

Old   August 8, 2000, 03:17
Default Re: UDF on SGI
  #2
Sebastien DANIEL
Guest
 
Posts: n/a
Hey,

I got the same issues with different UDFs I typed but actually it is running good.

"conflicting types for 'cell_t'" seems to be a persistent bug on the UDF compiler. You can begin by checking your src and Makefile directory and ensure the user command directory is correct (I got these issue with SGI before).

Then check if you can run without 'cell_t' in your UDF. This is strange but sometime it is running after.

I hope I help you.

Sebastian
  Reply With Quote

Old   August 8, 2000, 13:11
Default Re: UDF on SGI
  #3
Chris
Guest
 
Posts: n/a
Unfortunately, both fluent and Irix are defining the symbol cell_t as a type, and the definitions are not compatible.

Your options are to either not to include one of the
definitions or changing the symbol being defined. Not including the definitions is probably not feasible, since you need the fluent cell_t definition for any non-trivial UDF, and the Irix definition is in a very common system include file (/usr/include/sys/types.h).

So the best bet is to change the symbol being defined.
Try these as the first lines in your UDF:


#define cell_t IRIX_CELL_T
#include <sys/types.h>
#undef cell_t

#include "udf.h"


Hope that helps.
  Reply With Quote

Old   August 8, 2000, 13:15
Default Re: UDF on SGI
  #4
Chris
Guest
 
Posts: n/a
Uh oh, the html didn't like my include file name.

The file name should be sys/types.h and it should be enclosed within angle brackets (less-than and greater-than signs).

#include sys/types.h
  Reply With Quote

Old   August 10, 2000, 05:20
Default Re: UDF on SGI
  #5
Rüdiger Schwarze
Guest
 
Posts: n/a
Change the compiler flags in the makefile from

CFLAGS_IRIX...= -KPIC -ansi -fullwarn -O -n32

to

CFLAGS_IRIX...= -KPIC -xansi -fullwarn -O -n32

  Reply With Quote

Reply


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
Dynamic Mesh UDF Qureshi FLUENT 7 March 23, 2017 08:37
UDF parallel error: chip-exec: function not found????? shankara.2 Fluent UDF and Scheme Programming 1 January 16, 2012 23:14
How to add a UDF to a compiled UDF library kim FLUENT 3 October 26, 2011 22:38
UDF...UDF...UDF...UDF Luc SEMINEL FLUENT 0 November 25, 2002 05:03
UDF, UDF, UDF, UDF Luc SEMINEL Main CFD Forum 0 November 25, 2002 05:01


All times are GMT -4. The time now is 01:31.