Jump to content
  • Advertisement
Sign in to follow this  
Teamsmash

Unresolved External Symbols

This topic is 3753 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I'm fresh out of high school where they taught Java, and during summer break I'm trying to get some experience with C++ using the DirectX Tutorials, but cannot get a sample to work in Visual C++ 2005 Express Edition. I downloaded the Windows SDK, since I'm running Vista, and have added the include and library directories, but receive a bunch of unresolved external symbol errors. I read a few threads on a similar problem, each of which were resolved in the end, but I couldn't quite follow the advice... Any help is much appreciated. Here's the program:
#include <windows.h>    // include the basic windows header file

// the entry point for any Windows program
int WINAPI WinMain(HINSTANCE hInstance,
                   HINSTANCE hPrevInstance,
                   LPSTR lpCmdLine,
                   int nShowCmd)
{
    // create a "Hello World" message box using MessageBox()
    MessageBox(NULL,
               L"Hello World!",
               L"Just another Hello World program!",
               MB_ICONEXCLAMATION | MB_OK);

    // return 0 to Windows
    return 0;
}

Share this post


Link to post
Share on other sites
Advertisement
First: it doesn't appear you have a question on DirectX and other forums may be more appropriate for where you currently are with C++.

Second: You say you're getting some errors. Can you give us some more info? Like, what are the errors?

Share this post


Link to post
Share on other sites
Sorry if I posted in the wrong forum...

[Edit] - Also sorry for the screen stretch =/ Fixed.

Here's the output I get:
------ Build started: Project: Hello, Configuration: Debug Win32 ------
1>Compiling...
1>main.c
1>.\main.c(11) : warning C4133: 'function' : incompatible types - from 'unsigned short [13]' to 'LPCSTR'
1>.\main.c(12) : warning C4133: 'function' : incompatible types - from 'unsigned short [34]' to 'LPCSTR'
1>Linking...
1>main.obj : error LNK2019: unresolved external symbol __imp__MessageBoxA@16 referenced in function _WinMain@16
1>LIBCMT.lib(wincrt0.obj) : error LNK2019: unresolved external symbol __imp__GetCommandLineA@0 referenced in function ___tmainCRTStartup
1>LIBCMT.lib(wincrt0.obj) : error LNK2019: unresolved external symbol __imp__HeapFree@12 referenced in function ___tmainCRTStartup
1>LIBCMT.lib(heapinit.obj) : error LNK2001: unresolved external symbol __imp__HeapFree@12
1>LIBCMT.lib(free.obj) : error LNK2001: unresolved external symbol __imp__HeapFree@12
1>LIBCMT.lib(sbheap.obj) : error LNK2001: unresolved external symbol __imp__HeapFree@12
1>LIBCMT.lib(wincrt0.obj) : error LNK2019: unresolved external symbol __imp__GetVersionExA@4 referenced in function ___tmainCRTStartup
1>LIBCMT.lib(realloc.obj) : error LNK2001: unresolved external symbol __imp__HeapAlloc@12
1>LIBCMT.lib(wincrt0.obj) : error LNK2019: unresolved external symbol __imp__HeapAlloc@12 referenced in function ___tmainCRTStartup
1>LIBCMT.lib(sbheap.obj) : error LNK2001: unresolved external symbol __imp__HeapAlloc@12
1>LIBCMT.lib(malloc.obj) : error LNK2001: unresolved external symbol __imp__HeapAlloc@12
1>LIBCMT.lib(calloc.obj) : error LNK2001: unresolved external symbol __imp__HeapAlloc@12
1>LIBCMT.lib(wincrt0.obj) : error LNK2019: unresolved external symbol __imp__GetProcessHeap@0 referenced in function ___tmainCRTStartup
1>LIBCMT.lib(wincrt0.obj) : error LNK2019: unresolved external symbol __imp__GetStartupInfoA@4 referenced in function ___tmainCRTStartup
1>LIBCMT.lib(ioinit.obj) : error LNK2001: unresolved external symbol __imp__GetStartupInfoA@4
1>LIBCMT.lib(unhandld.obj) : error LNK2019: unresolved external symbol __imp__SetUnhandledExceptionFilter@4 referenced in function ___CxxSetUnhandledExceptionFilter
1>LIBCMT.lib(invarg.obj) : error LNK2001: unresolved external symbol __imp__SetUnhandledExceptionFilter@4
1>LIBCMT.lib(abort.obj) : error LNK2001: unresolved external symbol __imp__SetUnhandledExceptionFilter@4
1>LIBCMT.lib(gs_report.obj) : error LNK2001: unresolved external symbol __imp__SetUnhandledExceptionFilter@4
1>LIBCMT.lib(crtmbox.obj) : error LNK2019: unresolved external symbol __imp__GetProcAddress@8 referenced in function ___crtMessageBoxA
1>LIBCMT.lib(crt0dat.obj) : error LNK2001: unresolved external symbol __imp__GetProcAddress@8
1>LIBCMT.lib(tidtable.obj) : error LNK2001: unresolved external symbol __imp__GetProcAddress@8
1>LIBCMT.lib(rand_s.obj) : error LNK2001: unresolved external symbol __imp__GetProcAddress@8
1>LIBCMT.lib(initcrit.obj) : error LNK2001: unresolved external symbol __imp__GetProcAddress@8
1>LIBCMT.lib(crt0dat.obj) : error LNK2019: unresolved external symbol __imp__GetModuleHandleA@4 referenced in function ___crtCorExitProcess
1>LIBCMT.lib(tidtable.obj) : error LNK2001: unresolved external symbol __imp__GetModuleHandleA@4
1>LIBCMT.lib(initcrit.obj) : error LNK2001: unresolved external symbol __imp__GetModuleHandleA@4
1>LIBCMT.lib(crt0dat.obj) : error LNK2019: unresolved external symbol __imp__ExitProcess@4 referenced in function ___crtExitProcess
1>LIBCMT.lib(crt0msg.obj) : error LNK2019: unresolved external symbol __imp__WriteFile@20 referenced in function __NMSG_WRITE
1>LIBCMT.lib(crt0msg.obj) : error LNK2019: unresolved external symbol __imp__GetStdHandle@4 referenced in function __NMSG_WRITE
1>LIBCMT.lib(ioinit.obj) : error LNK2001: unresolved external symbol __imp__GetStdHandle@4
1>LIBCMT.lib(crt0msg.obj) : error LNK2019: unresolved external symbol __imp__GetModuleFileNameA@12 referenced in function __NMSG_WRITE
1>LIBCMT.lib(stdargv.obj) : error LNK2001: unresolved external symbol __imp__GetModuleFileNameA@12
1>LIBCMT.lib(a_env.obj) : error LNK2019: unresolved external symbol __imp__FreeEnvironmentStringsA@4 referenced in function ___crtGetEnvironmentStringsA
1>LIBCMT.lib(a_env.obj) : error LNK2019: unresolved external symbol __imp__GetEnvironmentStrings@0 referenced in function ___crtGetEnvironmentStringsA
1>LIBCMT.lib(a_env.obj) : error LNK2019: unresolved external symbol __imp__FreeEnvironmentStringsW@4 referenced in function ___crtGetEnvironmentStringsA
1>LIBCMT.lib(tzset.obj) : error LNK2001: unresolved external symbol __imp__WideCharToMultiByte@32
1>LIBCMT.lib(wtombenv.obj) : error LNK2001: unresolved external symbol __imp__WideCharToMultiByte@32
1>LIBCMT.lib(w_str.obj) : error LNK2001: unresolved external symbol __imp__WideCharToMultiByte@32
1>LIBCMT.lib(a_env.obj) : error LNK2019: unresolved external symbol __imp__WideCharToMultiByte@32 referenced in function ___crtGetEnvironmentStringsA
1>LIBCMT.lib(a_loc.obj) : error LNK2001: unresolved external symbol __imp__WideCharToMultiByte@32
1>LIBCMT.lib(a_map.obj) : error LNK2001: unresolved external symbol __imp__WideCharToMultiByte@32
1>LIBCMT.lib(convrtcp.obj) : error LNK2001: unresolved external symbol __imp__WideCharToMultiByte@32
1>LIBCMT.lib(a_cmp.obj) : error LNK2001: unresolved external symbol __imp__GetLastError@0
1>LIBCMT.lib(a_map.obj) : error LNK2001: unresolved external symbol __imp__GetLastError@0
1>LIBCMT.lib(a_str.obj) : error LNK2001: unresolved external symbol __imp__GetLastError@0
1>LIBCMT.lib(realloc.obj) : error LNK2019: unresolved external symbol __imp__GetLastError@0 referenced in function _realloc
1>LIBCMT.lib(w_str.obj) : error LNK2001: unresolved external symbol __imp__GetLastError@0
1>LIBCMT.lib(inithelp.obj) : error LNK2001: unresolved external symbol __imp__GetLastError@0
1>LIBCMT.lib(free.obj) : error LNK2001: unresolved external symbol __imp__GetLastError@0
1>LIBCMT.lib(w_loc.obj) : error LNK2001: unresolved external symbol __imp__GetLastError@0
1>LIBCMT.lib(a_loc.obj) : error LNK2001: unresolved external symbol __imp__GetLastError@0
1>LIBCMT.lib(a_env.obj) : error LNK2001: unresolved external symbol __imp__GetLastError@0
1>LIBCMT.lib(tidtable.obj) : error LNK2001: unresolved external symbol __imp__GetLastError@0
1>LIBCMT.lib(winsig.obj) : error LNK2001: unresolved external symbol __imp__GetLastError@0
1>LIBCMT.lib(rand_s.obj) : error LNK2001: unresolved external symbol __imp__GetLastError@0
1>LIBCMT.lib(a_env.obj) : error LNK2019: unresolved external symbol __imp__GetEnvironmentStringsW@0 referenced in function ___crtGetEnvironmentStringsA
1>LIBCMT.lib(ioinit.obj) : error LNK2019: unresolved external symbol __imp__SetHandleCount@4 referenced in function __ioinit
1>LIBCMT.lib(ioinit.obj) : error LNK2019: unresolved external symbol __imp__GetFileType@4 referenced in function __ioinit
1>LIBCMT.lib(ioinit.obj) : error LNK2019: unresolved external symbol __imp__DeleteCriticalSection@4 referenced in function __ioterm
1>LIBCMT.lib(mlock.obj) : error LNK2001: unresolved external symbol __imp__DeleteCriticalSection@4
1>LIBCMT.lib(tidtable.obj) : error LNK2019: unresolved external symbol __imp__TlsGetValue@4 referenced in function __encode_pointer
1>LIBCMT.lib(tidtable.obj) : error LNK2019: unresolved external symbol __imp__TlsAlloc@0 referenced in function ___crtTlsAlloc@4
1>LIBCMT.lib(tidtable.obj) : error LNK2019: unresolved external symbol __imp__TlsSetValue@8 referenced in function ___set_flsgetvalue
1>LIBCMT.lib(tidtable.obj) : error LNK2019: unresolved external symbol __imp__TlsFree@4 referenced in function __mtterm
1>LIBCMT.lib(tidtable.obj) : error LNK2019: unresolved external symbol __imp__InterlockedIncrement@4 referenced in function __initptd
1>LIBCMT.lib(mbctype.obj) : error LNK2001: unresolved external symbol __imp__InterlockedIncrement@4
1>LIBCMT.lib(setlocal.obj) : error LNK2001: unresolved external symbol __imp__InterlockedIncrement@4
1>LIBCMT.lib(tidtable.obj) : error LNK2019: unresolved external symbol __imp__SetLastError@4 referenced in function __getptd_noexit
1>LIBCMT.lib(initcrit.obj) : error LNK2001: unresolved external symbol __imp__SetLastError@4
1>LIBCMT.lib(tidtable.obj) : error LNK2019: unresolved external symbol __imp__GetCurrentThreadId@0 referenced in function __getptd_noexit
1>LIBCMT.lib(gs_support.obj) : error LNK2001: unresolved external symbol __imp__GetCurrentThreadId@0
1>LIBCMT.lib(initnum.obj) : error LNK2001: unresolved external symbol __imp__InterlockedDecrement@4
1>LIBCMT.lib(initmon.obj) : error LNK2001: unresolved external symbol __imp__InterlockedDecrement@4
1>LIBCMT.lib(initctyp.obj) : error LNK2001: unresolved external symbol __imp__InterlockedDecrement@4
1>LIBCMT.lib(tidtable.obj) : error LNK2019: unresolved external symbol __imp__InterlockedDecrement@4 referenced in function __freefls@4
1>LIBCMT.lib(mbctype.obj) : error LNK2001: unresolved external symbol __imp__InterlockedDecrement@4
1>LIBCMT.lib(setlocal.obj) : error LNK2001: unresolved external symbol __imp__InterlockedDecrement@4
1>LIBCMT.lib(inittime.obj) : error LNK2001: unresolved external symbol __imp__InterlockedDecrement@4
1>LIBCMT.lib(tidtable.obj) : error LNK2019: unresolved external symbol __imp__GetCurrentThread@0 referenced in function ___threadhandle
1>LIBCMT.lib(heapinit.obj) : error LNK2019: unresolved external symbol __imp__HeapDestroy@4 referenced in function __heap_init
1>LIBCMT.lib(heapinit.obj) : error LNK2019: unresolved external symbol __imp__HeapCreate@12 referenced in function __heap_init
1>LIBCMT.lib(heapinit.obj) : error LNK2019: unresolved external symbol __imp__VirtualFree@12 referenced in function __heap_term
1>LIBCMT.lib(sbheap.obj) : error LNK2001: unresolved external symbol __imp__VirtualFree@12
1>LIBCMT.lib(gs_support.obj) : error LNK2019: unresolved external symbol __imp__QueryPerformanceCounter@4 referenced in function ___security_init_cookie
1>LIBCMT.lib(gs_support.obj) : error LNK2019: unresolved external symbol __imp__GetTickCount@0 referenced in function ___security_init_cookie
1>LIBCMT.lib(gs_support.obj) : error LNK2019: unresolved external symbol __imp__GetCurrentProcessId@0 referenced in function ___security_init_cookie
1>LIBCMT.lib(gs_support.obj) : error LNK2019: unresolved external symbol __imp__GetSystemTimeAsFileTime@4 referenced in function ___security_init_cookie
1>LIBCMT.lib(mlock.obj) : error LNK2019: unresolved external symbol __imp__LeaveCriticalSection@4 referenced in function __unlock
1>LIBCMT.lib(mlock.obj) : error LNK2019: unresolved external symbol __imp__FatalAppExitA@8 referenced in function __lockerr_exit
1>LIBCMT.lib(mlock.obj) : error LNK2019: unresolved external symbol __imp__EnterCriticalSection@4 referenced in function __lock
1>LIBCMT.lib(invarg.obj) : error LNK2019: unresolved external symbol __imp__TerminateProcess@8 referenced in function __invoke_watson
1>LIBCMT.lib(gs_report.obj) : error LNK2001: unresolved external symbol __imp__TerminateProcess@8
1>LIBCMT.lib(invarg.obj) : error LNK2019: unresolved external symbol __imp__GetCurrentProcess@0 referenced in function __invoke_watson
1>LIBCMT.lib(gs_report.obj) : error LNK2001: unresolved external symbol __imp__GetCurrentProcess@0
1>LIBCMT.lib(invarg.obj) : error LNK2019: unresolved external symbol __imp__UnhandledExceptionFilter@4 referenced in function __invoke_watson
1>LIBCMT.lib(abort.obj) : error LNK2001: unresolved external symbol __imp__UnhandledExceptionFilter@4
1>LIBCMT.lib(gs_report.obj) : error LNK2001: unresolved external symbol __imp__UnhandledExceptionFilter@4
1>LIBCMT.lib(invarg.obj) : error LNK2019: unresolved external symbol __imp__IsDebuggerPresent@0 referenced in function __invoke_watson
1>LIBCMT.lib(gs_report.obj) : error LNK2001: unresolved external symbol __imp__IsDebuggerPresent@0
1>LIBCMT.lib(winsig.obj) : error LNK2019: unresolved external symbol __imp__SetConsoleCtrlHandler@8 referenced in function _signal
1>LIBCMT.lib(rand_s.obj) : error LNK2019: unresolved external symbol __imp__FreeLibrary@4 referenced in function _rand_s
1>LIBCMT.lib(rand_s.obj) : error LNK2019: unresolved external symbol __imp__InterlockedExchange@8 referenced in function _rand_s
1>LIBCMT.lib(rand_s.obj) : error LNK2019: unresolved external symbol __imp__LoadLibraryA@4 referenced in function _rand_s
1>LIBCMT.lib(crtmbox.obj) : error LNK2001: unresolved external symbol __imp__LoadLibraryA@4
1>LIBCMT.lib(initcrit.obj) : error LNK2019: unresolved external symbol __imp__InitializeCriticalSection@4 referenced in function ___crtInitCritSecNoSpinCount@8
1>LIBCMT.lib(mbctype.obj) : error LNK2019: unresolved external symbol __imp__GetCPInfo@8 referenced in function "void __cdecl setSBUpLow(struct threadmbcinfostruct *)" (?setSBUpLow@@YAXPAUthreadmbcinfostruct@@@Z)
1>LIBCMT.lib(initctyp.obj) : error LNK2001: unresolved external symbol __imp__GetCPInfo@8
1>LIBCMT.lib(convrtcp.obj) : error LNK2001: unresolved external symbol __imp__GetCPInfo@8
1>LIBCMT.lib(a_cmp.obj) : error LNK2001: unresolved external symbol __imp__GetCPInfo@8
1>LIBCMT.lib(mbctype.obj) : error LNK2019: unresolved external symbol __imp__GetACP@0 referenced in function "int __cdecl getSystemCP(int)" (?getSystemCP@@YAHH@Z)
1>LIBCMT.lib(mbctype.obj) : error LNK2019: unresolved external symbol __imp__GetOEMCP@0 referenced in function "int __cdecl getSystemCP(int)" (?getSystemCP@@YAHH@Z)
1>LIBCMT.lib(mbctype.obj) : error LNK2019: unresolved external symbol __imp__IsValidCodePage@4 referenced in function __setmbcp_nolock
1>LIBCMT.lib(getqloc.obj) : error LNK2001: unresolved external symbol __imp__IsValidCodePage@4
1>LIBCMT.lib(crtheap.obj) : error LNK2019: unresolved external symbol __imp__Sleep@4 referenced in function _wait_a_bit
1>LIBCMT.lib(sbheap.obj) : error LNK2019: unresolved external symbol __imp__VirtualAlloc@16 referenced in function ___sbh_alloc_new_region
1>LIBCMT.lib(sbheap.obj) : error LNK2019: unresolved external symbol __imp__HeapReAlloc@16 referenced in function ___sbh_alloc_new_region
1>LIBCMT.lib(realloc.obj) : error LNK2001: unresolved external symbol __imp__HeapReAlloc@16
1>LIBCMT.lib(exsup4.obj) : error LNK2019: unresolved external symbol _RtlUnwind@16 referenced in function @_EH4_GlobalUnwind@4
1>LIBCMT.lib(exsup.obj) : error LNK2001: unresolved external symbol _RtlUnwind@16
1>LIBCMT.lib(msize.obj) : error LNK2019: unresolved external symbol __imp__HeapSize@12 referenced in function __msize
1>LIBCMT.lib(a_cmp.obj) : error LNK2001: unresolved external symbol __imp__MultiByteToWideChar@24
1>LIBCMT.lib(w_loc.obj) : error LNK2019: unresolved external symbol __imp__MultiByteToWideChar@24 referenced in function "int __cdecl __crtGetLocaleInfoW_stat(struct localeinfo_struct *,unsigned long,unsigned long,wchar_t *,int,int)" (?__crtGetLocaleInfoW_stat@@YAHPAUlocaleinfo_struct@@KKPA_WHH@Z)
1>LIBCMT.lib(a_map.obj) : error LNK2001: unresolved external symbol __imp__MultiByteToWideChar@24
1>LIBCMT.lib(a_str.obj) : error LNK2001: unresolved external symbol __imp__MultiByteToWideChar@24
1>LIBCMT.lib(convrtcp.obj) : error LNK2001: unresolved external symbol __imp__MultiByteToWideChar@24
1>LIBCMT.lib(w_loc.obj) : error LNK2019: unresolved external symbol __imp__GetLocaleInfoA@16 referenced in function "int __cdecl __crtGetLocaleInfoW_stat(struct localeinfo_struct *,unsigned long,unsigned long,wchar_t *,int,int)" (?__crtGetLocaleInfoW_stat@@YAHPAUlocaleinfo_struct@@KKPA_WHH@Z)
1>LIBCMT.lib(a_loc.obj) : error LNK2001: unresolved external symbol __imp__GetLocaleInfoA@16
1>LIBCMT.lib(getqloc.obj) : error LNK2001: unresolved external symbol __imp__GetLocaleInfoA@16
1>LIBCMT.lib(convrtcp.obj) : error LNK2001: unresolved external symbol __imp__GetLocaleInfoA@16
1>LIBCMT.lib(w_loc.obj) : error LNK2019: unresolved external symbol __imp__GetLocaleInfoW@16 referenced in function "int __cdecl __crtGetLocaleInfoW_stat(struct localeinfo_struct *,unsigned long,unsigned long,wchar_t *,int,int)" (?__crtGetLocaleInfoW_stat@@YAHPAUlocaleinfo_struct@@KKPA_WHH@Z)
1>LIBCMT.lib(a_loc.obj) : error LNK2001: unresolved external symbol __imp__GetLocaleInfoW@16
1>LIBCMT.lib(a_map.obj) : error LNK2019: unresolved external symbol __imp__LCMapStringA@24 referenced in function "int __cdecl __crtLCMapStringA_stat(struct localeinfo_struct *,unsigned long,unsigned long,char const *,int,char *,int,int,int)" (?__crtLCMapStringA_stat@@YAHPAUlocaleinfo_struct@@KKPBDHPADHHH@Z)
1>LIBCMT.lib(a_map.obj) : error LNK2019: unresolved external symbol __imp__LCMapStringW@24 referenced in function "int __cdecl __crtLCMapStringA_stat(struct localeinfo_struct *,unsigned long,unsigned long,char const *,int,char *,int,int,int)" (?__crtLCMapStringA_stat@@YAHPAUlocaleinfo_struct@@KKPBDHPADHHH@Z)
1>LIBCMT.lib(a_str.obj) : error LNK2019: unresolved external symbol __imp__GetStringTypeA@20 referenced in function "int __cdecl __crtGetStringTypeA_stat(struct localeinfo_struct *,unsigned long,char const *,int,unsigned short *,int,int,int)" (?__crtGetStringTypeA_stat@@YAHPAUlocaleinfo_struct@@KPBDHPAGHHH@Z)
1>LIBCMT.lib(w_str.obj) : error LNK2001: unresolved external symbol __imp__GetStringTypeA@20
1>LIBCMT.lib(a_str.obj) : error LNK2019: unresolved external symbol __imp__GetStringTypeW@16 referenced in function "int __cdecl __crtGetStringTypeA_stat(struct localeinfo_struct *,unsigned long,char const *,int,unsigned short *,int,int,int)" (?__crtGetStringTypeA_stat@@YAHPAUlocaleinfo_struct@@KPBDHPAGHHH@Z)
1>LIBCMT.lib(w_str.obj) : error LNK2001: unresolved external symbol __imp__GetStringTypeW@16
1>LIBCMT.lib(strftime.obj) : error LNK2019: unresolved external symbol __imp__GetTimeFormatA@24 referenced in function "int __cdecl _store_winword(struct localeinfo_struct *,int,struct tm const *,char * *,unsigned int *,struct __lc_time_data *)" (?_store_winword@@YAHPAUlocaleinfo_struct@@HPBUtm@@PAPADPAIPAU__lc_time_data@@@Z)
1>LIBCMT.lib(strftime.obj) : error LNK2019: unresolved external symbol __imp__GetDateFormatA@24 referenced in function "int __cdecl _store_winword(struct localeinfo_struct *,int,struct tm const *,char * *,unsigned int *,struct __lc_time_data *)" (?_store_winword@@YAHPAUlocaleinfo_struct@@HPBUtm@@PAPADPAIPAU__lc_time_data@@@Z)
1>LIBCMT.lib(getqloc.obj) : error LNK2019: unresolved external symbol __imp__GetUserDefaultLCID@0 referenced in function _GetLcidFromDefault
1>LIBCMT.lib(getqloc.obj) : error LNK2019: unresolved external symbol __imp__EnumSystemLocalesA@8 referenced in function _GetLcidFromCountry
1>LIBCMT.lib(getqloc.obj) : error LNK2019: unresolved external symbol __imp__IsValidLocale@8 referenced in function ___get_qualified_locale
1>LIBCMT.lib(tzset.obj) : error LNK2019: unresolved external symbol __imp__GetTimeZoneInformation@4 referenced in function __tzset_nolock
1>LIBCMT.lib(a_cmp.obj) : error LNK2019: unresolved external symbol __imp__CompareStringA@24 referenced in function "int __cdecl __crtCompareStringA_stat(struct localeinfo_struct *,unsigned long,unsigned long,char const *,int,char const *,int,int)" (?__crtCompareStringA_stat@@YAHPAUlocaleinfo_struct@@KKPBDH1HH@Z)
1>LIBCMT.lib(a_cmp.obj) : error LNK2019: unresolved external symbol __imp__CompareStringW@24 referenced in function "int __cdecl __crtCompareStringA_stat(struct localeinfo_struct *,unsigned long,unsigned long,char const *,int,char const *,int,int)" (?__crtCompareStringA_stat@@YAHPAUlocaleinfo_struct@@KKPBDH1HH@Z)
1>LIBCMT.lib(setenv.obj) : error LNK2019: unresolved external symbol __imp__SetEnvironmentVariableA@8 referenced in function ___crtsetenv
1>C:\Users\Teamsmash\Documents\Visual Studio 2005\Projects\Hello\Debug\Hello.exe : fatal error LNK1120: 76 unresolved externals
1>Build log was saved at "file://c:\Users\Teamsmash\Documents\Visual Studio 2005\Projects\Hello\Hello\Debug\BuildLog.htm"
1>Hello - 148 error(s), 2 warning(s)
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========


Share this post


Link to post
Share on other sites
What XVincentX is getting at is the setup of VC++ Express. What those messages are telling you is, during the linking process, the linker was unable to find routines that are necessary for your app to run.

During the linking process, the linker combines your code with code from various code librarie. Your code needs to be linked with various windows libraries ( judging from the error messages ) and the linker isn't finding those libraries as directed in the Express Edition setup.

The likely cause is that you're not setting up to create a windows project. Express will set certain defaults depending on what type of project you create before you start coding.

You say you added the include and library directories but the linker is definitely not finding the correct libraries.

Suggestion: Start the learning process with some of the Windows SDK examples; they should compile and run; become familiar with setting up a project, compling and linking it by studying successful setups. Learn some of the basics of C++, etc., before diving into DirectX.

Share this post


Link to post
Share on other sites
Thanks for the help, I believe that's probably the problem, since I created a Win32 Console Application. Now I just have to find out how to enable the Windows Application option in VC++ 2005 (it's grayed out).

Thanks again!

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!