Cuberite Forum
Transition to cmake on Windows - Printable Version

+- Cuberite Forum (https://forum.cuberite.org)
+-- Forum: Cuberite (https://forum.cuberite.org/forum-4.html)
+--- Forum: Development (https://forum.cuberite.org/forum-13.html)
+--- Thread: Transition to cmake on Windows (/thread-1312.html)

Pages: 1 2 3 4 5


RE: Transition to cmake on Windows - tigerw - 01-17-2014

Good point - I should read my quotes properly Blush. Okay, drop /Ox for now, what about the others:

Code:
Enable Intrinsic Functions: No
Favour size or speed: Neither
Enable fiber safe optimizations: No
Whole program optimization: No

Also, MCS executable is now in the right folder, but not the lua.dll.


RE: Transition to cmake on Windows - xoft - 01-17-2014

The other options are the MSVC's GUI misguiding you again. /O2 already enables those options, so there's no point in setting them again.

I have fixed the Lua dll, CMake uses a different set of properties for DLLs. Sighhh.


RE: Transition to cmake on Windows - tigerw - 01-18-2014

In that case, delete away Smile

I'll speak of any other issues.


RE: Transition to cmake on Windows - xoft - 01-18-2014

LuaRocks is not working on Windows anymore. It requires the lua DLL to be named exactly lua5.1.dll, otherwise two different Lua DLLs (MCServer's one and LuaRocks' one) are loaded and they fight each other.
This should be easy to fix, just dropping a note here so that I don't forget Smile


RE: Transition to cmake on Windows - ThuGie - 01-19-2014

As the vc2013 does not work cause of the missing binding.bat missing, i tried the cmake works perfectly for vc2012 Smile.


RE: Transition to cmake on Windows - xoft - 01-19-2014

VC2013 worked for me when I tried at work. What exactly is failing for you?


RE: Transition to cmake on Windows - ThuGie - 01-19-2014

I need to generate the bindings so i run the GenerateBindings.cmd
That executes
set ALLTOLUA_WAIT=N
cd ..\src\Bindings
AllToLua.bat
But there is no BindingsAllToLua.bat :p. but as i said i was able to perfectly use cmake so i got no real problem.


RE: Transition to cmake on Windows - xoft - 01-19-2014

GenerateBindings.cmd? Where did you get that from, there isn't such a file in the repo anymore.

You don't need to generate the bindings, CMake will do that for you (the first time, at least); you can then update the bindings by executing the $/src/Bindings/AllToLua.bat script manually. I personally have added a command to VS's External tools menu (Tools -> External Tools...), like this:
Code:
Title: &Update bindings
Command: <full-path-to-mc-server>\src\Bindings\tolua++.exe
Arguments: -L virtual_method_hooks.lua -o Bindings.cpp -H Bindings.h AllToLua.pkg
Initial directory: $(SolutionDir)\src\Bindings\
This allows me to update bindings for any MCServer solution I have open (I keep a few repositories checked out in parallel) simply by pressing Alt+T, then U


RE: Transition to cmake on Windows - tigerw - 01-20-2014

GenerateBindings.bat is in the VC2008/13 folders. Also, delete said folders?


RE: Transition to cmake on Windows - xoft - 01-20-2014

Done.