ssbssa / heob

Detects buffer overruns and memory leaks.
Boost Software License 1.0
155 stars 25 forks source link

Issues building from command line #9

Closed mitchcurtis closed 6 years ago

mitchcurtis commented 6 years ago

I'm a scrub when it comes to building stuff like this, usually just relying on qmake to handle everything for me. My naive attempt to do a shadow build with jom failed:

C:\dev>mkdir heob-build

C:\dev>cd heob-build

C:\dev\heob-build>jom CPPFLAGS="-DNO_DWARFSTACK" ..\heob\Makefile
Error: File Makefile doesn't exist.

nmake too:

C:\dev\heob-build>nmake CPPFLAGS="-DNO_DWARFSTACK" ..\heob\Makefile

Microsoft (R) Program Maintenance Utility Version 14.11.25507.1
Copyright (C) Microsoft Corporation.  All rights reserved.

..\heob\Makefile(2) : fatal error U1033: syntax error : '=' unexpected
Stop.

So I gave in and did an in-source build:

C:\dev>cd heob

C:\dev\heob>jom CPPFLAGS="-DNO_DWARFSTACK"
Error: syntax error in C:\dev\heob\Makefile line 8

It would be good to have some complete build instructions in the README. :)

mitchcurtis commented 6 years ago

Setting the environment variables should work, according to this.

C:\dev\heob-build>set CPPFLAGS="-DNO_DWARFSTACK"

C:\dev\heob-build>echo %CPPFLAGS%
"-DNO_DWARFSTACK"

But when I run it:

C:\dev\heob-build>nmake ..\heob\Makefile

Microsoft (R) Program Maintenance Utility Version 14.11.25507.1
Copyright (C) Microsoft Corporation.  All rights reserved.

..\heob\Makefile(2) : fatal error U1033: syntax error : '=' unexpected
Stop.
mitchcurtis commented 6 years ago

I'm starting to come to the conclusion that this is not meant for building with MSVC, but MinGW. :) This is also something that would be good to have in the README.

ssbssa commented 6 years ago

Yes, the Makefile is for MinGW only, for MSVC there is the build.bat.

ssbssa commented 6 years ago

Does that mean this issue can be closed, or do you need some more info?

mitchcurtis commented 6 years ago

Yep, go ahead. :)