From 235fdfdbe0d2585a7f8a39226c912b8053112aaf Mon Sep 17 00:00:00 2001 From: tchernobog Date: Tue, 7 Feb 2006 20:41:59 +0000 Subject: [PATCH] - Prefix our macros with "SG_", as per Luca request git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@301 3ecf2c5c-341e-0410-92b4-d18e462d057c --- configure.ac | 24 ++++++++++++------------ doc/sgpem2dman.texi | 2 +- src/backend/process.hh | 2 +- src/backend/schedulable.hh | 2 +- src/backend/schedulableStatus.hh | 2 +- src/backend/simulationStatus.hh | 2 +- src/backend/slice.hh | 2 +- src/startgui.hh | 2 +- 8 files changed, 19 insertions(+), 19 deletions(-) diff --git a/configure.ac b/configure.ac index 70eaa14..be7c09c 100644 --- a/configure.ac +++ b/configure.ac @@ -95,10 +95,10 @@ PKG_CHECK_MODULES([GTKMM], dnl use DSO visibility tags for systems that supports it correctly dnl (for example, GCC 4.0 and above) dnl see http://gcc.gnu.org/wiki/Visibility for more informations -AH_TEMPLATE([DLLEXPORT],[Attribute for objects to be exported from DSOs]) -AH_TEMPLATE([DLLIMPORT],[Attribute for objects to be imported from DSOs]) -AH_TEMPLATE([DLLLOCAL], [Attribute for objects local to current DSO]) -AH_TEMPLATE([DLLPUBLIC],[Attribute for DSO public objects]) +AH_TEMPLATE([SG_DLLEXPORT],[Attribute for objects to be exported from DSOs]) +AH_TEMPLATE([SG_DLLIMPORT],[Attribute for objects to be imported from DSOs]) +AH_TEMPLATE([SG_DLLLOCAL], [Attribute for objects local to current DSO]) +AH_TEMPLATE([SG_DLLPUBLIC],[Attribute for DSO public objects]) dnl for now it works only with GCC >= 4.0.0 AC_MSG_CHECKING([whether GCC supports DSO visibility attributes]) @@ -112,19 +112,19 @@ AC_COMPILE_IFELSE( #endif ]),[ AC_MSG_RESULT([yes]) - AC_DEFINE([DLLIMPORT],[/* intentionally left with no value */]) - AC_DEFINE([DLLEXPORT],[__attribute__ ((visibility("default")))]) - AC_DEFINE([DLLLOCAL],[__attribute__ ((visibility("hidden")))]) - AC_DEFINE([DLLPUBLIC],[__attribute__ ((visibility("default")))]) + AC_DEFINE([SG_DLLIMPORT],[/* intentionally left with no value */]) + AC_DEFINE([SG_DLLEXPORT],[__attribute__ ((visibility("default")))]) + AC_DEFINE([SG_DLLLOCAL],[__attribute__ ((visibility("hidden")))]) + AC_DEFINE([SG_DLLPUBLIC],[__attribute__ ((visibility("default")))]) AC_CHECK_CXXFLAG([fvisibility=hidden]) AC_CHECK_CXXFLAG([fvisibility-inlines-hidden]) ],[ AC_MSG_RESULT([no]) - AC_DEFINE([DLLIMPORT],[/* unsupported */]) - AC_DEFINE([DLLEXPORT],[/* unsupported */]) - AC_DEFINE([DLLLOCAL],[/* unsupported */]) - AC_DEFINE([DLLPUBLIC],[/* unsupported */]) + AC_DEFINE([SG_DLLIMPORT],[/* unsupported */]) + AC_DEFINE([SG_DLLEXPORT],[/* unsupported */]) + AC_DEFINE([SG_DLLLOCAL],[/* unsupported */]) + AC_DEFINE([SG_DLLPUBLIC],[/* unsupported */]) ]) AC_LANG_POP diff --git a/doc/sgpem2dman.texi b/doc/sgpem2dman.texi index 78c3ae9..073fde0 100644 --- a/doc/sgpem2dman.texi +++ b/doc/sgpem2dman.texi @@ -946,7 +946,7 @@ the language you're employing. Only exportable classes and functions inside a library should be marked with correct visibility attribute (usually a macro we defined -as @code{DLL_EXPORT}). All the others are marked with +as @code{SGP_DLLEXPORT}). All the others are marked with @option{--visibility=hidden} from the compiler, and aren't available outside the @acronym{DSO, Dynamic Shared Object} they live in, so that they don't clutter diff --git a/src/backend/process.hh b/src/backend/process.hh index d98b01a..2bb2515 100644 --- a/src/backend/process.hh +++ b/src/backend/process.hh @@ -35,7 +35,7 @@ namespace sgpem It IS a Schedulable object. */ - class DLLEXPORT Process : public Schedulable + class SG_DLLEXPORT Process : public Schedulable { public: Process(const Glib::ustring& name, const unsigned int& arrival, const unsigned int& total, const int& priority); diff --git a/src/backend/schedulable.hh b/src/backend/schedulable.hh index e6c2f00..059fe3a 100644 --- a/src/backend/schedulable.hh +++ b/src/backend/schedulable.hh @@ -36,7 +36,7 @@ namespace sgpem * All subclasses are ... (FIXME: teach Luca and Marco what's * the Italian language for, damn them! -- they must have * *smoked* mushrooms! :-) ) */ - class DLLEXPORT Schedulable + class SG_DLLEXPORT Schedulable { public: Schedulable(const Glib::ustring& name, const unsigned int& arrival, const unsigned int& total, const int& priority); diff --git a/src/backend/schedulableStatus.hh b/src/backend/schedulableStatus.hh index e000d60..082b936 100644 --- a/src/backend/schedulableStatus.hh +++ b/src/backend/schedulableStatus.hh @@ -36,7 +36,7 @@ namespace sgpem Objects SchedulableStatus are created by Scheduler and destroyed by SimulationStatus if they are linked to it or by Scheduler. */ -class DLLEXPORT SchedulableStatus +class SG_DLLEXPORT SchedulableStatus { public: enum state diff --git a/src/backend/simulationStatus.hh b/src/backend/simulationStatus.hh index 20690da..52d3ac8 100644 --- a/src/backend/simulationStatus.hh +++ b/src/backend/simulationStatus.hh @@ -37,7 +37,7 @@ namespace sgpem running and other infos (since M02+) */ - class DLLEXPORT SimulationStatus + class SG_DLLEXPORT SimulationStatus { public: SimulationStatus(); diff --git a/src/backend/slice.hh b/src/backend/slice.hh index 2868e1a..2eefa4c 100644 --- a/src/backend/slice.hh +++ b/src/backend/slice.hh @@ -36,7 +36,7 @@ namespace sgpem */ - class DLLEXPORT Slice + class SG_DLLEXPORT Slice { public: Slice(const int& start, const int& duration, const SimulationStatus& status); diff --git a/src/startgui.hh b/src/startgui.hh index f76a553..8c00b6e 100644 --- a/src/startgui.hh +++ b/src/startgui.hh @@ -24,6 +24,6 @@ #include "config.h" /** \brief This function starts the whole GUI */ -void DLLEXPORT start_gui(int argc, char** argv); +void SG_DLLEXPORT start_gui(int argc, char** argv); #endif