Building under Visual Studio 2015

Benjamin Kaduk kaduk at MIT.EDU
Fri May 6 20:16:31 EDT 2016


Hi Chris,

First, thank you for writing this and letting us know what obstacles you
ran into; it's always nice to get feedback like this.

Unfortunately, the KfW 4.0.x series is pretty dead at this point; I would
not expect there to be another relase in it.  (Recall that it is based off
of the krb5 1.10.x series, which has been end-of-life for a couple years
now.)

In the 4.1.x series (currently in beta 2), I believe we fied the
VISUALSTUDIOVERSION conditionals, though I am not sure whether the other
two issues have already been fixed.

If you don't mind, I'd be curious to hear how you start up your cmd.exe
build environment (or if you use some other setup); in particular, whether
src/windows/README is still useful or should be updated.

Thanks,

Ben


On Fri, 6 May 2016, Chris Kingsley wrote:

> I have gotten my copy of kfw 4.0.1 to now build under Visual Studio 2015. (I haven't gotten around to testing it yet - I'm still getting the rest of the system to compile.) Though untested, I thought you might find it useful to hear what other fixes I found, beyond the ones I saw in this mailing list.
>
>
> 1.       In src/lib/Makefile.in - it was not handling debug builds properly. It should look like this:
>
> ##WIN32##!if defined(VISUALSTUDIOVERSION) && $(VISUALSTUDIOVERSION:.=) >= 140
> ##WIN32##!ifdef NODEBUG
> ##WIN32##WINCRTEXTRA = ucrt.lib vcruntime.lib
> ##WIN32##!else
> ##WIN32##WINCRTEXTRA = ucrtd.lib vcruntimed.lib
> ##WIN32##!endif
> ##WIN32##!endif
> ##WIN32##WINLIBS = kernel32.lib ws2_32.lib user32.lib shell32.lib oldnames.lib \
> ##WIN32##        version.lib secur32.lib advapi32.lib gdi32.lib delayimp.lib \
> ##WIN32##        $(WINCRTEXTRA)
> ##WIN32##WINDLLFLAGS = $(DLL_LINKOPTS) -base:0x1c000000 /DELAYLOAD:secur32.dll \
> ##WIN32##        /DELAYLOAD:advapi32.dll /DELAY:UNLOAD /DELAY:NOBIND
>
>
>
> 2.       Similarly in src/windows/kfwlogon/Makefile.in:
>
> !if defined(VISUALSTUDIOVERSION) && $(VISUALSTUDIOVERSION:.=) >= 140
> !ifdef NODEBUG
> WINCRTEXTRA = ucrt.lib vcruntime.lib
> !else
> WINCRTEXTRA = ucrtd.lib vcruntimed.lib
> !endif
> !endif
> SYSLIBS = kernel32.lib user32.lib advapi32.lib wsock32.lib secur32.lib userenv.lib $(WINCRTEXTRA)
>
>
>
> 3.       In src/windows/leash/Leash.cpp I commented out the -console option:
>            }
> //            else if (0 == stricmp(optionParam+1, "console") ||
> //                     0 == stricmp(optionParam+1, "c"))
> //            {
> //                CreateConsoleEcho();
> //            }
>             else if (0 == stricmp(optionParam+1, "noribbon"))
>
>
> 4.       That prevents all usage of the ConsoleEcho object, in src/windows/leash/out2con.cpp. It wasn't compiling. I didn't remove it from the makefile, but I just commented out the suspicious line that was preventing it from compiling (Sorry, completely slovenly work):
>
>     // now slam the allocated FILE's _flag to zero to mark it as free without
>     // actually closing the os file handle and pipe
> //    fp->_flag = 0; doesn't build under VS2015. I disabled the console option which is the only place that constructs these.
>
>
>
> _______________________________________________
> kfwdev mailing list
> kfwdev at mit.edu
> http://mailman.mit.edu/mailman/listinfo/kfwdev
>


More information about the kfwdev mailing list