Author Topic: UMESH error  (Read 2681 times)

Dipankar

  • New Member
  • *
  • Posts: 2
UMESH error
« on: February 06, 2015, 03:51:29 PM »
Hi,

I am working with fiber element.  I am getting some errors during the time of building the files. I have created two projects according to the installation process mentioned in feappv website: the name of the first project is “main” where “main.lib” resides and the second one is “user” where “feappv.f” and “user.exe” belongs and “main.lib” is linked with “feappv.f” as per the instructions given in the website.

I have added these user files to the “user” project. One of the user file is “Umesh.f90” where I have 12 subroutines such as Umesh1 (prt) to Umesh12 (prt) for adding various macros to the input file. Also, “main” project contains 5 nos umesh1.f to umesh5.f subroutines, one function umesh.f and one umshlib.f subroutine. And, umesh.f function and umshlib.f is connected to pmesh.f.

During building the files from “user” project, I am getting errors as “main.lib (umesh1.obj): error LNK2005: _UMESH1 already defined in Umesh.obj”.
I need your kind suggestion to rectify this problem.

Also, I would like to mention that the same fiber element was successfully running in the previous version of feappv around 2011. Whereas, presently I am using the downloaded feappv source file updated on 12 August 2013.

Thanks,
Dipankar
« Last Edit: February 06, 2015, 04:22:54 PM by Dipankar »

Prof. R.L. Taylor

  • Administrator
  • FEAP Guru
  • *****
  • Posts: 2647
Re: UMESH error
« Reply #1 on: February 07, 2015, 07:53:38 AM »
Is this a Windows or a Unix/Mac build?  You cannot have two routines with the same name.  You need to have unique names for the routines.  You may need to delete the "dummy" routines from the library build to avoid the conflict.

FEAP_Admin

  • Administrator
  • FEAP Guru
  • *****
  • Posts: 993
Re: UMESH error
« Reply #2 on: February 07, 2015, 12:43:37 PM »
Deleting dummy routines from "main" should not be necessary.
Linux or Windows.

In "user" are you creating a library "user.lib" with your new user files and then linking it with "main.lib" + feappv.f?
If that is the case, then you way want to try not sticking your new files in a library and just linking them directly with "main.lib".