This is an automated email from the git hooks/post-receive script. hmmr-guest pushed a commit to branch master in repository aghermann.
commit a23de32e76e1d53632dafa66d9bcde160dde5deb Author: Andrei Zavada <[email protected]> Date: Sat Sep 21 02:30:21 2013 +0300 move some project-wide filenames to very toplevel project_strings.h --- upstream/src/Makefile.am | 3 +++ upstream/src/aghermann/expdesign/loadsave.cc | 9 ++++---- upstream/src/aghermann/main.cc | 1 + upstream/src/aghermann/ui/globals.cc | 3 +-- upstream/src/aghermann/ui/mw/loadsave.cc | 3 +-- upstream/src/project_strings.h | 31 ++++++++++++++++++++++++++ upstream/src/tools/edfhed-gtk.cc | 1 + 7 files changed, 42 insertions(+), 9 deletions(-) diff --git a/upstream/src/Makefile.am b/upstream/src/Makefile.am index d0438a6..a1c0719 100644 --- a/upstream/src/Makefile.am +++ b/upstream/src/Makefile.am @@ -4,6 +4,9 @@ SUBDIRS := \ aghermann \ tools +EXTRA_DIST := \ + project_strings.h + # by trial and error, the _CFLAGS mentioned are the minimum required to pre-build all headers AM_CXXFLAGS := \ -Wall -std=c++0x -fno-rtti \ diff --git a/upstream/src/aghermann/expdesign/loadsave.cc b/upstream/src/aghermann/expdesign/loadsave.cc index df184d5..7445ed1 100644 --- a/upstream/src/aghermann/expdesign/loadsave.cc +++ b/upstream/src/aghermann/expdesign/loadsave.cc @@ -9,6 +9,7 @@ * License: GPL */ +#include "project_strings.h" #include "aghermann/model/achermann.hh" #include "expdesign.hh" @@ -16,8 +17,6 @@ using namespace std; using namespace agh; -#define EXPD_FILENAME ".expdesign.conf" - int @@ -27,7 +26,7 @@ load_settings() libconfig::Config conf; try { - conf.readFile( EXPD_FILENAME); + conf.readFile( EXPD_FILE); using namespace confval; get( config_keys_d, conf); @@ -44,7 +43,7 @@ load_settings() tstep [t] = A[3]; } } catch (...) { - fprintf( stderr, "CExpDesign::load_settings(): Something is wrong with %s\n", EXPD_FILENAME); + fprintf( stderr, "CExpDesign::load_settings(): Something is wrong with %s\n", EXPD_FILE); _status = _status | load_fail; @@ -122,7 +121,7 @@ save_settings() confval::put( conf, string("Band.") + FreqBandNames[i], forward_list<double> {freq_bands[i][0], freq_bands[i][1]}); - conf.writeFile( EXPD_FILENAME); + conf.writeFile( EXPD_FILE); return 0; } diff --git a/upstream/src/aghermann/main.cc b/upstream/src/aghermann/main.cc index 21b60e8..c2b3813 100644 --- a/upstream/src/aghermann/main.cc +++ b/upstream/src/aghermann/main.cc @@ -18,6 +18,7 @@ #include <gtk/gtk.h> #include <unique/unique.h> +#include "project_strings.h" #include "globals.hh" #include "expdesign/expdesign.hh" #include "ui/globals.hh" diff --git a/upstream/src/aghermann/ui/globals.cc b/upstream/src/aghermann/ui/globals.cc index e847213..99e474b 100644 --- a/upstream/src/aghermann/ui/globals.cc +++ b/upstream/src/aghermann/ui/globals.cc @@ -10,6 +10,7 @@ */ #include <gtk/gtk.h> +#include "project_strings.h" #include "globals.hh" using namespace std; @@ -43,8 +44,6 @@ set_unique_app_window( GtkWindow* w) // own init -#define AGH_UI_GRESOURCE_FILE "aghermann.gresource" - int agh::ui::global:: prepare_for_expdesign() diff --git a/upstream/src/aghermann/ui/mw/loadsave.cc b/upstream/src/aghermann/ui/mw/loadsave.cc index 112982f..f681c02 100644 --- a/upstream/src/aghermann/ui/mw/loadsave.cc +++ b/upstream/src/aghermann/ui/mw/loadsave.cc @@ -11,6 +11,7 @@ #include <forward_list> +#include "project_strings.h" #include "common/config-validate.hh" #include "aghermann/ui/globals.hh" #include "mw.hh" @@ -18,8 +19,6 @@ using namespace std; using namespace agh::ui; -#define CONF_FILE ".aghermann.conf" - namespace { diff --git a/upstream/src/project_strings.h b/upstream/src/project_strings.h new file mode 100644 index 0000000..0ede050 --- /dev/null +++ b/upstream/src/project_strings.h @@ -0,0 +1,31 @@ +/* + * File name: project_strings.h + * Project: Aghermann + * Author: Andrei Zavada <[email protected]> + * Initial version: 2013-09-21 + * + * Purpose: project-wide #define'd things + * + * License: GPL + */ + + +#ifndef AGH_PROJECT_STRINGS_H_ +#define AGH_PROJECT_STRINGS_H_ + +#if HAVE_CONFIG_H && !defined(VERSION) +# include "config.h" +#endif + +#define AGH_UI_GRESOURCE_FILE "aghermann.gresource" +#define EXPD_FILE ".expdesign.conf" +#define CONF_FILE ".aghermann.conf" + +#endif + +// Local Variables: +// Mode: c +// indent-tabs-mode: nil +// tab-width: 8 +// c-basic-offset: 8 +// End: diff --git a/upstream/src/tools/edfhed-gtk.cc b/upstream/src/tools/edfhed-gtk.cc index f9515c5..492a577 100644 --- a/upstream/src/tools/edfhed-gtk.cc +++ b/upstream/src/tools/edfhed-gtk.cc @@ -11,6 +11,7 @@ #include <gtk/gtk.h> +#include "project_strings.h" #include "libsigfile/edf.hh" #include "libsigfile/typed-source.hh" -- Alioth's /git/debian-med/git-commit-notice on /srv/git.debian.org/git/debian-med/aghermann.git _______________________________________________ debian-med-commit mailing list [email protected] http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/debian-med-commit
