- 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
This commit is contained in:
tchernobog 2006-02-07 20:41:59 +00:00
parent 7de2c281bb
commit 235fdfdbe0
8 changed files with 19 additions and 19 deletions

View File

@ -95,10 +95,10 @@ PKG_CHECK_MODULES([GTKMM],
dnl use DSO visibility tags for systems that supports it correctly dnl use DSO visibility tags for systems that supports it correctly
dnl (for example, GCC 4.0 and above) dnl (for example, GCC 4.0 and above)
dnl see http://gcc.gnu.org/wiki/Visibility for more informations dnl see http://gcc.gnu.org/wiki/Visibility for more informations
AH_TEMPLATE([DLLEXPORT],[Attribute for objects to be exported from DSOs]) AH_TEMPLATE([SG_DLLEXPORT],[Attribute for objects to be exported from DSOs])
AH_TEMPLATE([DLLIMPORT],[Attribute for objects to be imported from DSOs]) AH_TEMPLATE([SG_DLLIMPORT],[Attribute for objects to be imported from DSOs])
AH_TEMPLATE([DLLLOCAL], [Attribute for objects local to current DSO]) AH_TEMPLATE([SG_DLLLOCAL], [Attribute for objects local to current DSO])
AH_TEMPLATE([DLLPUBLIC],[Attribute for DSO public objects]) AH_TEMPLATE([SG_DLLPUBLIC],[Attribute for DSO public objects])
dnl for now it works only with GCC >= 4.0.0 dnl for now it works only with GCC >= 4.0.0
AC_MSG_CHECKING([whether GCC supports DSO visibility attributes]) AC_MSG_CHECKING([whether GCC supports DSO visibility attributes])
@ -112,19 +112,19 @@ AC_COMPILE_IFELSE(
#endif #endif
]),[ ]),[
AC_MSG_RESULT([yes]) AC_MSG_RESULT([yes])
AC_DEFINE([DLLIMPORT],[/* intentionally left with no value */]) AC_DEFINE([SG_DLLIMPORT],[/* intentionally left with no value */])
AC_DEFINE([DLLEXPORT],[__attribute__ ((visibility("default")))]) AC_DEFINE([SG_DLLEXPORT],[__attribute__ ((visibility("default")))])
AC_DEFINE([DLLLOCAL],[__attribute__ ((visibility("hidden")))]) AC_DEFINE([SG_DLLLOCAL],[__attribute__ ((visibility("hidden")))])
AC_DEFINE([DLLPUBLIC],[__attribute__ ((visibility("default")))]) AC_DEFINE([SG_DLLPUBLIC],[__attribute__ ((visibility("default")))])
AC_CHECK_CXXFLAG([fvisibility=hidden]) AC_CHECK_CXXFLAG([fvisibility=hidden])
AC_CHECK_CXXFLAG([fvisibility-inlines-hidden]) AC_CHECK_CXXFLAG([fvisibility-inlines-hidden])
],[ ],[
AC_MSG_RESULT([no]) AC_MSG_RESULT([no])
AC_DEFINE([DLLIMPORT],[/* unsupported */]) AC_DEFINE([SG_DLLIMPORT],[/* unsupported */])
AC_DEFINE([DLLEXPORT],[/* unsupported */]) AC_DEFINE([SG_DLLEXPORT],[/* unsupported */])
AC_DEFINE([DLLLOCAL],[/* unsupported */]) AC_DEFINE([SG_DLLLOCAL],[/* unsupported */])
AC_DEFINE([DLLPUBLIC],[/* unsupported */]) AC_DEFINE([SG_DLLPUBLIC],[/* unsupported */])
]) ])
AC_LANG_POP AC_LANG_POP

View File

@ -946,7 +946,7 @@ the language you're employing.
Only exportable classes and functions inside Only exportable classes and functions inside
a library should be marked with correct a library should be marked with correct
visibility attribute (usually a macro we defined 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 @option{--visibility=hidden} from the compiler, and aren't
available outside the @acronym{DSO, Dynamic Shared Object} available outside the @acronym{DSO, Dynamic Shared Object}
they live in, so that they don't clutter they live in, so that they don't clutter

View File

@ -35,7 +35,7 @@ namespace sgpem
It IS a Schedulable object. It IS a Schedulable object.
*/ */
class DLLEXPORT Process : public Schedulable class SG_DLLEXPORT Process : public Schedulable
{ {
public: public:
Process(const Glib::ustring& name, const unsigned int& arrival, const unsigned int& total, const int& priority); Process(const Glib::ustring& name, const unsigned int& arrival, const unsigned int& total, const int& priority);

View File

@ -36,7 +36,7 @@ namespace sgpem
* All subclasses are ... (FIXME: teach Luca and Marco what's * All subclasses are ... (FIXME: teach Luca and Marco what's
* the Italian language for, damn them! -- they must have * the Italian language for, damn them! -- they must have
* *smoked* mushrooms! :-) ) */ * *smoked* mushrooms! :-) ) */
class DLLEXPORT Schedulable class SG_DLLEXPORT Schedulable
{ {
public: public:
Schedulable(const Glib::ustring& name, const unsigned int& arrival, const unsigned int& total, const int& priority); Schedulable(const Glib::ustring& name, const unsigned int& arrival, const unsigned int& total, const int& priority);

View File

@ -36,7 +36,7 @@ namespace sgpem
Objects SchedulableStatus are created by Scheduler and destroyed by SimulationStatus if they are linked to it Objects SchedulableStatus are created by Scheduler and destroyed by SimulationStatus if they are linked to it
or by Scheduler. or by Scheduler.
*/ */
class DLLEXPORT SchedulableStatus class SG_DLLEXPORT SchedulableStatus
{ {
public: public:
enum state enum state

View File

@ -37,7 +37,7 @@ namespace sgpem
running and other infos (since M02+) running and other infos (since M02+)
*/ */
class DLLEXPORT SimulationStatus class SG_DLLEXPORT SimulationStatus
{ {
public: public:
SimulationStatus(); SimulationStatus();

View File

@ -36,7 +36,7 @@ namespace sgpem
*/ */
class DLLEXPORT Slice class SG_DLLEXPORT Slice
{ {
public: public:
Slice(const int& start, const int& duration, const SimulationStatus& status); Slice(const int& start, const int& duration, const SimulationStatus& status);

View File

@ -24,6 +24,6 @@
#include "config.h" #include "config.h"
/** \brief This function starts the whole GUI */ /** \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 #endif