 
CFLAGS+=-rdynamic
AM_CXXFLAGS=-rdynamic

bin_PROGRAMS=mysql-workbench-bin
bin_SCRIPTS=mysql-workbench

pkgdata_DATA=res/wb.glade \
  res/model_view.glade\
  res/diagram_view.glade\
  res/find.glade\
  res/diagram_size_form.glade\
  res/input_dialog.glade\
  workbench.rc\
  $(top_srcdir)/frontend/windows/ScintillaNET/Configuration/Builtin/python.xml\
  $(top_srcdir)/frontend/windows/ScintillaNET/Configuration/Builtin/lua.xml\
  $(top_srcdir)/frontend/windows/ScintillaNET/Configuration/Builtin/mysql.xml\
  $(top_srcdir)/frontend/windows/ScintillaNET/Configuration/Builtin/default.xml\
  $(top_srcdir)/frontend/windows/ScintillaNET/Configuration/Builtin/LexerStyleNames/python.txt\
  $(top_srcdir)/frontend/windows/ScintillaNET/Configuration/Builtin/LexerStyleNames/mysql.txt\
  $(top_srcdir)/frontend/windows/ScintillaNET/Configuration/Builtin/LexerStyleNames/lua.txt

#BUILT_SOURCES=precompiled.h.gch

INCLUDES=@GLIB_CFLAGS@ @SIGC_CFLAGS@ @GRT_CFLAGS@ @CAIRO_CFLAGS@ @GNOME_CFLAGS@ @PCRE_CFLAGS@\
	-I$(top_srcdir)/library/grt/src -I$(top_srcdir)/library/base\
	-I$(top_srcdir)/backend -I$(top_srcdir)/generated -I$(top_srcdir)/library/canvas/src\
	-I$(top_srcdir)/backend/wbprivate/workbench\
	-I$(top_srcdir)/frontend/linux/linux_utilities\
	-I$(top_srcdir)/backend/wbpublic\
	-I$(top_srcdir)/backend/wbpublic/grt\
	-I$(top_srcdir)/backend/wbprivate\
	-I$(top_srcdir)/frontend/linux/\
	-I$(top_srcdir)/library/forms\
	-I$(top_srcdir)/library/dbc/src\
	-I$(top_srcdir)/library/forms/gtk\
	-I$(top_srcdir)/generated/grti\
	-I$(top_srcdir)/modules/wb.model/src\
	-I$(top_srcdir)/modules/interfaces\
	-I$(top_srcdir)/ext\
	-I$(top_srcdir)/ext/cppconn\
	-I$(top_srcdir)/modules\
  -I$(top_srcdir)/ext/vsqlite++/include\
  -I$(top_srcdir)/ext/scintilla/include\
	-I$(top_srcdir)/library/forms/mforms
#	-I$(top_srcdir) -include precompiled.h

mysql_workbench_bin_LDADD=\
	$(top_srcdir)/library/forms/libmforms.la\
	$(top_srcdir)/frontend/linux/linux_utilities/liblinux_utilities.la\
	$(top_srcdir)/frontend/linux/sqlide/libsqlide.la\
	$(top_srcdir)/backend/wbprivate/libwbprivate.a\
	$(top_srcdir)/backend/wbpublic/libwbpublic.la\
	$(top_srcdir)/library/base/libwbbase.la\
	$(top_srcdir)/library/grt/src/libgrt.la\
	$(top_srcdir)/library/dbc/libcdbc.la\
	$(top_srcdir)/ext/cppconn/driver/mysqlcppconn.la\
	$(top_srcdir)/ext/scintilla/gtk/libwbscintilla.la\
	$(top_srcdir)/library/canvas/src/libmdcanvasgtk.la\
	$(top_srcdir)/library/canvas/src/libmdcanvas.la\
	@CTEMPLATE_LIBS@\
	@GNOME_LIBS@ @GRT_LIBS@ @PCRE_LIBS@ @GLIB_LIBS@ @CAIRO_LIBS@ @ZIP_LIBS@ @MYSQL_LIBS@ @SQLITE3_LIBS@\
	-lX11

#precompiled.h.gch: precompiled.h
#	$(CXXCOMPILE) precompiled.h -o precompiled.h.gch


mysql-workbench: mysql-workbench.in
	sed -e "s@#libdir#@$(libdir)@" -e "s@#utilities_cmds#@@MYSQL_UTILITIES_PROGRAMS@@" $< > $@
	chmod +x $@


mysql_workbench_bin_SOURCES=\
main.cpp\
program.cpp\
main_form.cpp\
overview_panel.cpp\
model_panel.cpp\
model_diagram_panel.cpp\
mforms_grttreeview.cpp\
catalog_tree.cpp\
layer_tree.cpp\
properties_tree.cpp\
history_tree.cpp\
navigator_box.cpp\
info_box.cpp\
documentation_box.cpp\
user_types_box.cpp\
find_panel.cpp\
diagram_size_form.cpp\
validation_panel.cpp\
sqlide_form.cpp\
sqlide_main.cpp\
../../common/new_server_instance_wizard.cpp\
../../common/grt_code_editor.cpp\
../../common/server_instance_editor.cpp\
../../common/grt_python_debugger.cpp\
../../common/advanced_sidebar.cpp\
../../common/snippet_popover.cpp


