Am o problema legata de compilare. Imi apare eroare la linkarea bibliotecii partajate. Multumesc mult pentru orice ajutor!<br><br>Erorile intoarse de linker:<br><br>TestRW.obj : error LNK2019: unresolved external symbol "int __cdecl GetNrConds(void)" (?GetNrConds@@YAHXZ) referenced in function "void __cdecl TestRW(void)" (?TestRW@@YAXXZ)<br>
TestStres.obj : error LNK2001: unresolved external symbol "int __cdecl GetNrConds(void)" (?GetNrConds@@YAHXZ)<br>TestRW.obj : error LNK2019: unresolved external symbol "struct Monitor * __cdecl CreateRWMonitor(void)" (?CreateRWMonitor@@YAPAUMonitor@@XZ) referenced in function "void __cdecl TestRW(void)" (?TestRW@@YAXXZ)<br>
TestStres.obj : error LNK2001: unresolved external symbol "struct Monitor * __cdecl CreateRWMonitor(void)" (?CreateRWMonitor@@YAPAUMonitor@@XZ)<br>TestRW.obj : error LNK2019: unresolved external symbol "void __cdecl StopCit(struct Monitor *)" (?StopCit@@YAXPAUMonitor@@@Z) referenced in function "unsigned long __stdcall Functie1ABC(void *)" (?Functie1ABC@@YGKPAX@Z)<br>
TestStres.obj : error LNK2001: unresolved external symbol "void __cdecl StopCit(struct Monitor *)" (?StopCit@@YAXPAUMonitor@@@Z)<br>TestRW.obj : error LNK2019: unresolved external symbol "void __cdecl StartCit(struct Monitor *)" (?StartCit@@YAXPAUMonitor@@@Z) referenced in function "unsigned long __stdcall Functie1ABC(void *)" (?Functie1ABC@@YGKPAX@Z)<br>
TestStres.obj : error LNK2001: unresolved external symbol "void __cdecl StartCit(struct Monitor *)" (?StartCit@@YAXPAUMonitor@@@Z)<br>TestRW.obj : error LNK2019: unresolved external symbol "void __cdecl StopScrit(struct Monitor *)" (?StopScrit@@YAXPAUMonitor@@@Z) referenced in function "unsigned long __stdcall Functie2A(void *)" (?Functie2A@@YGKPAX@Z)<br>
TestRW.obj : error LNK2019: unresolved external symbol "void __cdecl StartScrit(struct Monitor *)" (?StartScrit@@YAXPAUMonitor@@@Z) referenced in function "unsigned long __stdcall Functie2A(void *)" (?Functie2A@@YGKPAX@Z)<br>
Test4.obj : error LNK2019: unresolved external symbol "int __cdecl Destroy(struct Monitor *)" (?Destroy@@YAHPAUMonitor@@@Z) referenced in function "void __cdecl IesireDinWait4(void)" (?IesireDinWait4@@YAXXZ)<br>
Test5.obj : error LNK2001: unresolved external symbol "int __cdecl Destroy(struct Monitor *)" (?Destroy@@YAHPAUMonitor@@@Z)<br>Test6.obj : error LNK2001: unresolved external symbol "int __cdecl Destroy(struct Monitor *)" (?Destroy@@YAHPAUMonitor@@@Z)<br>
TestStres.obj : error LNK2001: unresolved external symbol "int __cdecl Destroy(struct Monitor *)" (?Destroy@@YAHPAUMonitor@@@Z)<br>Test1.obj : error LNK2001: unresolved external symbol "int __cdecl Destroy(struct Monitor *)" (?Destroy@@YAHPAUMonitor@@@Z)<br>
Test2.obj : error LNK2001: unresolved external symbol "int __cdecl Destroy(struct Monitor *)" (?Destroy@@YAHPAUMonitor@@@Z)<br>Test3.obj : error LNK2001: unresolved external symbol "int __cdecl Destroy(struct Monitor *)" (?Destroy@@YAHPAUMonitor@@@Z)<br>
Test1.obj : error LNK2019: unresolved external symbol "int __cdecl Broadcast(struct Monitor *,int)" (?Broadcast@@YAHPAUMonitor@@H@Z) referenced in function "void __cdecl Test1(void)" (?Test1@@YAXXZ)<br>
Test4.obj : error LNK2001: unresolved external symbol "int __cdecl Broadcast(struct Monitor *,int)" (?Broadcast@@YAHPAUMonitor@@H@Z)<br>Test6.obj : error LNK2001: unresolved external symbol "int __cdecl Broadcast(struct Monitor *,int)" (?Broadcast@@YAHPAUMonitor@@H@Z)<br>
Test1.obj : error LNK2019: unresolved external symbol "int __cdecl Signal(struct Monitor *,int)" (?Signal@@YAHPAUMonitor@@H@Z) referenced in function "void __cdecl Test1(void)" (?Test1@@YAXXZ)<br>Test3.obj : error LNK2001: unresolved external symbol "int __cdecl Signal(struct Monitor *,int)" (?Signal@@YAHPAUMonitor@@H@Z)<br>
Test4.obj : error LNK2001: unresolved external symbol "int __cdecl Signal(struct Monitor *,int)" (?Signal@@YAHPAUMonitor@@H@Z)<br>Test5.obj : error LNK2001: unresolved external symbol "int __cdecl Signal(struct Monitor *,int)" (?Signal@@YAHPAUMonitor@@H@Z)<br>
Test6.obj : error LNK2019: unresolved external symbol "int __cdecl Wait(struct Monitor *,int)" (?Wait@@YAHPAUMonitor@@H@Z) referenced in function "void __cdecl Test6(void)" (?Test6@@YAXXZ)<br>Test1.obj : error LNK2001: unresolved external symbol "int __cdecl Wait(struct Monitor *,int)" (?Wait@@YAHPAUMonitor@@H@Z)<br>
Test3.obj : error LNK2001: unresolved external symbol "int __cdecl Wait(struct Monitor *,int)" (?Wait@@YAHPAUMonitor@@H@Z)<br>Test4.obj : error LNK2001: unresolved external symbol "int __cdecl Wait(struct Monitor *,int)" (?Wait@@YAHPAUMonitor@@H@Z)<br>
Test5.obj : error LNK2001: unresolved external symbol "int __cdecl Wait(struct Monitor *,int)" (?Wait@@YAHPAUMonitor@@H@Z)<br>Test5.obj : error LNK2019: unresolved external symbol "int __cdecl Leave(struct Monitor *)" (?Leave@@YAHPAUMonitor@@@Z) referenced in function "void __cdecl Test5(void)" (?Test5@@YAXXZ)<br>
Test6.obj : error LNK2001: unresolved external symbol "int __cdecl Leave(struct Monitor *)" (?Leave@@YAHPAUMonitor@@@Z)<br>Test1.obj : error LNK2001: unresolved external symbol "int __cdecl Leave(struct Monitor *)" (?Leave@@YAHPAUMonitor@@@Z)<br>
Test2.obj : error LNK2001: unresolved external symbol "int __cdecl Leave(struct Monitor *)" (?Leave@@YAHPAUMonitor@@@Z)<br>Test3.obj : error LNK2001: unresolved external symbol "int __cdecl Leave(struct Monitor *)" (?Leave@@YAHPAUMonitor@@@Z)<br>
Test4.obj : error LNK2001: unresolved external symbol "int __cdecl Leave(struct Monitor *)" (?Leave@@YAHPAUMonitor@@@Z)<br>Test5.obj : error LNK2019: unresolved external symbol "int __cdecl Enter(struct Monitor *)" (?Enter@@YAHPAUMonitor@@@Z) referenced in function "void __cdecl Test5(void)" (?Test5@@YAXXZ)<br>
Test6.obj : error LNK2001: unresolved external symbol "int __cdecl Enter(struct Monitor *)" (?Enter@@YAHPAUMonitor@@@Z)<br>Test1.obj : error LNK2001: unresolved external symbol "int __cdecl Enter(struct Monitor *)" (?Enter@@YAHPAUMonitor@@@Z)<br>
Test2.obj : error LNK2001: unresolved external symbol "int __cdecl Enter(struct Monitor *)" (?Enter@@YAHPAUMonitor@@@Z)<br>Test3.obj : error LNK2001: unresolved external symbol "int __cdecl Enter(struct Monitor *)" (?Enter@@YAHPAUMonitor@@@Z)<br>
Test4.obj : error LNK2001: unresolved external symbol "int __cdecl Enter(struct Monitor *)" (?Enter@@YAHPAUMonitor@@@Z)<br>Test5.obj : error LNK2019: unresolved external symbol "struct Monitor * __cdecl Create(int,char)" (?Create@@YAPAUMonitor@@HD@Z) referenced in function "void __cdecl Test5(void)" (?Test5@@YAXXZ)<br>
Test6.obj : error LNK2001: unresolved external symbol "struct Monitor * __cdecl Create(int,char)" (?Create@@YAPAUMonitor@@HD@Z)<br>Test1.obj : error LNK2001: unresolved external symbol "struct Monitor * __cdecl Create(int,char)" (?Create@@YAPAUMonitor@@HD@Z)<br>
Test2.obj : error LNK2001: unresolved external symbol "struct Monitor * __cdecl Create(int,char)" (?Create@@YAPAUMonitor@@HD@Z)<br>Test3.obj : error LNK2001: unresolved external symbol "struct Monitor * __cdecl Create(int,char)" (?Create@@YAPAUMonitor@@HD@Z)<br>
Test4.obj : error LNK2001: unresolved external symbol "struct Monitor * __cdecl Create(int,char)" (?Create@@YAPAUMonitor@@HD@Z)<br>../Test.exe : fatal error LNK1120: 13 unresolved externals<br><br>Asa arata headerele care exporta functiile:<br>
<br>#ifdef __cplusplus<br>extern "C" {<br>#endif<br><br>extern __declspec (dllexport) Monitor* Create(int conditions, char policy);<br>extern __declspec (dllexport) int Enter(Monitor *m);<br>extern __declspec (dllexport) int Leave(Monitor *m);<br>
extern __declspec (dllexport) int Wait(Monitor *m, int cond);<br>extern __declspec (dllexport) int Signal(Monitor *m, int cond);<br>extern __declspec (dllexport) int Broadcast(Monitor *m, int cond);<br>extern __declspec (dllexport) int Destroy(Monitor *m);<br>
<br>#ifdef __cplusplus<br>}<br>#endif<br><br>#ifdef __cplusplus<br>extern "C" {<br>#endif<br><br>__declspec (dllexport) void StartCit(Monitor* m);<br>__declspec (dllexport) void StopCit(Monitor *m);<br>__declspec (dllexport) void StartScrit(Monitor* m);<br>
__declspec (dllexport) void StopScrit(Monitor *m);<br>__declspec (dllexport) int GetNrConds();<br>__declspec (dllexport) Monitor* CreateRWMonitor();<br><br>#ifdef __cplusplus<br>}<br>#endif<br><br>