# =========================================================================
#     This makefile was generated by
#     Bakefile 0.2.8 (http://www.bakefile.org)
#     Do not modify, all changes will be overwritten!
# =========================================================================



# -------------------------------------------------------------------------
# These are configurable options:
# -------------------------------------------------------------------------

# C++ compiler 
CXX = cl

# Standard flags for C++ 
CXXFLAGS = 

# Standard preprocessor flags (common for CC and CXX) 
CPPFLAGS = 

# Standard linker flags 
LDFLAGS = 

# Set to 1 to build debug version [0,1]
#   0 - Release
#   1 - Debug
DEBUG = 0

# Use DLL build of wx library? [0,1]
#   0 - Static
#   1 - DLL
WX_SHARED = 0

# Use debug build of wxWidgets (define __WXDEBUG__)? [0,1]
#   0 - Release
#   1 - Debug
WX_DEBUG = 1

# Version of the wx library to build against. 
WX_VERSION = 28

# The directory where wxWidgets library is installed 
WX_DIR = $(WXWIN)

# Path to wxrc tool 
WXRC = wxrc

# Path to Berkeley DB tree 
DB_PATH = ./db

# Version of Berkeley DB used 
DB_VERSION = 45

# Path to WinSparkle files 
WINSPARKLE_PATH = .



# -------------------------------------------------------------------------
# Do not modify the rest of this file!
# -------------------------------------------------------------------------

### Variables: ###

POEDIT_CXXFLAGS = /MD$(____DEBUG_13_15) /DWIN32 $(____DEBUG_3_p) \
	$(____DEBUG_4_5) $(____WX_SHARED_6_p) /D_UNICODE $(__WXDEBUG_DEFINE_p) \
	/D__WXMSW__ /I$(WX_DIR)$(WXLIBPATH)\msw$(WXLIBPOSTFIX) /I$(WX_DIR)\include \
	/D_WINDOWS /DUSE_TRANSMEM /DDB_HEADER=\"db.h\" /I$(DB_PATH)\build_windows \
	/I$(WINSPARKLE_PATH) /Zi /Fdpoedit.pdb $(______DEBUG_13_14_p) /GR /EHsc \
	$(CPPFLAGS) $(CXXFLAGS)
POEDIT_OBJECTS =  \
	poedit_catalog.obj \
	poedit_chooselang.obj \
	poedit_commentdlg.obj \
	poedit_digger.obj \
	poedit_edapp.obj \
	poedit_edframe.obj \
	poedit_edlistctrl.obj \
	poedit_export_html.obj \
	poedit_fileviewer.obj \
	poedit_findframe.obj \
	poedit_gexecute.obj \
	poedit_icons.obj \
	poedit_isocodes.obj \
	poedit_manager.obj \
	poedit_parser.obj \
	poedit_prefsdlg.obj \
	poedit_progressinfo.obj \
	poedit_settingsdlg.obj \
	poedit_summarydlg.obj \
	poedit_transmem.obj \
	poedit_transmemupd.obj \
	poedit_transmemupd_wizard.obj \
	poedit_pl_evaluate.obj \
	poedit_editlbox.obj \
	poedit_compiled_xrc.obj
POEDIT_RESOURCES =  \
	poedit_poedit.res
XRC_FILES =  \
	../src/resources/comment.xrc \
	../src/resources/fileview.xrc \
	../src/resources/find.xrc \
	../src/resources/manager.xrc \
	../src/resources/menus.xrc \
	../src/resources/prefs.xrc \
	../src/resources/progress.xrc \
	../src/resources/settings.xrc \
	../src/resources/summary.xrc \
	../src/resources/tm_update.xrc \
	../src/resources/toolbar.xrc

### Conditionally set variables: ###

!if "$(WX_DEBUG)" == "1"
WX3RDPARTYLIBPOSTFIX = d
!endif
!if "$(DEBUG)" == "0"
____DEBUG_3_p = /DNDEBUG
!endif
!if "$(DEBUG)" == "1"
____DEBUG_3_p = 
!endif
!if "$(DEBUG)" == "0"
____DEBUG_3_p_1 = /d NDEBUG
!endif
!if "$(DEBUG)" == "1"
____DEBUG_3_p_1 = 
!endif
!if "$(DEBUG)" == "0"
____DEBUG_4_5 = /O2
!endif
!if "$(DEBUG)" == "1"
____DEBUG_4_5 = /Od
!endif
!if "$(WX_SHARED)" == "0"
____WX_SHARED_6_p = 
!endif
!if "$(WX_SHARED)" == "1"
____WX_SHARED_6_p = /DWXUSINGDLL
!endif
!if "$(WX_SHARED)" == "0"
____WX_SHARED_6_p_1 = 
!endif
!if "$(WX_SHARED)" == "1"
____WX_SHARED_6_p_1 = /d WXUSINGDLL
!endif
!if "$(WX_DEBUG)" == "1"
__WXDEBUG_DEFINE_p = /D__WXDEBUG__
!endif
!if "$(WX_DEBUG)" == "1"
__WXDEBUG_DEFINE_p_1 = /d __WXDEBUG__
!endif
!if "$(DEBUG)" == "0"
____DEBUG_0_FILENAMES = Release
!endif
!if "$(DEBUG)" == "1"
____DEBUG_0_FILENAMES = Debug
!endif
!if "$(DEBUG)" == "0"
______DEBUG_13_14_p = 
!endif
!if "$(DEBUG)" == "1"
______DEBUG_13_14_p = /D_DEBUG
!endif
!if "$(DEBUG)" == "0"
______DEBUG_13_14_p_1 = 
!endif
!if "$(DEBUG)" == "1"
______DEBUG_13_14_p_1 = /d _DEBUG
!endif
!if "$(DEBUG)" == "0"
____DEBUG_13_15 = 
!endif
!if "$(DEBUG)" == "1"
____DEBUG_13_15 = d
!endif
!if "$(DEBUG)" == "0"
____DEBUG_13_16 = /opt:ref /opt:icf
!endif
!if "$(DEBUG)" == "1"
____DEBUG_13_16 = 
!endif
!if "$(WX_DEBUG)" == "0"
__WXLIB_XRC_NAME_p = wxmsw$(WX_VERSION)u_xrc.lib
!endif
!if "$(WX_DEBUG)" == "1"
__WXLIB_XRC_NAME_p = wxmsw$(WX_VERSION)ud_xrc.lib
!endif
!if "$(WX_DEBUG)" == "0"
__WXLIB_ADV_NAME_p = wxmsw$(WX_VERSION)u_adv.lib
!endif
!if "$(WX_DEBUG)" == "1"
__WXLIB_ADV_NAME_p = wxmsw$(WX_VERSION)ud_adv.lib
!endif
!if "$(WX_DEBUG)" == "0"
__WXLIB_HTML_NAME_p = wxmsw$(WX_VERSION)u_html.lib
!endif
!if "$(WX_DEBUG)" == "1"
__WXLIB_HTML_NAME_p = wxmsw$(WX_VERSION)ud_html.lib
!endif
!if "$(WX_DEBUG)" == "0"
__WXLIB_CORE_NAME_p = wxmsw$(WX_VERSION)u_core.lib
!endif
!if "$(WX_DEBUG)" == "1"
__WXLIB_CORE_NAME_p = wxmsw$(WX_VERSION)ud_core.lib
!endif
!if "$(WX_DEBUG)" == "0"
__WXLIB_XML_NAME_p = wxbase$(WX_VERSION)u_xml.lib
!endif
!if "$(WX_DEBUG)" == "1"
__WXLIB_XML_NAME_p = wxbase$(WX_VERSION)ud_xml.lib
!endif
!if "$(WX_DEBUG)" == "0"
__WXLIB_BASE_NAME_p = wxbase$(WX_VERSION)u.lib
!endif
!if "$(WX_DEBUG)" == "1"
__WXLIB_BASE_NAME_p = wxbase$(WX_VERSION)ud.lib
!endif
!if "$(WX_DEBUG)" == "0"
WXLIBPOSTFIX = u
!endif
!if "$(WX_DEBUG)" == "1"
WXLIBPOSTFIX = ud
!endif
!if "$(WX_SHARED)" == "0"
WXLIBPATH = \lib\vc_lib
!endif
!if "$(WX_SHARED)" == "1"
WXLIBPATH = \lib\vc_dll
!endif


### Targets: ###

all: test_for_selected_wxbuild poedit.exe

clean: 
	-if exist .\*.obj del .\*.obj
	-if exist .\*.res del .\*.res
	-if exist .\*.pch del .\*.pch
	-if exist poedit.exe del poedit.exe
	-if exist poedit.ilk del poedit.ilk
	-if exist poedit.pdb del poedit.pdb

test_for_selected_wxbuild: 
	@if not exist $(WX_DIR)$(WXLIBPATH)\msw$(WXLIBPOSTFIX)\wx\setup.h \
	echo ----------------------------------------------------------------------------
	@if not exist $(WX_DIR)$(WXLIBPATH)\msw$(WXLIBPOSTFIX)\wx\setup.h \
	echo The selected wxWidgets build is not available!
	@if not exist $(WX_DIR)$(WXLIBPATH)\msw$(WXLIBPOSTFIX)\wx\setup.h \
	echo Please use the options prefixed with WX_ to select another wxWidgets build.
	@if not exist $(WX_DIR)$(WXLIBPATH)\msw$(WXLIBPOSTFIX)\wx\setup.h \
	echo ----------------------------------------------------------------------------
	@if not exist $(WX_DIR)$(WXLIBPATH)\msw$(WXLIBPOSTFIX)\wx\setup.h \
	exit 1

poedit.exe: $(POEDIT_OBJECTS) poedit_poedit.res
	link /NOLOGO /OUT:$@  /LIBPATH:$(WX_DIR)$(WXLIBPATH) /SUBSYSTEM:WINDOWS /LIBPATH:$(DB_PATH)\build_windows\$(____DEBUG_0_FILENAMES) /LIBPATH:$(WINSPARKLE_PATH) /DEBUG /pdb:"poedit.pdb" $(____DEBUG_13_16) $(LDFLAGS) @<<
	$(POEDIT_OBJECTS) $(POEDIT_RESOURCES)  libdb$(DB_VERSION)s.lib ws2_32.lib WinSparkle.lib $(__WXLIB_XRC_NAME_p) $(__WXLIB_ADV_NAME_p) $(__WXLIB_HTML_NAME_p) $(__WXLIB_CORE_NAME_p) $(__WXLIB_XML_NAME_p) $(__WXLIB_BASE_NAME_p) wxtiff$(WX3RDPARTYLIBPOSTFIX).lib wxjpeg$(WX3RDPARTYLIBPOSTFIX).lib wxpng$(WX3RDPARTYLIBPOSTFIX).lib wxzlib$(WX3RDPARTYLIBPOSTFIX).lib wxregex$(WXLIBPOSTFIX).lib wxexpat$(WX3RDPARTYLIBPOSTFIX).lib kernel32.lib user32.lib gdi32.lib comdlg32.lib winspool.lib winmm.lib shell32.lib comctl32.lib ole32.lib oleaut32.lib uuid.lib rpcrt4.lib advapi32.lib wsock32.lib oleacc.lib
<<
	mt -manifest poedit.exe.manifest -outputresource:poedit.exe;1

poedit_catalog.obj: ..\src\catalog.cpp
	$(CXX) /c /nologo /TP /Fo$@ $(POEDIT_CXXFLAGS) ..\src\catalog.cpp

poedit_chooselang.obj: ..\src\chooselang.cpp
	$(CXX) /c /nologo /TP /Fo$@ $(POEDIT_CXXFLAGS) ..\src\chooselang.cpp

poedit_commentdlg.obj: ..\src\commentdlg.cpp
	$(CXX) /c /nologo /TP /Fo$@ $(POEDIT_CXXFLAGS) ..\src\commentdlg.cpp

poedit_digger.obj: ..\src\digger.cpp
	$(CXX) /c /nologo /TP /Fo$@ $(POEDIT_CXXFLAGS) ..\src\digger.cpp

poedit_edapp.obj: ..\src\edapp.cpp
	$(CXX) /c /nologo /TP /Fo$@ $(POEDIT_CXXFLAGS) ..\src\edapp.cpp

poedit_edframe.obj: ..\src\edframe.cpp
	$(CXX) /c /nologo /TP /Fo$@ $(POEDIT_CXXFLAGS) ..\src\edframe.cpp

poedit_edlistctrl.obj: ..\src\edlistctrl.cpp
	$(CXX) /c /nologo /TP /Fo$@ $(POEDIT_CXXFLAGS) ..\src\edlistctrl.cpp

poedit_export_html.obj: ..\src\export_html.cpp
	$(CXX) /c /nologo /TP /Fo$@ $(POEDIT_CXXFLAGS) ..\src\export_html.cpp

poedit_fileviewer.obj: ..\src\fileviewer.cpp
	$(CXX) /c /nologo /TP /Fo$@ $(POEDIT_CXXFLAGS) ..\src\fileviewer.cpp

poedit_findframe.obj: ..\src\findframe.cpp
	$(CXX) /c /nologo /TP /Fo$@ $(POEDIT_CXXFLAGS) ..\src\findframe.cpp

poedit_gexecute.obj: ..\src\gexecute.cpp
	$(CXX) /c /nologo /TP /Fo$@ $(POEDIT_CXXFLAGS) ..\src\gexecute.cpp

poedit_icons.obj: ..\src\icons.cpp
	$(CXX) /c /nologo /TP /Fo$@ $(POEDIT_CXXFLAGS) ..\src\icons.cpp

poedit_isocodes.obj: ..\src\isocodes.cpp
	$(CXX) /c /nologo /TP /Fo$@ $(POEDIT_CXXFLAGS) ..\src\isocodes.cpp

poedit_manager.obj: ..\src\manager.cpp
	$(CXX) /c /nologo /TP /Fo$@ $(POEDIT_CXXFLAGS) ..\src\manager.cpp

poedit_parser.obj: ..\src\parser.cpp
	$(CXX) /c /nologo /TP /Fo$@ $(POEDIT_CXXFLAGS) ..\src\parser.cpp

poedit_prefsdlg.obj: ..\src\prefsdlg.cpp
	$(CXX) /c /nologo /TP /Fo$@ $(POEDIT_CXXFLAGS) ..\src\prefsdlg.cpp

poedit_progressinfo.obj: ..\src\progressinfo.cpp
	$(CXX) /c /nologo /TP /Fo$@ $(POEDIT_CXXFLAGS) ..\src\progressinfo.cpp

poedit_settingsdlg.obj: ..\src\settingsdlg.cpp
	$(CXX) /c /nologo /TP /Fo$@ $(POEDIT_CXXFLAGS) ..\src\settingsdlg.cpp

poedit_summarydlg.obj: ..\src\summarydlg.cpp
	$(CXX) /c /nologo /TP /Fo$@ $(POEDIT_CXXFLAGS) ..\src\summarydlg.cpp

poedit_transmem.obj: ..\src\transmem.cpp
	$(CXX) /c /nologo /TP /Fo$@ $(POEDIT_CXXFLAGS) ..\src\transmem.cpp

poedit_transmemupd.obj: ..\src\transmemupd.cpp
	$(CXX) /c /nologo /TP /Fo$@ $(POEDIT_CXXFLAGS) ..\src\transmemupd.cpp

poedit_transmemupd_wizard.obj: ..\src\transmemupd_wizard.cpp
	$(CXX) /c /nologo /TP /Fo$@ $(POEDIT_CXXFLAGS) ..\src\transmemupd_wizard.cpp

poedit_pl_evaluate.obj: ..\src\pluralforms\pl_evaluate.cpp
	$(CXX) /c /nologo /TP /Fo$@ $(POEDIT_CXXFLAGS) ..\src\pluralforms\pl_evaluate.cpp

poedit_editlbox.obj: ..\src\editlbox\editlbox.cpp
	$(CXX) /c /nologo /TP /Fo$@ $(POEDIT_CXXFLAGS) ..\src\editlbox\editlbox.cpp

poedit_compiled_xrc.obj: ..\win32\.\compiled_xrc.cpp
	$(CXX) /c /nologo /TP /Fo$@ $(POEDIT_CXXFLAGS) ..\win32\.\compiled_xrc.cpp

poedit_poedit.res: ..\src\poedit.rc
	rc /fo$@  /d WIN32 $(____DEBUG_3_p_1) $(____WX_SHARED_6_p_1) /d _UNICODE $(__WXDEBUG_DEFINE_p_1) /d __WXMSW__ /i $(WX_DIR)$(WXLIBPATH)\msw$(WXLIBPOSTFIX) /i $(WX_DIR)\include /d _WINDOWS /d USE_TRANSMEM /d DB_HEADER="db.h" /i $(DB_PATH)\build_windows /i $(WINSPARKLE_PATH) $(______DEBUG_13_14_p_1) ..\src\poedit.rc


..\win32\.\compiled_xrc.cpp: $(XRC_FILES)
    $(WXRC) -v -c -o $@ $(XRC_FILES)
