Intel® Fortran Compiler
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.
29140 Discussions

LIB file not being generated in DLL project

ferrad1
New Contributor I
1,433 Views

I have a base DLL project test_lib.vfproj which successfully creates a DLL and LIB file in the output directory.  I created a cut down project test2_lib.vfproj, by copying the test_lib vfproj file, and edited the vfproj file to rename all occurrences of test_lib to test2_lib, and rebuilt test2_lib.vfproj.  However test2_lib.lib is not created (the DLL is).  The command line has /IMPLIB:"F:\Proj\tmp\test2_lib\Debug\x64\test2_lib.lib" which is where the DLL is built too.

Any idea why is the LIB not being built?

0 Kudos
1 Solution
Arjen_Markus
Honored Contributor II
1,422 Views

Yes, you need to explicitly export one or more routines from the library via a compiler directive:

 

!DEC$ ATTRIBUTES DLLEXPORT :: routinename

 

This appears after the subroutine or function statement.

View solution in original post

2 Replies
Arjen_Markus
Honored Contributor II
1,423 Views

Yes, you need to explicitly export one or more routines from the library via a compiler directive:

 

!DEC$ ATTRIBUTES DLLEXPORT :: routinename

 

This appears after the subroutine or function statement.

ferrad1
New Contributor I
1,411 Views

aah yes, of course, thank you!

0 Kudos
Reply