blueCFD / Core

Coordination repository for the blueCFD-Core: Issue tracking, Wiki, project webpage and miscellaneous scripts
http://bluecfd.github.io/Core
53 stars 10 forks source link

wmake link error when compiling normalizedHelicity function Object tutorial #138

Closed dedeWGT closed 4 years ago

dedeWGT commented 4 years ago

Hello, when trying to work through the normalizedHelicity function Object tutorial I get a link error from wmake and I have no clue where I should start looking for it. Heres the compilation output:

$ wmake $(/home/ofuser/blueCFD/OpenFOAM-5.x/wmake/scripts/makeReinterpretExePath x86_64-w64-mingw32-g++) -std=c++11 -Dmingw_w64 -DWM_ARCH_OPTION=64 -DWM_DP -DWM_LABEL_SIZE=32 -DWIN64 -DLITTLE_ENDIAN -DWIN64 -DLITTLE_ENDIAN -Wall -Wextra -Wold-style-cast -Wnon-virtual-dtor -Wno-unused-parameter -Wno-invalid-offsetof -O2 -DNDEBUG -gdwarf -DNoRepository -ftemplate-depth-100 -D_FILE_OFFSET_BITS=64 -D_MODET -I/home/ofuser/blueCFD/OpenFOAM-5.x/src/finiteVolume/lnInclude -I/home/ofuser/blueCFD/OpenFOAM-5.x/src/meshTools/lnInclude -I/home/ofuser/blueCFD/OpenFOAM-5.x/src/lagrangian/basic/lnInclude -I/home/ofuser/blueCFD/OpenFOAM-5.x/src/fileFormats/lnInclude -I/home/ofuser/blueCFD/OpenFOAM-5.x/src/sampling/lnInclude -I/home/ofuser/blueCFD/OpenFOAM-5.x/src/surfMesh/lnInclude -I/home/ofuser/blueCFD/OpenFOAM-5.x/src/thermophysicalModels/basic/lnInclude -I/home/ofuser/blueCFD/OpenFOAM-5.x/src/thermophysicalModels/solidThermo/lnInclude -I/home/ofuser/blueCFD/OpenFOAM-5.x/src/transportModels -I/home/ofuser/blueCFD/OpenFOAM-5.x/src/transportModels/compressible/lnInclude -I/home/ofuser/blueCFD/OpenFOAM-5.x/src/TurbulenceModels/turbulenceModels/lnInclude -I/home/ofuser/blueCFD/OpenFOAM-5.x/src/TurbulenceModels/incompressible/lnInclude -I/home/ofuser/blueCFD/OpenFOAM-5.x/src/TurbulenceModels/compressible/lnInclude -I/home/ofuser/blueCFD/OpenFOAM-5.x/src/functionObjects/field/lnInclude @Make/mingw_w64GccDPInt32Opt/includeHeaderPaths -IlnInclude -I. -I/home/ofuser/blueCFD/OpenFOAM-5.x/src/OpenFOAM/lnInclude -I/home/ofuser/blueCFD/OpenFOAM-5.x/src/OSspecific/MSwindows/lnInclude -Wl,--output-def,/home/ofuser/blueCFD/OpenFOAM-5.x/platforms/mingw_w64GccDPInt32Opt/lib/libfieldFunctionObjects.def -Wl,--out-implib,/home/ofuser/blueCFD/OpenFOAM-5.x/platforms/mingw_w64GccDPInt32Opt/lib/libfieldFunctionObjects.a -Wl,--enable-auto-import -shared @Make/mingw_w64GccDPInt32Opt/objectList -L/home/ofuser/blueCFD/OpenFOAM-5.x/platforms/mingw_w64GccDPInt32Opt/lib \ -lOpenFOAM -L/home/ofuser/blueCFD/OpenFOAM-5.x/platforms/mingw_w64GccDPInt32Opt/lib/MS-MPI-7.1 -lPstream -lfiniteVolume -lfluidThermophysicalModels -lsolidThermo -lincompressibleTransportModels -lturbulenceModels -lcompressibleTransportModels -lincompressibleTurbulenceModels -lcompressibleTurbulenceModels -lmeshTools -lsurfMesh -llagrangian -lfileFormats -lsampling -lsurfMesh -lfieldFunctionObjects -o /home/ofuser/blueCFD/OpenFOAM-5.x/platforms/mingw_w64GccDPInt32Opt/lib/libfieldFunctionObjects.dll Make/mingw_w64GccDPInt32Opt/normalizedHelicity/normalizedHelicity.o: In Funktion ▒Foam::functionObjects::normalizedHelicity::~normalizedHelicity()▒: C:\PROGRA~1\BLUECF~1\ofuser-of5\src\functionObjects\field/normalizedHelicity/normalizedHelicity.C:86: Warnung: undefinierter Verweis auf ▒Foam::functionObjects::fieldExpression::~fieldExpression()▒ Make/mingw_w64GccDPInt32Opt/normalizedHelicity/normalizedHelicity.o: In Funktion ▒Foam::functionObjects::normalizedHelicity::normalizedHelicity(Foam::word const&, Foam::Time const&, Foam::dictionary const&)▒: C:\PROGRA~1\BLUECF~1\ofuser-of5\src\functionObjects\field/normalizedHelicity/normalizedHelicity.C:78: Warnung: undefinierter Verweis auf ▒Foam::functionObjects::fieldExpression::fieldExpression(Foam::word const&, Foam::Time const&, Foam::dictionary const&, Foam::word const&, Foam::word const&)▒ C:\PROGRA~1\BLUECF~1\ofuser-of5\src\functionObjects\field/normalizedHelicity/normalizedHelicity.C:80: Warnung: undefinierter Verweis auf ▒Foam::functionObjects::fieldExpression::setResultName(Foam::word const&, Foam::word const&)▒ C:\PROGRA~1\BLUECF~1\ofuser-of5\src\functionObjects\field/normalizedHelicity/normalizedHelicity.C:78: Warnung: undefinierter Verweis auf ▒Foam::functionObjects::fieldExpression::~fieldExpression()▒ Make/mingw_w64GccDPInt32Opt/normalizedHelicity/normalizedHelicity.o: In Funktion ▒Foam::functionObjects::normalizedHelicity::~normalizedHelicity()▒: C:\PROGRA~1\BLUECF~1\ofuser-of5\src\functionObjects\field/normalizedHelicity/normalizedHelicity.C:86: Warnung: undefinierter Verweis auf ▒Foam::functionObjects::fieldExpression::~fieldExpression()▒ Make/mingw_w64GccDPInt32Opt/normalizedHelicity/normalizedHelicity.o:normalizedHelicity.C:(.rdata$_ZTVN4Foam15functionObjects18normalizedHelicityE[_ZTVN4Foam15functionObjects18normalizedHelicityE]+0x28): Warnung: undefinierter Verweis auf ▒Foam::functionObjects::fieldExpression::read(Foam::dictionary const&)▒ Make/mingw_w64GccDPInt32Opt/normalizedHelicity/normalizedHelicity.o:normalizedHelicity.C:(.rdata$_ZTVN4Foam15functionObjects18normalizedHelicityE[_ZTVN4Foam15functionObjects18normalizedHelicityE]+0x30): Warnung: undefinierter Verweis auf ▒Foam::functionObjects::fieldExpression::execute()▒ Make/mingw_w64GccDPInt32Opt/normalizedHelicity/normalizedHelicity.o:normalizedHelicity.C:(.rdata$_ZTVN4Foam15functionObjects18normalizedHelicityE[_ZTVN4Foam15functionObjects18normalizedHelicityE]+0x38): Warnung: undefinierter Verweis auf ▒Foam::functionObjects::fieldExpression::write()▒ Make/mingw_w64GccDPInt32Opt/normalizedHelicity/normalizedHelicity.o:normalizedHelicity.C:(.rdata$_ZTVN4Foam15functionObjects18normalizedHelicityE[_ZTVN4Foam15functionObjects18normalizedHelicityE]+0x68): Warnung: undefinierter Verweis auf ▒Foam::functionObjects::fieldExpression::clear()▒ collect2.exe: error: ld returned 1 exit status make: *** [/home/ofuser/blueCFD/OpenFOAM-5.x/wmake/makefiles/general:214: /home/ofuser/blueCFD/OpenFOAM-5.x/platforms/mingw_w64GccDPInt32Opt/lib/libfieldFunctionObjects.dll] Fehler 1

Could somebody give me a hint ? best regards, dede

wyldckat commented 4 years ago

If it's a tutorial, please share the source code files, if possible. Or please let us know where we can find this tutorial, so that we can try to reproduce this issue.

I ask this because since the error messages are in German, it makes it a bit harder to quickly diagnose what happened...

dedeWGT commented 4 years ago

Ok, the problem is sitting in front of the computer:

  1. I did not change the library name to my personal library and then there's no permission to write the file.
  2. "wmake field" does the job without messing up / and \ in the file path.
  3. I needed to add the functionality in the "./etc/caseDicts/postProcessing/fields/" directory to make it work with "postProcess -func". cheers, dede
wyldckat commented 4 years ago

Excellent! Now my conscience is cleared... not having had time to answer you, but also gave you the opportunity to figure it out for yourself with success :)