[libgis] Win32 build fixes
- From: Andy Spencer <andys src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [libgis] Win32 build fixes
- Date: Fri, 10 Sep 2010 03:16:58 +0000 (UTC)
commit 08b979cf4e173ae461ce0e823ba08a732f4b7cbf
Author: Andy Spencer <andy753421 gmail com>
Date: Sun May 2 01:31:59 2010 +0000
Win32 build fixes
.gitignore | 1 +
configure.ac | 3 +++
gen-win32.sh | 8 ++------
src/Makefile.am | 11 +++++++----
src/gis-test.c | 4 ++--
5 files changed, 15 insertions(+), 12 deletions(-)
---
diff --git a/.gitignore b/.gitignore
index baff3a0..e3a68c6 100644
--- a/.gitignore
+++ b/.gitignore
@@ -3,6 +3,7 @@
*~
.*.swp
.swp
+build/
Makefile
Makefile.in
aclocal.m4
diff --git a/configure.ac b/configure.ac
index 6aa57c8..14e1353 100644
--- a/configure.ac
+++ b/configure.ac
@@ -24,6 +24,9 @@ case "${host}" in
*cygwin*) WIN32="yes" ;;
*) WIN32="no" ;;
esac
+if test "$WIN32" = yes; then
+ ac_default_prefix="/"
+fi
AM_CONDITIONAL([WIN32], test "$WIN32" = "yes")
AM_CONDITIONAL([NOTWIN32], test "$WIN32" = "no")
diff --git a/gen-win32.sh b/gen-win32.sh
index 7106b06..ec4c407 100755
--- a/gen-win32.sh
+++ b/gen-win32.sh
@@ -1,7 +1,3 @@
#!/bin/bash
-dir=$(dirname $(readlink -f $0))
-./autogen.sh \
- "--host=i686-pc-mingw32" \
- "--libdir=Z:$dir/src/.libs" \
- "--includedir=Z:$dir/include" \
- CFLAGS="-g -Werror -Wno-unused $CFLAGS"
+export CFLAGS="-g -Werror -Wno-unused -O3"
+./autogen.sh --host=i686-pc-mingw32
diff --git a/src/Makefile.am b/src/Makefile.am
index 1673dff..b41ca09 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -37,15 +37,18 @@ libgis_la_SOURCES = gis.h \
roam.c roam.h \
gpqueue.c gpqueue.h
libgis_la_CPPFLAGS = $(AM_CPPFLAGS) \
- -DPKGDATADIR="\"$(datadir)/gis\"" \
- -DPLUGINSDIR="\"$(libdir)/gis\""
+ -DPKGDATADIR="\"$(dots)$(datadir)/gis\"" \
+ -DPLUGINSDIR="\"$(dots)$(libdir)/gis\""
libgis_la_LIBADD = $(AM_LDADD) \
objects/libgis-objects.la \
data/libgis-data.la
# Demo program
-if NOTWIN32
-BINLDFLAGS = -static
+if WIN32
+AM_LDFLAGS += -mwindows
+dots = ..
+else
+BINLDFLAGS = -static
endif
bin_PROGRAMS = gis-demo
diff --git a/src/gis-test.c b/src/gis-test.c
index 6366ade..1146f41 100644
--- a/src/gis-test.c
+++ b/src/gis-test.c
@@ -88,8 +88,8 @@ int main(int argc, char **argv)
/* Configurable stuff */
gis_viewer_set_offline(viewer, TRUE);
- //load_plugin(plugins, "elev", viewer, prefs, GTK_NOTEBOOK(config));
- //load_plugin(plugins, "env", viewer, prefs, GTK_NOTEBOOK(config));
+ load_plugin(plugins, "elev", viewer, prefs, GTK_NOTEBOOK(config));
+ load_plugin(plugins, "env", viewer, prefs, GTK_NOTEBOOK(config));
//load_plugin(plugins, "map", viewer, prefs, GTK_NOTEBOOK(config));
load_plugin(plugins, "sat", viewer, prefs, GTK_NOTEBOOK(config));
//load_plugin(plugins, "test", viewer, prefs, GTK_NOTEBOOK(config));
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]