lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


Would the lua profiler break if i have other unrelated profiler.h and .cpp files?
I wouldn't say that that would be the probable problem since I am not able to use require at all (not with my own files either) except when outside VS using the command line (allthough the script in this case is not run via c/c++)

I don't know if this is anything of what you would like to see as far as system specs go...

command line:
/OUT:"..\game\game_d.exe" /NOLOGO "kernel32.lib" "user32.lib" "gdi32.lib" "winspool.lib" "comdlg32.lib" "advapi32.lib" "shell32.lib" "ole32.lib" "oleaut32.lib" "uuid.lib" "odbc32.lib" "odbccp32.lib" "C:\Projects\engine\enginelib\AnsiDebug\enginelib.lib" "C:\Projects\engine\import\zlib\projects\visualc6\Win32_LIB_Debug\zlibd.lib" /MANIFEST /ManifestFile:".\../Intermediary_2005/Ansi Debug\game_d.exe.intermediate.manifest" /ALLOWISOLATION /MANIFESTUAC:"level='asInvoker' uiAccess='false'" /PDB:"C:\Projects\luaexjobb\game\game_d.pdb" /PGD:"C:\Projects\luaexjobb\game\game_d.pgd" /TLBID:1 /DYNAMICBASE /NXCOMPAT /MACHINE:X86 /ERRORREPORT:QUEUE

the complete (lua) stacktrace on the fail is:
1: string ( attempt to call a nil value )

I am building Ansi Debug for Win32

Executable Directories C:\Program Files %28x86%29\Lua\5.1\clibs
Include directories C:\Program Files %28x86%29\Lua\5.1\include
C:\Program Files (x86)\Microsoft DirectX SDK (March 2009)\Include
Library directories C:\Program Files %28x86%29\Lua\5.1\clibs
C:\Program Files %28x86%29\Lua\5.1\lib
C:\Program Files\Microsoft SDKs\Windows\v6.1\Lib
C:\Program Files %28x86%29\Microsoft DirectX SDK %28March 2009%29\Lib\x86

LUA_CPATH C:\Program Files (x86)\Lua\5.1\clibs
LUA_DEV C:\Program Files (x86)\Lua\5.1
LUA_PATH ;;C:\Program Files (x86)\Lua\5.1\lua\?.luac
Path C:\Program Files (x86)\NVIDIA Corporation\PhysX\Common;%SystemRoot%\system32;%SystemRoot%;%SystemRoot%\System32\Wbem;%SYSTEMROOT%\System32\WindowsPowerShell\v1.0\;C:\Program Files\TortoiseSVN\bin;c:\Program Files (x86)\Microsoft SQL Server\100\Tools\Binn\;c:\Program Files\Microsoft SQL Server\100\Tools\Binn\;c:\Program Files\Microsoft SQL Server\100\DTS\Binn\;C:\Python27;C:\Program Files (x86)\Lua\5.1;C:\Program Files (x86)\Lua\5.1\clibs

OS Name Microsoft Windows 7 Professional
Version 6.1.7601 Service Pack 1 Build 7601
System Manufacturer Gigabyte Technology Co., Ltd.
System Model P67A-UD3-B3
System Type x64-based PC
Processor Intel(R) Core(TM) i5-2500 CPU @ 3.30GHz, 3601 Mhz, 4 Core(s), 4 Logical Processor(s)
BIOS Version/Date Award Software International, Inc. F3, 2011-03-31
SMBIOS Version 2.4
Windows Directory C:\Windows
System Directory C:\Windows\system32

Microsoft Visual Studio 2010
Version 10.0.40219.1 SP1Rel
Microsoft .NET Framework
Version 4.0.30319 SP1Rel

Installed Version: Professional

Microsoft Office Developer Tools   01018-532-2002181-70641
Microsoft Visual Basic 2010   01018-532-2002181-70641
Microsoft Visual C# 2010   01018-532-2002181-70641
Microsoft Visual C++ 2010   01018-532-2002181-70641
Microsoft Visual F# 2010   01018-532-2002181-70641
Microsoft Visual Studio 2010 Team Explorer   01018-532-2002181-70641
Microsoft Visual Web Developer 2010   01018-532-2002181-70641
Crystal Reports Templates for Microsoft Visual Studio 2010
Microsoft Visual Studio 2010 Professional - ENU Service Pack 1 (KB983509)   KB983509
Microsoft Visual Studio 2010 SharePoint Developer Tools   10.0.40219

On Wed, Sep 7, 2011 at 3:12 PM, Peng Zhicheng <pengzhicheng1986@gmail.com> wrote:
于 2011-9-7 19:40, Oskar Forsslund 写道:

Hi!
Im quite new to both lua and VS and this is really getting on my nerves.
I'm trying to require the profiler package included in the "lua for windows"-install but my application keeps crashing. I have tried running just the script from the console and it runs properly but as soon as I try to run it under VS lua panics with the error message "attempted to call a nil value".

Glad for any ideas

regards
Oskar

more information is needed to find out where the bug lies. you should give as much information as possible such as
the build environment, build toolchain version, build command line flags, external libraries linked,
the stack trace message when lua panic, and so on.


yet I could only make a guess from the limited description you posted.
since the error message is "attempted to call a nil value", maybe there is some name conflicts between the profiler
and your host application, so some lua value is broken which should have be a function.
or, maybe this is another problem due to the different crt versions from the one your host program is linked with and
the one the pre-built package is linked with.