RE: [gnome-db] Building libgda on Windows



Rodrigo,

Here is a makefile i used to successfully build a shared library (DLL) on
Windows that uses gtk 2.0 and runs with a gtk+ test program i have.

I'm thinking I could use something from here to help get libgda built on
Windows.  I was looking at the gtk# for Win32 build files for this.

# Makefile for gnome-db-sqleditor

PROJECT = sqleditor.dll

MODULES = gnome-db-sqleditor.c
OBJS = gnome-db-sqleditor.o

CFLAGS = `pkg-config --cflags gtk+-2.0`
LIBS = `pkg-config --libs gtk+-2.0`

CC = gcc -b i686-pc-mingw32

all: $(PROJECT)

$(PROJECT) :
	$(CC) -shared -mms-bitfields -mno-cygwin -Wall $(CFLAGS) -o $(PROJECT)
$(MODULES) $(LIBS)
clean:
	rm -f *.o
	rm -f $(PROJECT).exe

# This is the makefile for the test program
MODULES = testsqleditor.c
OBJS = testsqleditor.o

PKG_CONFIG_PATH=/home/DanielMorgan/mono/install/lib/pkgconfig

CFLAGS = `pkg-config --cflags gtk+-2.0`
LIBS = `pkg-config --libs
gtk+-2.0` -lsqleditor -L/cygdrive/e/projects/GnomeDbSqlEditor/v0.0.0

CC = gcc -b i686-pc-mingw32

all: $(PROJECT)

$(PROJECT) :
	$(CC) -mms-bitfields -mno-cygwin -Wall $(CFLAGS) -o $(PROJECT) $(MODULES)
$(LIBS)
clean:
	rm -f *.o
	rm -f $(PROJECT).exe

-----Original Message-----
From: gnome-db-list-admin gnome org
[mailto:gnome-db-list-admin gnome org]On Behalf Of Rodrigo Moya
Sent: Monday, October 21, 2002 5:55 AM
To: Daniel Morgan
Cc: Gnome DB
Subject: Re: [gnome-db] Building libgda on Windows


On Wed, 2002-10-16 at 14:28, Daniel Morgan wrote:
>
> Another possibility, I have mentioned to Rodrigo before, is to create make
> files by hand for Cygwin.  Call these files makefile.cygwin and they would
> have to be manually updated to point to your prefix, database libraries,
> dependencies such as glib-2.0, and libxml2, etc...
>
you should also be making use of pkg-config, so that manual editing is
not needed.

> I don't know where to start on this.  It would probably be best to create
> makefiles by hand to build on Linux, and with these makefiles, base the
> Cygwin makefiles off of the Linux makefiles.
>
> Here is something I could use to build libgda on Cygwin:
> gcc -shared -fPIC -DPIC libgda_objects.o -o libgda-2.dll
> `pkg-config --cflags --libs glib-2.0` -lany_other_libs
>
yes

> Need to take account for -DDEFINES switches too.
>
yes

> The last time I tried to build libgda on cygwin, it could not find the
> PostgreSQL nor MySQL headers/libraries even though I provided the path to
> them.
>
what do you mean?

cheers

_______________________________________________
gnome-db-list mailing list
gnome-db-list gnome org
http://mail.gnome.org/mailman/listinfo/gnome-db-list




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]