Ansys Products

Ansys Products

Discuss installation & licensing of our Ansys Teaching and Research products.

UDF Compiling issue in ANSYS Fluent

    • joshua.mimart
      Subscriber

      Hello everyone,

      I'm a french intern in National Technical University of Athens and I'm currently trying to compile a UDF file (2DGaussian.c) in order to create a moving heat source in ANSYS Fluent but the following error message appears :

      Setting Post Processing and Surfaces information ... Done.
      Copy "C:\Users\joshu\Desktop\UDF Test\2DGaussian.c" to "libudf\src"

      Creating user_nt.udf file for 3ddp_host ...

      Copyright 1987-2024 ANSYS, Inc. All Rights Reserved.
      Compiler and linker: Clang (builtin)

      scons: warning: No version of Visual Studio compiler found - C/C++ compilers most likely not set correctly
      File "C:\Users\joshu\Desktop\Test_avec_fluent_files\dp0\FFF\Fluent\libudf\win64\3ddp_host\SConstruct", line 20, in
      Compiler path: "C:\PROGRA~1\ANSYSI~1\ANSYSS~1\v242\fluent"\ntbin\clang\bin\clang-cl
      Linker path: "C:\PROGRA~1\ANSYSI~1\ANSYSS~1\v242\fluent"\ntbin\clang\bin\lld-link

      scons: warning: No version of Visual Studio compiler found - C/C++ compilers most likely not set correctly
      File "C:\Users\joshu\Desktop\Test_avec_fluent_files\dp0\FFF\Fluent\libudf\win64\3ddp_host\SConstruct", line 156, in
      C sources: ['2DGaussian.c']
      lld-link: error: undefined symbol: ??w
      >>> referenced by 2DGaussian.obj:(gauss2D_heat_flux)
      scons: *** [libudf.dll] Error 1
      Creating user_nt.udf file for 3ddp_node ...

      Copyright 1987-2024 ANSYS, Inc. All Rights Reserved.
      Compiler and linker: Clang (builtin)

      scons: warning: No version of Visual Studio compiler found - C/C++ compilers most likely not set correctly
      File "C:\Users\joshu\Desktop\Test_avec_fluent_files\dp0\FFF\Fluent\libudf\win64\3ddp_node\SConstruct", line 20, in
      Compiler path: "C:\PROGRA~1\ANSYSI~1\ANSYSS~1\v242\fluent"\ntbin\clang\bin\clang-cl
      Linker path: "C:\PROGRA~1\ANSYSI~1\ANSYSS~1\v242\fluent"\ntbin\clang\bin\lld-link

      scons: warning: No version of Visual Studio compiler found - C/C++ compilers most likely not set correctly
      File "C:\Users\joshu\Desktop\Test_avec_fluent_files\dp0\FFF\Fluent\libudf\win64\3ddp_node\SConstruct", line 156, in
      C sources: ['2DGaussian.c']
      lld-link: error: undefined symbol: ??w
      >>> referenced by 2DGaussian.obj:(gauss2D_heat_flux)
      scons: *** [libudf.dll] Error 1

      Done.
      Copy "C:\Users\joshu\Desktop\UDF Test\2DGaussian.c" to "libudf\src"

      Files udf_names.c and user_nt.udf in 3ddp_host are up-to-date.

      Copyright 1987-2024 ANSYS, Inc. All Rights Reserved.
      Compiler and linker: Clang (builtin)

      scons: warning: No version of Visual Studio compiler found - C/C++ compilers most likely not set correctly
      File "C:\Users\joshu\Desktop\Test_avec_fluent_files\dp0\FFF\Fluent\libudf\win64\3ddp_host\SConstruct", line 20, in
      Compiler path: "C:\PROGRA~1\ANSYSI~1\ANSYSS~1\v242\fluent"\ntbin\clang\bin\clang-cl
      Linker path: "C:\PROGRA~1\ANSYSI~1\ANSYSS~1\v242\fluent"\ntbin\clang\bin\lld-link

      scons: warning: No version of Visual Studio compiler found - C/C++ compilers most likely not set correctly
      File "C:\Users\joshu\Desktop\Test_avec_fluent_files\dp0\FFF\Fluent\libudf\win64\3ddp_host\SConstruct", line 156, in
      C sources: ['2DGaussian.c']
      lld-link: error: undefined symbol: ??w
      >>> referenced by 2DGaussian.obj:(gauss2D_heat_flux)
      scons: *** [libudf.dll] Error 1
      Files udf_names.c and user_nt.udf in 3ddp_node are up-to-date.

      Copyright 1987-2024 ANSYS, Inc. All Rights Reserved.
      Compiler and linker: Clang (builtin)

      scons: warning: No version of Visual Studio compiler found - C/C++ compilers most likely not set correctly
      File "C:\Users\joshu\Desktop\Test_avec_fluent_files\dp0\FFF\Fluent\libudf\win64\3ddp_node\SConstruct", line 20, in
      Compiler path: "C:\PROGRA~1\ANSYSI~1\ANSYSS~1\v242\fluent"\ntbin\clang\bin\clang-cl
      Linker path: "C:\PROGRA~1\ANSYSI~1\ANSYSS~1\v242\fluent"\ntbin\clang\bin\lld-link

      scons: warning: No version of Visual Studio compiler found - C/C++ compilers most likely not set correctly
      File "C:\Users\joshu\Desktop\Test_avec_fluent_files\dp0\FFF\Fluent\libudf\win64\3ddp_node\SConstruct", line 156, in
      C sources: ['2DGaussian.c']
      lld-link: error: undefined symbol: ??w
      >>> referenced by 2DGaussian.obj:(gauss2D_heat_flux)
      scons: *** [libudf.dll] Error 1

      Done.

      Could anyone help me with this problem please?

    • Rob
      Forum Moderator

      Can you try compiling with the CLANG (built in) compiler when launching Fluent from the Start menu? 

Viewing 1 reply thread
  • You must be logged in to reply to this topic.