[glom] Revert "Really never use config.h in libglom."
- From: David King <davidk src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [glom] Revert "Really never use config.h in libglom."
- Date: Mon, 31 Aug 2009 12:56:44 +0000 (UTC)
commit 3bf3f74ef97f223cf7988cec7c98689239dafcec
Author: David King <davidk openismus com>
Date: Mon Aug 31 14:56:14 2009 +0200
Revert "Really never use config.h in libglom."
This reverts commit 8d73f2051fb624e145505b3587a12d89ed3c8326.
The change gave no benefits, but did break any project that used libglom
and autoheader.
ChangeLog | 9 +++++++++
glom/libglom/appstate.cc | 4 ++--
glom/libglom/connectionpool.cc | 4 ++--
glom/libglom/connectionpool.h | 3 ++-
glom/libglom/connectionpool_backends/backend.h | 2 +-
glom/libglom/connectionpool_backends/postgres.cc | 7 ++++---
glom/libglom/connectionpool_backends/postgres.h | 6 +++---
.../connectionpool_backends/postgres_central.cc | 3 ++-
.../connectionpool_backends/postgres_central.h | 3 ++-
.../connectionpool_backends/postgres_self.cc | 2 +-
.../connectionpool_backends/postgres_self.h | 3 ++-
glom/libglom/connectionpool_backends/sqlite.cc | 3 ++-
glom/libglom/connectionpool_backends/sqlite.h | 3 ++-
glom/libglom/data_structure/glomconversions.cc | 2 +-
glom/libglom/data_structure/iso_codes.cc | 2 +-
glom/libglom/document/bakery/document.cc | 2 +-
glom/libglom/document/document.h | 3 ++-
glom/libglom/libglom_config.h.in | 13 -------------
glom/libglom/utils.cc | 3 ++-
19 files changed, 41 insertions(+), 36 deletions(-)
---
diff --git a/ChangeLog b/ChangeLog
index 05a8382..28a8df2 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,12 @@
+2009-08-31 David King <davidk openismus com>
+
+ Revert "Really never use config.h in libglom."
+
+ This reverts commit 8d73f2051fb624e145505b3587a12d89ed3c8326.
+
+ The change gave no benefits, but did break any project that used libglom
+ and autoheader.
+
2009-08-31 Johannes Schmid <jschmid openismus com>
* Makefile_test.am: Fixed make dist (probably automake-1.11 is more
diff --git a/glom/libglom/appstate.cc b/glom/libglom/appstate.cc
index 016615e..f0e4c0b 100644
--- a/glom/libglom/appstate.cc
+++ b/glom/libglom/appstate.cc
@@ -18,8 +18,8 @@
* Boston, MA 02111-1307, USA.
*/
-#include <libglom/appstate.h>
-#include <libglom/libglom_config.h>
+#include <libglom/libglom_config.h> // GLOM_ENABLE_CLIENT_ONLY
+#include "appstate.h"
namespace Glom
diff --git a/glom/libglom/connectionpool.cc b/glom/libglom/connectionpool.cc
index 64fa8b4..b5bf139 100644
--- a/glom/libglom/connectionpool.cc
+++ b/glom/libglom/connectionpool.cc
@@ -18,12 +18,12 @@
* Boston, MA 02111-1307, USA.
*/
-
+#include <libglom/libglom_config.h>
+
#include <libglom/connectionpool.h>
#include <libglom/document/document.h>
#include <libglom/utils.h>
//#include <libgdamm/connectionevent.h>
-#include <libglom/libglom_config.h>
#include <glibmm/i18n.h>
#ifdef G_OS_WIN32
diff --git a/glom/libglom/connectionpool.h b/glom/libglom/connectionpool.h
index 67d57c2..4af3563 100644
--- a/glom/libglom/connectionpool.h
+++ b/glom/libglom/connectionpool.h
@@ -21,12 +21,13 @@
#ifndef GLOM_CONNECTIONPOOL_H
#define GLOM_CONNECTIONPOOL_H
+#include <libglom/libglom_config.h> // For GLOM_ENABLE_CLIENT_ONLY
+
#include <libgdamm.h>
#include <libglom/sharedptr.h>
#include <libglom/data_structure/fieldtypes.h>
#include <libglom/data_structure/field.h>
#include <libglom/connectionpool_backends/backend.h>
-#include <libglom/libglom_config.h>
#include <memory> // For std::auto_ptr
diff --git a/glom/libglom/connectionpool_backends/backend.h b/glom/libglom/connectionpool_backends/backend.h
index b1f4f22..f731139 100644
--- a/glom/libglom/connectionpool_backends/backend.h
+++ b/glom/libglom/connectionpool_backends/backend.h
@@ -21,10 +21,10 @@
#ifndef GLOM_BACKEND_BACKEND_H
#define GLOM_BACKEND_BACKEND_H
+#include <libglom/libglom_config.h> // For GLOM_ENABLE_CLIENT_ONLY
#include <libglom/sharedptr.h>
#include <libglom/data_structure/field.h>
-#include <libglom/libglom_config.h>
#include <memory>
diff --git a/glom/libglom/connectionpool_backends/postgres.cc b/glom/libglom/connectionpool_backends/postgres.cc
index d33f24f..90f9c73 100644
--- a/glom/libglom/connectionpool_backends/postgres.cc
+++ b/glom/libglom/connectionpool_backends/postgres.cc
@@ -18,10 +18,10 @@
* Boston, MA 02111-1307, USA.
*/
+#include <libglom/libglom_config.h>
#include <libglom/connectionpool_backends/postgres.h>
#include <libglom/utils.h>
-#include <libglom/libglom_config.h>
#include <glibmm/i18n.h>
// Uncomment to see debug messages
@@ -81,14 +81,15 @@ Glib::RefPtr<Gnome::Gda::Connection> Postgres::attempt_connect(const Glib::ustri
std::cout << " DEBUG: auth_string=" << auth_string << std::endl;
#endif
-//TODO: Allow the client-only build to specify a read-only connection,
-//so we can use Gnome::Gda::CONNECTION_OPTIONS_READ_ONLY?
#ifdef GLIBMM_EXCEPTIONS_ENABLED
try
{
connection = Gnome::Gda::Connection::open_from_string("PostgreSQL",
cnc_string, auth_string,
Gnome::Gda::CONNECTION_OPTIONS_SQL_IDENTIFIERS_CASE_SENSITIVE
+#ifndef GLOM_ENABLE_CLIENT_ONLY
+ | Gnome::Gda::CONNECTION_OPTIONS_READ_ONLY
+#endif
);
connection->statement_execute_non_select("SET DATESTYLE = 'ISO'");
data_model = connection->statement_execute_select("SELECT version()");
diff --git a/glom/libglom/connectionpool_backends/postgres.h b/glom/libglom/connectionpool_backends/postgres.h
index 5660672..5165454 100644
--- a/glom/libglom/connectionpool_backends/postgres.h
+++ b/glom/libglom/connectionpool_backends/postgres.h
@@ -21,10 +21,10 @@
#ifndef GLOM_BACKEND_POSTGRES_H
#define GLOM_BACKEND_POSTGRES_H
-
-#include <libglom/libglom_config.h>
-#include <libglom/connectionpool_backends/backend.h>
#include <libgdamm.h>
+#include <libglom/connectionpool_backends/backend.h>
+
+#include <libglom/libglom_config.h> // For GLOM_ENABLE_CLIENT_ONLY
namespace Glom
{
diff --git a/glom/libglom/connectionpool_backends/postgres_central.cc b/glom/libglom/connectionpool_backends/postgres_central.cc
index 7d41c7e..3d242f8 100644
--- a/glom/libglom/connectionpool_backends/postgres_central.cc
+++ b/glom/libglom/connectionpool_backends/postgres_central.cc
@@ -18,8 +18,9 @@
* Boston, MA 02111-1307, USA.
*/
-#include <libglom/connectionpool_backends/postgres_central.h>
#include <libglom/libglom_config.h>
+
+#include <libglom/connectionpool_backends/postgres_central.h>
#include <glibmm/i18n.h>
// Uncomment to see debug messages
diff --git a/glom/libglom/connectionpool_backends/postgres_central.h b/glom/libglom/connectionpool_backends/postgres_central.h
index 16ec5f8..7858786 100644
--- a/glom/libglom/connectionpool_backends/postgres_central.h
+++ b/glom/libglom/connectionpool_backends/postgres_central.h
@@ -21,9 +21,10 @@
#ifndef GLOM_BACKEND_POSTGRES_CENTRAL_H
#define GLOM_BACKEND_POSTGRES_CENTRAL_H
-#include <libglom/libglom_config.h>
#include <libglom/connectionpool_backends/postgres.h>
+#include <libglom/libglom_config.h> // For GLOM_ENABLE_CLIENT_ONLY
+
namespace Glom
{
diff --git a/glom/libglom/connectionpool_backends/postgres_self.cc b/glom/libglom/connectionpool_backends/postgres_self.cc
index fe3a94a..5640b1f 100644
--- a/glom/libglom/connectionpool_backends/postgres_self.cc
+++ b/glom/libglom/connectionpool_backends/postgres_self.cc
@@ -18,7 +18,7 @@
* Boston, MA 02111-1307, USA.
*/
-#include <libglom/libglom_config.h> // For POSTGRES_UTILS_PATH
+#include <config.h> // For POSTGRES_UTILS_PATH
#include <libglom/connectionpool_backends/postgres_self.h>
#include <libglom/utils.h>
diff --git a/glom/libglom/connectionpool_backends/postgres_self.h b/glom/libglom/connectionpool_backends/postgres_self.h
index 3fbd5fe..027b1d8 100644
--- a/glom/libglom/connectionpool_backends/postgres_self.h
+++ b/glom/libglom/connectionpool_backends/postgres_self.h
@@ -21,8 +21,9 @@
#ifndef GLOM_BACKEND_POSTGRES_SELF_H
#define GLOM_BACKEND_POSTGRES_SELF_H
+#include <libglom/libglom_config.h> // For GLOM_ENABLE_CLIENT_ONLY
+
#include <libglom/connectionpool_backends/postgres.h>
-#include <libglom/libglom_config.h>
namespace Glom
{
diff --git a/glom/libglom/connectionpool_backends/sqlite.cc b/glom/libglom/connectionpool_backends/sqlite.cc
index 71f0e76..c72241d 100644
--- a/glom/libglom/connectionpool_backends/sqlite.cc
+++ b/glom/libglom/connectionpool_backends/sqlite.cc
@@ -18,10 +18,11 @@
* Boston, MA 02111-1307, USA.
*/
+#include <libglom/libglom_config.h>
#include <libglom/connectionpool_backends/sqlite.h>
+
#include <giomm/file.h>
-#include <libglom/libglom_config.h>
namespace Glom
{
diff --git a/glom/libglom/connectionpool_backends/sqlite.h b/glom/libglom/connectionpool_backends/sqlite.h
index 1de6d42..0b33931 100644
--- a/glom/libglom/connectionpool_backends/sqlite.h
+++ b/glom/libglom/connectionpool_backends/sqlite.h
@@ -23,7 +23,8 @@
#include <libgdamm.h>
#include <libglom/connectionpool_backends/backend.h>
-#include <libglom/libglom_config.h>
+
+#include <libglom/libglom_config.h> // For GLOM_ENABLE_CLIENT_ONLY
namespace Glom
{
diff --git a/glom/libglom/data_structure/glomconversions.cc b/glom/libglom/data_structure/glomconversions.cc
index 8af507c..ae70df7 100644
--- a/glom/libglom/data_structure/glomconversions.cc
+++ b/glom/libglom/data_structure/glomconversions.cc
@@ -19,11 +19,11 @@
*/
+#include <libglom/libglom_config.h> // For HAVE_STRPTIME
#include "glomconversions.h"
#include <libglom/connectionpool.h>
#include <libglom/utils.h>
-#include <libglom/libglom_config.h> // For HAVE_STRPTIME
#include <glibmm/i18n.h>
#include <sstream> //For stringstream
diff --git a/glom/libglom/data_structure/iso_codes.cc b/glom/libglom/data_structure/iso_codes.cc
index 336da38..5e649c2 100644
--- a/glom/libglom/data_structure/iso_codes.cc
+++ b/glom/libglom/data_structure/iso_codes.cc
@@ -18,12 +18,12 @@
* Boston, MA 02111-1307, USA.
*/
+#include <libglom/libglom_config.h> //For ISO_CODES_PREFIX.
#include <libglom/data_structure/iso_codes.h>
#include <libxml++/libxml++.h>
#include <libglom/document/document.h>
#include <libglom/utils.h>
-#include <libglom/libglom_config.h> //For ISO_CODES_PREFIX.
#include <glibmm/i18n.h>
namespace Glom
diff --git a/glom/libglom/document/bakery/document.cc b/glom/libglom/document/bakery/document.cc
index a40472e..9b80865 100644
--- a/glom/libglom/document/bakery/document.cc
+++ b/glom/libglom/document/bakery/document.cc
@@ -16,8 +16,8 @@
* Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
+#include <config.h>
#include <libglom/document/bakery/document.h>
-#include <libglom/libglom_config.h>
#include <giomm.h>
//#include <fstream>
#include <glibmm/i18n-lib.h>
diff --git a/glom/libglom/document/document.h b/glom/libglom/document/document.h
index fa06307..d3169eb 100644
--- a/glom/libglom/document/document.h
+++ b/glom/libglom/document/document.h
@@ -21,6 +21,8 @@
#ifndef DOCUMENT_GLOM_H
#define DOCUMENT_GLOM_H
+#include <libglom/libglom_config.h> // For GLOM_ENABLE_CLIENT_ONLY
+
#include <libglom/document/bakery/document_xml.h>
#include <libglom/data_structure/relationship.h>
#include <libglom/data_structure/field.h>
@@ -36,7 +38,6 @@
#include <libglom/data_structure/print_layout.h>
#include <libglom/data_structure/foundset.h>
#include <libglom/appstate.h>
-#include <libglom/libglom_config.h>
#include <vector>
#include <map>
#include <limits> // for numeric_limits
diff --git a/glom/libglom/libglom_config.h.in b/glom/libglom/libglom_config.h.in
index c6e0d71..28be5dd 100644
--- a/glom/libglom/libglom_config.h.in
+++ b/glom/libglom/libglom_config.h.in
@@ -5,16 +5,9 @@
/* "definition of GLOM_DTD_INSTALL_DIR" */
#undef GLOM_DTD_INSTALL_DIR
-//TODO: Should libglom have separate translations than Glom itself? How? murrayc.
/* Define to 1 if you have the `dcgettext' function. */
#undef HAVE_DCGETTEXT
-/* Define to the gettext package name. */
-#undef GETTEXT_PACKAGE
-
-/* Define to the one symbol short name of this package. */
-#undef PACKAGE_TARNAME
-
/* Define to 1 if you have the <dlfcn.h> header file. */
#undef HAVE_DLFCN_H
@@ -27,10 +20,4 @@
/* Define to the installation prefix of the iso-codes module. */
#undef ISO_CODES_PREFIX
-/* Define to the location of the PostgreSQL utilities. */
-#undef POSTGRES_UTILS_PATH
-
-/* Define to the file extension of executables on the target. */
-#undef EXEEXT
-
#endif /* GLOM_LIBGLOM_CONFIG_H */
diff --git a/glom/libglom/utils.cc b/glom/libglom/utils.cc
index 280eda4..48a0b99 100644
--- a/glom/libglom/utils.cc
+++ b/glom/libglom/utils.cc
@@ -18,11 +18,12 @@
* Boston, MA 02111-1307, USA.
*/
+#include <libglom/libglom_config.h>
+
#include <libglom/utils.h>
#include <libglom/connectionpool.h>
#include <libglom/data_structure/layout/report_parts/layoutitem_fieldsummary.h>
#include <libglom/data_structure/glomconversions.h>
-#include <libglom/libglom_config.h>
#include <glibmm/i18n.h>
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]