[Scummvm-cvs-logs] SF.net SVN: scummvm: [27910] scummex/branches/gsoc2007-gameresbrowser

zbychs at users.sourceforge.net zbychs at users.sourceforge.net
Thu Jul 5 01:04:49 CEST 2007


Revision: 27910
          http://scummvm.svn.sourceforge.net/scummvm/?rev=27910&view=rev
Author:   zbychs
Date:     2007-07-04 16:04:49 -0700 (Wed, 04 Jul 2007)

Log Message:
-----------
Improved Makefile

Modified Paths:
--------------
    scummex/branches/gsoc2007-gameresbrowser/gcc/Makefile
    scummex/branches/gsoc2007-gameresbrowser/src/core/pinslot.cpp
    scummex/branches/gsoc2007-gameresbrowser/src/gui/MainForm.cpp
    scummex/branches/gsoc2007-gameresbrowser/src/gui/MainForm.h

Modified: scummex/branches/gsoc2007-gameresbrowser/gcc/Makefile
===================================================================
--- scummex/branches/gsoc2007-gameresbrowser/gcc/Makefile	2007-07-04 23:04:40 UTC (rev 27909)
+++ scummex/branches/gsoc2007-gameresbrowser/gcc/Makefile	2007-07-04 23:04:49 UTC (rev 27910)
@@ -6,7 +6,7 @@
 #
 ###########################################################################################
 
-.PHONY : dep all clean copy_data core plugins gui clean_data clean_core clean_plugins clean_gui core_dir plugins_dir gui_dir
+.PHONY : tell dep all clean copy_data core plugins gui clean_data clean_core clean_plugins clean_gui core_dir plugins_dir gui_dir
 
 ###########################################################################################
 
@@ -53,13 +53,25 @@
 
 ###########################################################################################
 
+ifeq ($(MAKE_DEBUG), yes)
+    WX_DEBUG = yes
+else
+    WX_DEBUG = no
+endif
 WX_VERSION = 2.8
-WX_FLAGS = $(shell wx-config --version=$(WX_VERSION) --debug=no --cxxflags)
-WX_LIBS = $(shell wx-config --version=$(WX_VERSION) --debug=no --libs)
+WX_FLAGS = $(shell wx-config --version=$(WX_VERSION) --debug=$(WX_DEBUG) --cxxflags)
+WX_LIBS = $(shell wx-config --version=$(WX_VERSION) --debug=$(WX_DEBUG) --libs)
 
 ###########################################################################################
 
-GLOBAL_DEFINES = NDEBUG UNIX
+ifeq ($(MAKE_DEBUG), yes)
+    TELL = DEBUG BUILD
+    GLOBAL_DEFINES = _DEBUG UNIX
+else
+    TELL = RELEASE BUILD
+    GLOBAL_DEFINES = NDEBUG UNIX
+#    GLOBAL_DEFINES = UNIX
+endif
 
 BASE_FLAGS = -g $(patsubst %, -I%, $(HEADERS_DIRS) ) $(patsubst %, -D%, $(GLOBAL_DEFINES) )
 CFLAGS = $(BASE_FLAGS) $(WX_FLAGS)
@@ -69,8 +81,11 @@
 
 ###########################################################################################
 
-all: gui copy_data
+all: tell gui copy_data
 
+tell:
+	echo '$(TELL)'
+
 ###########################################################################################
 
 dep:

Modified: scummex/branches/gsoc2007-gameresbrowser/src/core/pinslot.cpp
===================================================================
--- scummex/branches/gsoc2007-gameresbrowser/src/core/pinslot.cpp	2007-07-04 23:04:40 UTC (rev 27909)
+++ scummex/branches/gsoc2007-gameresbrowser/src/core/pinslot.cpp	2007-07-04 23:04:49 UTC (rev 27910)
@@ -152,8 +152,6 @@
 	_instance = NULL;
 }
 
-	std::set<BObject*> _initializedObjects;
-
 void InitializedObjects::registerObject(BObject* obj) {
 	std::set<BObject*>::const_iterator i;
 	i = _initializedObjects.find(obj);

Modified: scummex/branches/gsoc2007-gameresbrowser/src/gui/MainForm.cpp
===================================================================
--- scummex/branches/gsoc2007-gameresbrowser/src/gui/MainForm.cpp	2007-07-04 23:04:40 UTC (rev 27909)
+++ scummex/branches/gsoc2007-gameresbrowser/src/gui/MainForm.cpp	2007-07-04 23:04:49 UTC (rev 27910)
@@ -67,7 +67,7 @@
 	leak[0] = 'L'; leak[1] = 'E'; leak[2] = 'A'; leak[3] = 'K'; leak[4] = '\0';
 }
 
-MainForm::~MainForm() {
+void MainForm::ZCleanup() {
 	InitializedObjects::get()->report();
 
 	ExplorationTree::release();
@@ -84,6 +84,9 @@
 	set_statics_not_allowed();
 }
 
+MainForm::~MainForm() {
+}
+
 void MainForm::CreateGUIControls() {
 	//Do not add custom code between
 	//GUI Items Creation Start and GUI Items Creation End
@@ -141,6 +144,7 @@
 }
 
 void MainForm::OnClose(wxCloseEvent& event) {
+	ZCleanup();
 	Destroy();
 }
 

Modified: scummex/branches/gsoc2007-gameresbrowser/src/gui/MainForm.h
===================================================================
--- scummex/branches/gsoc2007-gameresbrowser/src/gui/MainForm.h	2007-07-04 23:04:40 UTC (rev 27909)
+++ scummex/branches/gsoc2007-gameresbrowser/src/gui/MainForm.h	2007-07-04 23:04:49 UTC (rev 27910)
@@ -46,6 +46,8 @@
 	public:
 		MainForm(wxWindow *parent, wxWindowID id = 1, const wxString &title = wxT("Game Resource Browser"), const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxDefaultSize, long style = MainForm_STYLE);
 		virtual ~MainForm();
+		//virtual bool Destroy();
+		void ZCleanup();
 		void ExitClick(wxCommandEvent& event);
 		void OnTest1Cleanup(wxCommandEvent& event);
 		void OnTest1(wxCommandEvent& event);


This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.




More information about the Scummvm-git-logs mailing list