Commit 5c00c349 authored by Tor Lillqvist's avatar Tor Lillqvist Committed by Tor Lillqvist

Cygwin support contributed by Stefan Ondrejicka <ondrej@idata.sk>.

2001-02-21  Tor Lillqvist  <tml@iki.fi>

	Cygwin support contributed by Stefan Ondrejicka
	<ondrej@idata.sk>. Hopefully I got it all in while simultaneously
	adding support for auto*/libtool for mingw.

	* Makefile.am: Changes for auto* support on Cygwin and Win32. Do
	still distribute the hand-written makefiles and *.win32.in files,
	though. Use GIO, GSPAWN and PLATFORMDEP macros set by configure.
	Use -no-undefined. Pass -export-symbols glib.def to libtool.

	* configure.in: Define G_PLATFORM_WIN32 on both pure Win32 (mingw)
	and Cygwin. Add AC_CYGWIN, AC_EXEEXT and AC_LIBTOOL_WIN32_DLL
	calls for Cygwin and mingw support.  Check for %I64u guint64
	format (in MS C library). Set G_MODULE_IMPL on mingw and
	Cygwin. Use ac_object and ac_exeext.  Set GIO, GSPAWN, PLATFORMDEP
	and G_LIBS_EXTRA. Compile timeloop only on Unix. Define OS_WIN32
	automake conditional on Win32.

	* glib.h: Include gwin32.h also on Cygwin.

	* gfileutils.c (get_contents_posix): Use O_BINARY (defined as 0 on
	Unix) for Cygwin's sake.

	* gtimer.c (GETTIME): Reduce #ifdefs, use a macro GETTIME().

	* gconvert.c
	* gthread.c
	* gutf8.c
	* gutils.c: For code needed both on Cygwin and native Win32,
	test for G_PLATFORM_WIN32.

	* gtypes.h: Refine GLIB_VAR definition. Also check for DLL_EXPORT
	in case compiling a static library on Win32 or Cygwin.

	* gwin32.c: No <direct.h> on Cygwin. No need for ftruncate() or
	dirent emulation on Cygwin.
	(get_package_directory_from_module) Convert return value from
	GetModuleFileName() to POSIX path on Cygwin.

	* tests/Makefile.am (progs_LDADD): Link with libglib, libgthread
	and libgmodule as appropriate. Use -no-undefined.

	* gbacktrace.c: Move #ifdefs around a bit on Win32.

	* gshell.c (unquote_string_inplace): Make static.
parent 608608fc
......@@ -84,7 +84,54 @@ Thu Feb 22 10:31:36 2001 Owen Taylor <otaylor@redhat.com>
2001-02-21 Tor Lillqvist <tml@iki.fi>
* gutils.c (g_path_is_absolute): Match also UNC paths on Win32.
* gutils.c (g_find_program_in_path): Implement on Win32.
Cygwin support contributed by Stefan Ondrejicka
<ondrej@idata.sk>. Hopefully I got it all in while simultaneously
adding support for auto*/libtool for mingw.
* Makefile.am: Changes for auto* support on Cygwin and Win32. Do
still distribute the hand-written makefiles and *.win32.in files,
though. Use GIO, GSPAWN and PLATFORMDEP macros set by configure.
Use -no-undefined. Pass -export-symbols glib.def to libtool.
* configure.in: Define G_PLATFORM_WIN32 on both pure Win32 (mingw)
and Cygwin. Add AC_CYGWIN, AC_EXEEXT and AC_LIBTOOL_WIN32_DLL
calls for Cygwin and mingw support. Check for %I64u guint64
format (in MS C library). Set G_MODULE_IMPL on mingw and
Cygwin. Use ac_object and ac_exeext. Set GIO, GSPAWN, PLATFORMDEP
and G_LIBS_EXTRA. Compile timeloop only on Unix. Define OS_WIN32
automake conditional on Win32.
* glib.h: Include gwin32.h also on Cygwin.
* gfileutils.c (get_contents_posix): Use O_BINARY (defined as 0 on
Unix) for Cygwin's sake.
* gtimer.c (GETTIME): Reduce #ifdefs, use a macro GETTIME().
* gconvert.c
* gthread.c
* gutf8.c
* gutils.c: For code needed both on Cygwin and native Win32,
test for G_PLATFORM_WIN32.
* gtypes.h: Refine GLIB_VAR definition. Also check for DLL_EXPORT
in case compiling a static library on Win32 or Cygwin.
* gwin32.c: No <direct.h> on Cygwin. No need for ftruncate() or
dirent emulation on Cygwin.
(get_package_directory_from_module) Convert return value from
GetModuleFileName() to POSIX path on Cygwin.
* tests/Makefile.am (progs_LDADD): Link with libglib, libgthread
and libgmodule as appropriate. Use -no-undefined.
* gbacktrace.c: Move #ifdefs around a bit on Win32.
2001-02-21 Tor Lillqvist <tml@iki.fi>
* gshell.c (unquote_string_inplace): Make static.
* gthread.h: Include gtypes.h to be sure to get GLIB_VAR
definition, remove definition from here.
......@@ -97,11 +144,14 @@ Thu Feb 22 10:31:36 2001 Owen Taylor <otaylor@redhat.com>
* Makefile.am (INCLUDES): Add -DGLIB_COMPILATION.
* makefile.mingw.in: Remove install target, Windows isn't Unix.
(DEFINES): Add -DDLL_EXPORT.
* testgdate.c
* testgdateparser.c
* testglib.c: Undefine GLIB_COMPILATION.
* testglib.c: Make some vars static. Add Cygwin path tests.
* glib.def: Updates.
* .cvsignore
......
......@@ -84,7 +84,54 @@ Thu Feb 22 10:31:36 2001 Owen Taylor <otaylor@redhat.com>
2001-02-21 Tor Lillqvist <tml@iki.fi>
* gutils.c (g_path_is_absolute): Match also UNC paths on Win32.
* gutils.c (g_find_program_in_path): Implement on Win32.
Cygwin support contributed by Stefan Ondrejicka
<ondrej@idata.sk>. Hopefully I got it all in while simultaneously
adding support for auto*/libtool for mingw.
* Makefile.am: Changes for auto* support on Cygwin and Win32. Do
still distribute the hand-written makefiles and *.win32.in files,
though. Use GIO, GSPAWN and PLATFORMDEP macros set by configure.
Use -no-undefined. Pass -export-symbols glib.def to libtool.
* configure.in: Define G_PLATFORM_WIN32 on both pure Win32 (mingw)
and Cygwin. Add AC_CYGWIN, AC_EXEEXT and AC_LIBTOOL_WIN32_DLL
calls for Cygwin and mingw support. Check for %I64u guint64
format (in MS C library). Set G_MODULE_IMPL on mingw and
Cygwin. Use ac_object and ac_exeext. Set GIO, GSPAWN, PLATFORMDEP
and G_LIBS_EXTRA. Compile timeloop only on Unix. Define OS_WIN32
automake conditional on Win32.
* glib.h: Include gwin32.h also on Cygwin.
* gfileutils.c (get_contents_posix): Use O_BINARY (defined as 0 on
Unix) for Cygwin's sake.
* gtimer.c (GETTIME): Reduce #ifdefs, use a macro GETTIME().
* gconvert.c
* gthread.c
* gutf8.c
* gutils.c: For code needed both on Cygwin and native Win32,
test for G_PLATFORM_WIN32.
* gtypes.h: Refine GLIB_VAR definition. Also check for DLL_EXPORT
in case compiling a static library on Win32 or Cygwin.
* gwin32.c: No <direct.h> on Cygwin. No need for ftruncate() or
dirent emulation on Cygwin.
(get_package_directory_from_module) Convert return value from
GetModuleFileName() to POSIX path on Cygwin.
* tests/Makefile.am (progs_LDADD): Link with libglib, libgthread
and libgmodule as appropriate. Use -no-undefined.
* gbacktrace.c: Move #ifdefs around a bit on Win32.
2001-02-21 Tor Lillqvist <tml@iki.fi>
* gshell.c (unquote_string_inplace): Make static.
* gthread.h: Include gtypes.h to be sure to get GLIB_VAR
definition, remove definition from here.
......@@ -97,11 +144,14 @@ Thu Feb 22 10:31:36 2001 Owen Taylor <otaylor@redhat.com>
* Makefile.am (INCLUDES): Add -DGLIB_COMPILATION.
* makefile.mingw.in: Remove install target, Windows isn't Unix.
(DEFINES): Add -DDLL_EXPORT.
* testgdate.c
* testgdateparser.c
* testglib.c: Undefine GLIB_COMPILATION.
* testglib.c: Make some vars static. Add Cygwin path tests.
* glib.def: Updates.
* .cvsignore
......
......@@ -84,7 +84,54 @@ Thu Feb 22 10:31:36 2001 Owen Taylor <otaylor@redhat.com>
2001-02-21 Tor Lillqvist <tml@iki.fi>
* gutils.c (g_path_is_absolute): Match also UNC paths on Win32.
* gutils.c (g_find_program_in_path): Implement on Win32.
Cygwin support contributed by Stefan Ondrejicka
<ondrej@idata.sk>. Hopefully I got it all in while simultaneously
adding support for auto*/libtool for mingw.
* Makefile.am: Changes for auto* support on Cygwin and Win32. Do
still distribute the hand-written makefiles and *.win32.in files,
though. Use GIO, GSPAWN and PLATFORMDEP macros set by configure.
Use -no-undefined. Pass -export-symbols glib.def to libtool.
* configure.in: Define G_PLATFORM_WIN32 on both pure Win32 (mingw)
and Cygwin. Add AC_CYGWIN, AC_EXEEXT and AC_LIBTOOL_WIN32_DLL
calls for Cygwin and mingw support. Check for %I64u guint64
format (in MS C library). Set G_MODULE_IMPL on mingw and
Cygwin. Use ac_object and ac_exeext. Set GIO, GSPAWN, PLATFORMDEP
and G_LIBS_EXTRA. Compile timeloop only on Unix. Define OS_WIN32
automake conditional on Win32.
* glib.h: Include gwin32.h also on Cygwin.
* gfileutils.c (get_contents_posix): Use O_BINARY (defined as 0 on
Unix) for Cygwin's sake.
* gtimer.c (GETTIME): Reduce #ifdefs, use a macro GETTIME().
* gconvert.c
* gthread.c
* gutf8.c
* gutils.c: For code needed both on Cygwin and native Win32,
test for G_PLATFORM_WIN32.
* gtypes.h: Refine GLIB_VAR definition. Also check for DLL_EXPORT
in case compiling a static library on Win32 or Cygwin.
* gwin32.c: No <direct.h> on Cygwin. No need for ftruncate() or
dirent emulation on Cygwin.
(get_package_directory_from_module) Convert return value from
GetModuleFileName() to POSIX path on Cygwin.
* tests/Makefile.am (progs_LDADD): Link with libglib, libgthread
and libgmodule as appropriate. Use -no-undefined.
* gbacktrace.c: Move #ifdefs around a bit on Win32.
2001-02-21 Tor Lillqvist <tml@iki.fi>
* gshell.c (unquote_string_inplace): Make static.
* gthread.h: Include gtypes.h to be sure to get GLIB_VAR
definition, remove definition from here.
......@@ -97,11 +144,14 @@ Thu Feb 22 10:31:36 2001 Owen Taylor <otaylor@redhat.com>
* Makefile.am (INCLUDES): Add -DGLIB_COMPILATION.
* makefile.mingw.in: Remove install target, Windows isn't Unix.
(DEFINES): Add -DDLL_EXPORT.
* testgdate.c
* testgdateparser.c
* testglib.c: Undefine GLIB_COMPILATION.
* testglib.c: Make some vars static. Add Cygwin path tests.
* glib.def: Updates.
* .cvsignore
......
......@@ -84,7 +84,54 @@ Thu Feb 22 10:31:36 2001 Owen Taylor <otaylor@redhat.com>
2001-02-21 Tor Lillqvist <tml@iki.fi>
* gutils.c (g_path_is_absolute): Match also UNC paths on Win32.
* gutils.c (g_find_program_in_path): Implement on Win32.
Cygwin support contributed by Stefan Ondrejicka
<ondrej@idata.sk>. Hopefully I got it all in while simultaneously
adding support for auto*/libtool for mingw.
* Makefile.am: Changes for auto* support on Cygwin and Win32. Do
still distribute the hand-written makefiles and *.win32.in files,
though. Use GIO, GSPAWN and PLATFORMDEP macros set by configure.
Use -no-undefined. Pass -export-symbols glib.def to libtool.
* configure.in: Define G_PLATFORM_WIN32 on both pure Win32 (mingw)
and Cygwin. Add AC_CYGWIN, AC_EXEEXT and AC_LIBTOOL_WIN32_DLL
calls for Cygwin and mingw support. Check for %I64u guint64
format (in MS C library). Set G_MODULE_IMPL on mingw and
Cygwin. Use ac_object and ac_exeext. Set GIO, GSPAWN, PLATFORMDEP
and G_LIBS_EXTRA. Compile timeloop only on Unix. Define OS_WIN32
automake conditional on Win32.
* glib.h: Include gwin32.h also on Cygwin.
* gfileutils.c (get_contents_posix): Use O_BINARY (defined as 0 on
Unix) for Cygwin's sake.
* gtimer.c (GETTIME): Reduce #ifdefs, use a macro GETTIME().
* gconvert.c
* gthread.c
* gutf8.c
* gutils.c: For code needed both on Cygwin and native Win32,
test for G_PLATFORM_WIN32.
* gtypes.h: Refine GLIB_VAR definition. Also check for DLL_EXPORT
in case compiling a static library on Win32 or Cygwin.
* gwin32.c: No <direct.h> on Cygwin. No need for ftruncate() or
dirent emulation on Cygwin.
(get_package_directory_from_module) Convert return value from
GetModuleFileName() to POSIX path on Cygwin.
* tests/Makefile.am (progs_LDADD): Link with libglib, libgthread
and libgmodule as appropriate. Use -no-undefined.
* gbacktrace.c: Move #ifdefs around a bit on Win32.
2001-02-21 Tor Lillqvist <tml@iki.fi>
* gshell.c (unquote_string_inplace): Make static.
* gthread.h: Include gtypes.h to be sure to get GLIB_VAR
definition, remove definition from here.
......@@ -97,11 +144,14 @@ Thu Feb 22 10:31:36 2001 Owen Taylor <otaylor@redhat.com>
* Makefile.am (INCLUDES): Add -DGLIB_COMPILATION.
* makefile.mingw.in: Remove install target, Windows isn't Unix.
(DEFINES): Add -DDLL_EXPORT.
* testgdate.c
* testgdateparser.c
* testglib.c: Undefine GLIB_COMPILATION.
* testglib.c: Make some vars static. Add Cygwin path tests.
* glib.def: Updates.
* .cvsignore
......
......@@ -84,7 +84,54 @@ Thu Feb 22 10:31:36 2001 Owen Taylor <otaylor@redhat.com>
2001-02-21 Tor Lillqvist <tml@iki.fi>
* gutils.c (g_path_is_absolute): Match also UNC paths on Win32.
* gutils.c (g_find_program_in_path): Implement on Win32.
Cygwin support contributed by Stefan Ondrejicka
<ondrej@idata.sk>. Hopefully I got it all in while simultaneously
adding support for auto*/libtool for mingw.
* Makefile.am: Changes for auto* support on Cygwin and Win32. Do
still distribute the hand-written makefiles and *.win32.in files,
though. Use GIO, GSPAWN and PLATFORMDEP macros set by configure.
Use -no-undefined. Pass -export-symbols glib.def to libtool.
* configure.in: Define G_PLATFORM_WIN32 on both pure Win32 (mingw)
and Cygwin. Add AC_CYGWIN, AC_EXEEXT and AC_LIBTOOL_WIN32_DLL
calls for Cygwin and mingw support. Check for %I64u guint64
format (in MS C library). Set G_MODULE_IMPL on mingw and
Cygwin. Use ac_object and ac_exeext. Set GIO, GSPAWN, PLATFORMDEP
and G_LIBS_EXTRA. Compile timeloop only on Unix. Define OS_WIN32
automake conditional on Win32.
* glib.h: Include gwin32.h also on Cygwin.
* gfileutils.c (get_contents_posix): Use O_BINARY (defined as 0 on
Unix) for Cygwin's sake.
* gtimer.c (GETTIME): Reduce #ifdefs, use a macro GETTIME().
* gconvert.c
* gthread.c
* gutf8.c
* gutils.c: For code needed both on Cygwin and native Win32,
test for G_PLATFORM_WIN32.
* gtypes.h: Refine GLIB_VAR definition. Also check for DLL_EXPORT
in case compiling a static library on Win32 or Cygwin.
* gwin32.c: No <direct.h> on Cygwin. No need for ftruncate() or
dirent emulation on Cygwin.
(get_package_directory_from_module) Convert return value from
GetModuleFileName() to POSIX path on Cygwin.
* tests/Makefile.am (progs_LDADD): Link with libglib, libgthread
and libgmodule as appropriate. Use -no-undefined.
* gbacktrace.c: Move #ifdefs around a bit on Win32.
2001-02-21 Tor Lillqvist <tml@iki.fi>
* gshell.c (unquote_string_inplace): Make static.
* gthread.h: Include gtypes.h to be sure to get GLIB_VAR
definition, remove definition from here.
......@@ -97,11 +144,14 @@ Thu Feb 22 10:31:36 2001 Owen Taylor <otaylor@redhat.com>
* Makefile.am (INCLUDES): Add -DGLIB_COMPILATION.
* makefile.mingw.in: Remove install target, Windows isn't Unix.
(DEFINES): Add -DDLL_EXPORT.
* testgdate.c
* testgdateparser.c
* testglib.c: Undefine GLIB_COMPILATION.
* testglib.c: Make some vars static. Add Cygwin path tests.
* glib.def: Updates.
* .cvsignore
......
......@@ -84,7 +84,54 @@ Thu Feb 22 10:31:36 2001 Owen Taylor <otaylor@redhat.com>
2001-02-21 Tor Lillqvist <tml@iki.fi>
* gutils.c (g_path_is_absolute): Match also UNC paths on Win32.
* gutils.c (g_find_program_in_path): Implement on Win32.
Cygwin support contributed by Stefan Ondrejicka
<ondrej@idata.sk>. Hopefully I got it all in while simultaneously
adding support for auto*/libtool for mingw.
* Makefile.am: Changes for auto* support on Cygwin and Win32. Do
still distribute the hand-written makefiles and *.win32.in files,
though. Use GIO, GSPAWN and PLATFORMDEP macros set by configure.
Use -no-undefined. Pass -export-symbols glib.def to libtool.
* configure.in: Define G_PLATFORM_WIN32 on both pure Win32 (mingw)
and Cygwin. Add AC_CYGWIN, AC_EXEEXT and AC_LIBTOOL_WIN32_DLL
calls for Cygwin and mingw support. Check for %I64u guint64
format (in MS C library). Set G_MODULE_IMPL on mingw and
Cygwin. Use ac_object and ac_exeext. Set GIO, GSPAWN, PLATFORMDEP
and G_LIBS_EXTRA. Compile timeloop only on Unix. Define OS_WIN32
automake conditional on Win32.
* glib.h: Include gwin32.h also on Cygwin.
* gfileutils.c (get_contents_posix): Use O_BINARY (defined as 0 on
Unix) for Cygwin's sake.
* gtimer.c (GETTIME): Reduce #ifdefs, use a macro GETTIME().
* gconvert.c
* gthread.c
* gutf8.c
* gutils.c: For code needed both on Cygwin and native Win32,
test for G_PLATFORM_WIN32.
* gtypes.h: Refine GLIB_VAR definition. Also check for DLL_EXPORT
in case compiling a static library on Win32 or Cygwin.
* gwin32.c: No <direct.h> on Cygwin. No need for ftruncate() or
dirent emulation on Cygwin.
(get_package_directory_from_module) Convert return value from
GetModuleFileName() to POSIX path on Cygwin.
* tests/Makefile.am (progs_LDADD): Link with libglib, libgthread
and libgmodule as appropriate. Use -no-undefined.
* gbacktrace.c: Move #ifdefs around a bit on Win32.
2001-02-21 Tor Lillqvist <tml@iki.fi>
* gshell.c (unquote_string_inplace): Make static.
* gthread.h: Include gtypes.h to be sure to get GLIB_VAR
definition, remove definition from here.
......@@ -97,11 +144,14 @@ Thu Feb 22 10:31:36 2001 Owen Taylor <otaylor@redhat.com>
* Makefile.am (INCLUDES): Add -DGLIB_COMPILATION.
* makefile.mingw.in: Remove install target, Windows isn't Unix.
(DEFINES): Add -DDLL_EXPORT.
* testgdate.c
* testgdateparser.c
* testglib.c: Undefine GLIB_COMPILATION.
* testglib.c: Make some vars static. Add Cygwin path tests.
* glib.def: Updates.
* .cvsignore
......
......@@ -84,7 +84,54 @@ Thu Feb 22 10:31:36 2001 Owen Taylor <otaylor@redhat.com>
2001-02-21 Tor Lillqvist <tml@iki.fi>
* gutils.c (g_path_is_absolute): Match also UNC paths on Win32.
* gutils.c (g_find_program_in_path): Implement on Win32.
Cygwin support contributed by Stefan Ondrejicka
<ondrej@idata.sk>. Hopefully I got it all in while simultaneously
adding support for auto*/libtool for mingw.
* Makefile.am: Changes for auto* support on Cygwin and Win32. Do
still distribute the hand-written makefiles and *.win32.in files,
though. Use GIO, GSPAWN and PLATFORMDEP macros set by configure.
Use -no-undefined. Pass -export-symbols glib.def to libtool.
* configure.in: Define G_PLATFORM_WIN32 on both pure Win32 (mingw)
and Cygwin. Add AC_CYGWIN, AC_EXEEXT and AC_LIBTOOL_WIN32_DLL
calls for Cygwin and mingw support. Check for %I64u guint64
format (in MS C library). Set G_MODULE_IMPL on mingw and
Cygwin. Use ac_object and ac_exeext. Set GIO, GSPAWN, PLATFORMDEP
and G_LIBS_EXTRA. Compile timeloop only on Unix. Define OS_WIN32
automake conditional on Win32.
* glib.h: Include gwin32.h also on Cygwin.
* gfileutils.c (get_contents_posix): Use O_BINARY (defined as 0 on
Unix) for Cygwin's sake.
* gtimer.c (GETTIME): Reduce #ifdefs, use a macro GETTIME().
* gconvert.c
* gthread.c
* gutf8.c
* gutils.c: For code needed both on Cygwin and native Win32,
test for G_PLATFORM_WIN32.
* gtypes.h: Refine GLIB_VAR definition. Also check for DLL_EXPORT
in case compiling a static library on Win32 or Cygwin.
* gwin32.c: No <direct.h> on Cygwin. No need for ftruncate() or
dirent emulation on Cygwin.
(get_package_directory_from_module) Convert return value from
GetModuleFileName() to POSIX path on Cygwin.
* tests/Makefile.am (progs_LDADD): Link with libglib, libgthread
and libgmodule as appropriate. Use -no-undefined.
* gbacktrace.c: Move #ifdefs around a bit on Win32.
2001-02-21 Tor Lillqvist <tml@iki.fi>
* gshell.c (unquote_string_inplace): Make static.
* gthread.h: Include gtypes.h to be sure to get GLIB_VAR
definition, remove definition from here.
......@@ -97,11 +144,14 @@ Thu Feb 22 10:31:36 2001 Owen Taylor <otaylor@redhat.com>
* Makefile.am (INCLUDES): Add -DGLIB_COMPILATION.
* makefile.mingw.in: Remove install target, Windows isn't Unix.
(DEFINES): Add -DDLL_EXPORT.
* testgdate.c
* testgdateparser.c
* testglib.c: Undefine GLIB_COMPILATION.
* testglib.c: Make some vars static. Add Cygwin path tests.
* glib.def: Updates.
* .cvsignore
......
......@@ -84,7 +84,54 @@ Thu Feb 22 10:31:36 2001 Owen Taylor <otaylor@redhat.com>
2001-02-21 Tor Lillqvist <tml@iki.fi>
* gutils.c (g_path_is_absolute): Match also UNC paths on Win32.
* gutils.c (g_find_program_in_path): Implement on Win32.
Cygwin support contributed by Stefan Ondrejicka
<ondrej@idata.sk>. Hopefully I got it all in while simultaneously
adding support for auto*/libtool for mingw.
* Makefile.am: Changes for auto* support on Cygwin and Win32. Do
still distribute the hand-written makefiles and *.win32.in files,
though. Use GIO, GSPAWN and PLATFORMDEP macros set by configure.
Use -no-undefined. Pass -export-symbols glib.def to libtool.
* configure.in: Define G_PLATFORM_WIN32 on both pure Win32 (mingw)
and Cygwin. Add AC_CYGWIN, AC_EXEEXT and AC_LIBTOOL_WIN32_DLL
calls for Cygwin and mingw support. Check for %I64u guint64
format (in MS C library). Set G_MODULE_IMPL on mingw and
Cygwin. Use ac_object and ac_exeext. Set GIO, GSPAWN, PLATFORMDEP
and G_LIBS_EXTRA. Compile timeloop only on Unix. Define OS_WIN32
automake conditional on Win32.
* glib.h: Include gwin32.h also on Cygwin.
* gfileutils.c (get_contents_posix): Use O_BINARY (defined as 0 on
Unix) for Cygwin's sake.
* gtimer.c (GETTIME): Reduce #ifdefs, use a macro GETTIME().
* gconvert.c
* gthread.c
* gutf8.c
* gutils.c: For code needed both on Cygwin and native Win32,
test for G_PLATFORM_WIN32.
* gtypes.h: Refine GLIB_VAR definition. Also check for DLL_EXPORT
in case compiling a static library on Win32 or Cygwin.
* gwin32.c: No <direct.h> on Cygwin. No need for ftruncate() or
dirent emulation on Cygwin.
(get_package_directory_from_module) Convert return value from
GetModuleFileName() to POSIX path on Cygwin.
* tests/Makefile.am (progs_LDADD): Link with libglib, libgthread
and libgmodule as appropriate. Use -no-undefined.
* gbacktrace.c: Move #ifdefs around a bit on Win32.
2001-02-21 Tor Lillqvist <tml@iki.fi>
* gshell.c (unquote_string_inplace): Make static.
* gthread.h: Include gtypes.h to be sure to get GLIB_VAR
definition, remove definition from here.
......@@ -97,11 +144,14 @@ Thu Feb 22 10:31:36 2001 Owen Taylor <otaylor@redhat.com>
* Makefile.am (INCLUDES): Add -DGLIB_COMPILATION.
* makefile.mingw.in: Remove install target, Windows isn't Unix.
(DEFINES): Add -DDLL_EXPORT.
* testgdate.c
* testgdateparser.c
* testglib.c: Undefine GLIB_COMPILATION.
* testglib.c: Make some vars static. Add Cygwin path tests.
* glib.def: Updates.
* .cvsignore
......
......@@ -18,11 +18,7 @@ EXTRA_DIST = \
glib.def \
makefile.msc.in \
makefile.mingw.in \
giowin32.c \
glibconfig.h.win32.in \
gwin32.c \
gspawn-win32.c \
gspawn-win32-helper.c \
config.h.win32.in \
build-dll \
glib.rc.in \
......@@ -57,7 +53,6 @@ libglib_1_3_la_SOURCES = \
ghash.c \
ghook.c \
giochannel.c \
giounix.c \
glibintl.h \
glist.c \
gmain.c \
......@@ -73,7 +68,6 @@ libglib_1_3_la_SOURCES = \
gscanner.c \
gshell.c \
gslist.c \
gspawn.c \
gstrfuncs.c \
gstring.c \
gthread.c \
......@@ -89,8 +83,12 @@ libglib_1_3_la_SOURCES = \
gunidecomp.c \
gutils.c
## If we decide to link in 'alloca.c', this is how to do it
#libglib_1_3_la_LIBADD = @ALLOCA@
EXTRA_libglib_1_3_la_SOURCES = \
giounix.c \
giowin32.c \
gspawn.c \
gspawn-win32.c \
gwin32.c
glibincludedir=$(includedir)/glib-2.0
glibinclude_HEADERS = \
......@@ -158,18 +156,36 @@ stamp-gc-h: config.status
CONFIG_FILES= CONFIG_HEADERS= CONFIG_OTHER=glibconfig.h ./config.status
echo timestamp > stamp-gc-h
libglib_1_3_la_LIBADD = @ICONV_LIBS@
libglib_1_3_la_LIBADD = @GIO@ @GSPAWN@ @PLATFORMDEP@ @ICONV_LIBS@ @G_LIBS_EXTRA@
libglib_1_3_la_DEPENDENCIES = @GIO@ @GSPAWN@ @PLATFORMDEP@
if PLATFORM_WIN32
no_undefined = -no-undefined
endif
if OS_WIN32
# This requires a very new libtool
export_symbols = -export-symbols glib.def
endif
libglib_1_3_la_LDFLAGS = \
-version-info $(LT_CURRENT):$(LT_REVISION):$(LT_AGE) \
-export-dynamic
noinst_PROGRAMS = testglib testgdate testgdateparser timeloop
-export-dynamic $(no_undefined) $(export_symbols)
if OS_WIN32
bin_PROGRAMS = gspawn-win32-helper
gspawn_win32_helper_LDADD = libglib-1.3.la
endif
if ENABLE_TIMELOOP
timeloop = timeloop
endif
noinst_PROGRAMS = testglib testgdate testgdateparser $(timeloop)
testglib_LDADD = libglib-1.3.la
testgdate_LDADD = libglib-1.3.la
testgdateparser_LDADD = libglib-1.3.la
if ENABLE_TIMELOOP
timeloop_LDADD = libglib-1.3.la
endif
m4datadir = $(datadir)/aclocal
m4data_DATA = glib-2.0.m4
......
......@@ -161,6 +161,9 @@ else
fi
fi
AC_CYGWIN
AC_EXEEXT
# define a MAINT-like variable REBUILD which is set if Perl
# and awk are found, so autogenerated sources can be rebuilt
AC_PROG_AWK
......@@ -194,8 +197,8 @@ AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE,"$GETTEXT_PACKAGE")
GLIB_LOCALE_DIR="${prefix}/${DATADIRNAME}/locale"
AC_DEFINE_UNQUOTED(GLIB_LOCALE_DIR,"$GLIB_LOCALE_DIR")
dnl Initialize libtool
AC_LIBTOOL_WIN32_DLL
AM_PROG_LIBTOOL
if test "x$GCC" = "xyes"; then
......@@ -270,7 +273,7 @@ if test x$ac_cv_sizeof_long_long = x8; then
# long long is a 64 bit integer.
AC_MSG_CHECKING(for format to printf and scanf a gint64)
AC_CACHE_VAL(glib_cv_long_long_format,[
for format in ll q; do
for format in ll q I64; do
AC_TRY_RUN([#include <stdio.h>
int main()
{
......@@ -285,7 +288,7 @@ if test x$ac_cv_sizeof_long_long = x8; then
break)
done])
if test -n "$glib_cv_long_long_format"; then
AC_MSG_RESULT(%${glib_cv_long_long_format}i)
AC_MSG_RESULT(%${glib_cv_long_long_format}u)
else
AC_MSG_RESULT(none)
fi
......@@ -620,6 +623,12 @@ dnl G_MODULE_IMPL= don't reset, so cmd-line can override
G_MODULE_NEED_USCORE=0
G_MODULE_BROKEN_RTLD_GLOBAL=0
G_MODULE_HAVE_DLERROR=0
dnl *** force native WIN32 shared lib loader
if test -z "$G_MODULE_IMPL"; then
case "$host" in
*-*-mingw*|*-*-cygwin*) G_MODULE_IMPL=G_MODULE_IMPL_WIN32 ;;
esac
fi
dnl *** dlopen() and dlsym() in system libraries
if test -z "$G_MODULE_IMPL"; then
AC_CHECK_FUNC(dlopen,
......@@ -724,7 +733,7 @@ dnl *** check whether we need preceeding underscores
[glib_cv_uscore=yes],
[glib_cv_uscore=no],
[])
rm -f plugin.c plugin.o plugin.lo
rm -f plugin.c plugin.$ac_objext plugin.lo
])
if test "x$glib_cv_uscore" = "xyes"; then
G_MODULE_NEED_USCORE=1
......@@ -768,6 +777,89 @@ AC_SUBST(G_MODULE_BROKEN_RTLD_GLOBAL)
AC_SUBST(G_MODULE_NEED_USCORE)
AC_SUBST(GLIB_DEBUG_FLAGS)
dnl **********************
dnl *** g_spawn checks ***
dnl **********************
AC_MSG_CHECKING(for gspawn implementation)
case "$host" in
*-*-mingw*)
GSPAWN=gspawn-win32.lo
;;
*)
GSPAWN=gspawn.lo
;;
esac
AC_MSG_RESULT($GSPAWN)
AC_SUBST(GSPAWN)
dnl *************************
dnl *** GIOChannel checks ***
dnl *************************
AC_MSG_CHECKING(for GIOChannel implementation)
case "$host" in
*-*-mingw*)
GIO=giowin32.lo
;;
*)
GIO=giounix.lo
;;
esac
AC_MSG_RESULT($GIO)
AC_SUBST(GIO)
dnl ****************************************
dnl *** platform dependent source checks ***
dnl ****************************************
AC_MSG_CHECKING(for platform-dependent source)
case "$host" in
*-*-cygwin*|*-*-mingw*)
PLATFORMDEP=gwin32.lo
;;
*)
PLATFORMDEP=
;;
esac
AC_MSG_RESULT($PLATFORMDEP)
AC_SUBST(PLATFORMDEP)
AC_MSG_CHECKING([whether to compile timeloop])
case "$host" in
*-*-cygwin*|*-*-mingw*)
enable_timeloop=no
;;
*)
enable_timeloop=yes
;;
esac
AC_MSG_RESULT($enable_timeloop)
AM_CONDITIONAL(ENABLE_TIMELOOP, test x$enable_timeloop = xyes)
AC_MSG_CHECKING([if building for some Win32 platform])
case "$host" in
*-*-mingw*|*-*-cygwin*)
platform_win32=yes
;;
*)
platform_win32=no
;;
esac
AC_MSG_RESULT($platform_win32)
AM_CONDITIONAL(PLATFORM_WIN32, test x$platform_win32 = xyes)
AC_MSG_CHECKING([if building for pure Win32])
case "$host" in
*-*-mingw*)
os_win32=yes
;;
*)
os_win32=no
;;
esac
AC_MSG_RESULT($os_win32)