Re: [hatari-devel] Hatari 1.6.1 test build for Mac OS X

[ Thread Index | Date Index | More lists.tuxfamily.org/hatari-devel Archives ]


Hi,

On sunnuntai 15 tammikuu 2012, Eero Tamminen wrote:
> On sunnuntai 15 tammikuu 2012, Bob Carpenter wrote:
> > @Stefan: The default cmake file creates Hatari.app in debug mode.

What that means?

Hatari CMakefiles.txt sets the default build type to "Release" when
nothing else is specified:
----------
if(NOT CMAKE_BUILD_TYPE)
        set(CMAKE_BUILD_TYPE Release)
endif(NOT CMAKE_BUILD_TYPE)
----------


> > I
> > changed the release option of every item in the Hatari project to
> > Release and said "None" if I had a debugger choice. I wanted to strip
> > any debugging code out of the compiled Hatari. I also felt that leaving
> > the debug code might make it slower.
> 
> Debug option should only:
> * enable asserts on non-performance critical parts of the code
>   (debugger etc)
> * leave the binary unstripped so that its performance and possible
>   crashes can be debugged
> 
> It shouldn't have any really noticeable effect on performance.

Hm. It appears I wasn't quite up to date on what Hatari CMake files
do for different build types (IMHO CMake is pretty confusing in that
respect).

CMakeCache.txt tells:
------------------------
//Flags used by the compiler during debug builds.
CMAKE_C_FLAGS_DEBUG:STRING=-g

//Flags used by the compiler during release minsize builds.
CMAKE_C_FLAGS_MINSIZEREL:STRING=-Os -DNDEBUG

//Flags used by the compiler during release builds (/MD /Ob1 /Oi
// /Ot /Oy /Gs will produce slightly less optimized but smaller
// files).
CMAKE_C_FLAGS_RELEASE:STRING=-O3 -g

//Flags used by the compiler during Release with Debug Info builds.
CMAKE_C_FLAGS_RELWITHDEBINFO:STRING=-O3 -g
------------------------

And we have in CMakeFiles.txt:
------------------------
# Building Hatari w/o optimization is no fun...
IF (CMAKE_BUILD_TYPE STREQUAL "Debug")
        set(CMAKE_C_FLAGS "-O ${CMAKE_C_FLAGS}")
ENDIF (CMAKE_BUILD_TYPE STREQUAL "Debug")
-------------------------

I.e. plain "Debug" option builds with "-O" instead of "-O3" and
everything else except MINSIZEREL build type adds debug symbols.

I didn't find where & when stripping is done.

Thomas?


	- Eero

> > Also, my compilation only includes the SDL framework. The libpng
> > framework wasn't needed to create screenshots.  I can create a
> > screenshot without that framework being a part of Hatari.app.
> 
> Without libpng the screenshots are in BMP format and the AVI
> recording files are absolutely huge (completely uncompressed).
> 
> > I don't have libportaudio included in my Hatari.app either.
> 
> It's needed only to emulate the Falcon microphone.
> Atari programs being able to utilize that are really rare.
> 
> 
> 	- Eero




Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/