Match also UNC paths on Win32.

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

	* gutils.c (g_path_is_absolute): Match also UNC paths on Win32.

	* gthread.h: Include gtypes.h to be sure to get GLIB_VAR
	definition, remove definition from here.

	* gunicode.h: Remove duplicate GLIB_VAR definition from here, too.

	* gutils.c: (Win32) Use USERPROFILE as home dir if present. On
	Win2k, HOMEDRIVE and HOMEPATH aren't reliable.

	* Makefile.am (INCLUDES): Add -DGLIB_COMPILATION.

	* makefile.mingw.in: Remove install target, Windows isn't Unix.

	* testgdate.c
	* testgdateparser.c
	* testglib.c: Undefine GLIB_COMPILATION.

	* glib.def: Updates.

	* .cvsignore
	* */.cvsignore: Ignore also .obj, .dll, .lib and .exe files.
This commit is contained in:
Tor Lillqvist 2001-02-21 12:41:28 +00:00 committed by Tor Lillqvist
parent d1a05f990e
commit cd89e4cca6
31 changed files with 286 additions and 74 deletions

View File

@ -1,4 +1,8 @@
*.lo
*.obj
*.lib
*.dll
*.exe
.deps
.libs
Makefile

View File

@ -1,3 +1,28 @@
2001-02-21 Tor Lillqvist <tml@iki.fi>
* gutils.c (g_path_is_absolute): Match also UNC paths on Win32.
* gthread.h: Include gtypes.h to be sure to get GLIB_VAR
definition, remove definition from here.
* gunicode.h: Remove duplicate GLIB_VAR definition from here, too.
* gutils.c: (Win32) Use USERPROFILE as home dir if present. On
Win2k, HOMEDRIVE and HOMEPATH aren't reliable.
* Makefile.am (INCLUDES): Add -DGLIB_COMPILATION.
* makefile.mingw.in: Remove install target, Windows isn't Unix.
* testgdate.c
* testgdateparser.c
* testglib.c: Undefine GLIB_COMPILATION.
* glib.def: Updates.
* .cvsignore
* */.cvsignore: Ignore also .obj, .dll, .lib and .exe files.
2001-02-19 Hans Breuer <hans@breuer.org>
* glib/glib.def, gobject/gobject.def : added nissing symbols

View File

@ -1,3 +1,28 @@
2001-02-21 Tor Lillqvist <tml@iki.fi>
* gutils.c (g_path_is_absolute): Match also UNC paths on Win32.
* gthread.h: Include gtypes.h to be sure to get GLIB_VAR
definition, remove definition from here.
* gunicode.h: Remove duplicate GLIB_VAR definition from here, too.
* gutils.c: (Win32) Use USERPROFILE as home dir if present. On
Win2k, HOMEDRIVE and HOMEPATH aren't reliable.
* Makefile.am (INCLUDES): Add -DGLIB_COMPILATION.
* makefile.mingw.in: Remove install target, Windows isn't Unix.
* testgdate.c
* testgdateparser.c
* testglib.c: Undefine GLIB_COMPILATION.
* glib.def: Updates.
* .cvsignore
* */.cvsignore: Ignore also .obj, .dll, .lib and .exe files.
2001-02-19 Hans Breuer <hans@breuer.org>
* glib/glib.def, gobject/gobject.def : added nissing symbols

View File

@ -1,3 +1,28 @@
2001-02-21 Tor Lillqvist <tml@iki.fi>
* gutils.c (g_path_is_absolute): Match also UNC paths on Win32.
* gthread.h: Include gtypes.h to be sure to get GLIB_VAR
definition, remove definition from here.
* gunicode.h: Remove duplicate GLIB_VAR definition from here, too.
* gutils.c: (Win32) Use USERPROFILE as home dir if present. On
Win2k, HOMEDRIVE and HOMEPATH aren't reliable.
* Makefile.am (INCLUDES): Add -DGLIB_COMPILATION.
* makefile.mingw.in: Remove install target, Windows isn't Unix.
* testgdate.c
* testgdateparser.c
* testglib.c: Undefine GLIB_COMPILATION.
* glib.def: Updates.
* .cvsignore
* */.cvsignore: Ignore also .obj, .dll, .lib and .exe files.
2001-02-19 Hans Breuer <hans@breuer.org>
* glib/glib.def, gobject/gobject.def : added nissing symbols

View File

@ -1,3 +1,28 @@
2001-02-21 Tor Lillqvist <tml@iki.fi>
* gutils.c (g_path_is_absolute): Match also UNC paths on Win32.
* gthread.h: Include gtypes.h to be sure to get GLIB_VAR
definition, remove definition from here.
* gunicode.h: Remove duplicate GLIB_VAR definition from here, too.
* gutils.c: (Win32) Use USERPROFILE as home dir if present. On
Win2k, HOMEDRIVE and HOMEPATH aren't reliable.
* Makefile.am (INCLUDES): Add -DGLIB_COMPILATION.
* makefile.mingw.in: Remove install target, Windows isn't Unix.
* testgdate.c
* testgdateparser.c
* testglib.c: Undefine GLIB_COMPILATION.
* glib.def: Updates.
* .cvsignore
* */.cvsignore: Ignore also .obj, .dll, .lib and .exe files.
2001-02-19 Hans Breuer <hans@breuer.org>
* glib/glib.def, gobject/gobject.def : added nissing symbols

View File

@ -1,3 +1,28 @@
2001-02-21 Tor Lillqvist <tml@iki.fi>
* gutils.c (g_path_is_absolute): Match also UNC paths on Win32.
* gthread.h: Include gtypes.h to be sure to get GLIB_VAR
definition, remove definition from here.
* gunicode.h: Remove duplicate GLIB_VAR definition from here, too.
* gutils.c: (Win32) Use USERPROFILE as home dir if present. On
Win2k, HOMEDRIVE and HOMEPATH aren't reliable.
* Makefile.am (INCLUDES): Add -DGLIB_COMPILATION.
* makefile.mingw.in: Remove install target, Windows isn't Unix.
* testgdate.c
* testgdateparser.c
* testglib.c: Undefine GLIB_COMPILATION.
* glib.def: Updates.
* .cvsignore
* */.cvsignore: Ignore also .obj, .dll, .lib and .exe files.
2001-02-19 Hans Breuer <hans@breuer.org>
* glib/glib.def, gobject/gobject.def : added nissing symbols

View File

@ -1,3 +1,28 @@
2001-02-21 Tor Lillqvist <tml@iki.fi>
* gutils.c (g_path_is_absolute): Match also UNC paths on Win32.
* gthread.h: Include gtypes.h to be sure to get GLIB_VAR
definition, remove definition from here.
* gunicode.h: Remove duplicate GLIB_VAR definition from here, too.
* gutils.c: (Win32) Use USERPROFILE as home dir if present. On
Win2k, HOMEDRIVE and HOMEPATH aren't reliable.
* Makefile.am (INCLUDES): Add -DGLIB_COMPILATION.
* makefile.mingw.in: Remove install target, Windows isn't Unix.
* testgdate.c
* testgdateparser.c
* testglib.c: Undefine GLIB_COMPILATION.
* glib.def: Updates.
* .cvsignore
* */.cvsignore: Ignore also .obj, .dll, .lib and .exe files.
2001-02-19 Hans Breuer <hans@breuer.org>
* glib/glib.def, gobject/gobject.def : added nissing symbols

View File

@ -1,3 +1,28 @@
2001-02-21 Tor Lillqvist <tml@iki.fi>
* gutils.c (g_path_is_absolute): Match also UNC paths on Win32.
* gthread.h: Include gtypes.h to be sure to get GLIB_VAR
definition, remove definition from here.
* gunicode.h: Remove duplicate GLIB_VAR definition from here, too.
* gutils.c: (Win32) Use USERPROFILE as home dir if present. On
Win2k, HOMEDRIVE and HOMEPATH aren't reliable.
* Makefile.am (INCLUDES): Add -DGLIB_COMPILATION.
* makefile.mingw.in: Remove install target, Windows isn't Unix.
* testgdate.c
* testgdateparser.c
* testglib.c: Undefine GLIB_COMPILATION.
* glib.def: Updates.
* .cvsignore
* */.cvsignore: Ignore also .obj, .dll, .lib and .exe files.
2001-02-19 Hans Breuer <hans@breuer.org>
* glib/glib.def, gobject/gobject.def : added nissing symbols

View File

@ -1,3 +1,28 @@
2001-02-21 Tor Lillqvist <tml@iki.fi>
* gutils.c (g_path_is_absolute): Match also UNC paths on Win32.
* gthread.h: Include gtypes.h to be sure to get GLIB_VAR
definition, remove definition from here.
* gunicode.h: Remove duplicate GLIB_VAR definition from here, too.
* gutils.c: (Win32) Use USERPROFILE as home dir if present. On
Win2k, HOMEDRIVE and HOMEPATH aren't reliable.
* Makefile.am (INCLUDES): Add -DGLIB_COMPILATION.
* makefile.mingw.in: Remove install target, Windows isn't Unix.
* testgdate.c
* testgdateparser.c
* testglib.c: Undefine GLIB_COMPILATION.
* glib.def: Updates.
* .cvsignore
* */.cvsignore: Ignore also .obj, .dll, .lib and .exe files.
2001-02-19 Hans Breuer <hans@breuer.org>
* glib/glib.def, gobject/gobject.def : added nissing symbols

View File

@ -5,7 +5,7 @@ AUTOMAKE_OPTIONS = 1.4
SUBDIRS = . gobject gmodule gthread docs tests build
INCLUDES = -DG_LOG_DOMAIN=g_log_domain_glib @GLIB_DEBUG_FLAGS@ \
-DG_DISABLE_COMPAT_H
-DG_DISABLE_COMPAT_H -DGLIB_COMPILATION
EXTRA_DIST = \
ChangeLog.pre-1-2 \

View File

@ -456,12 +456,17 @@ EXPORTS
g_spawn_error_quark
g_spawn_sync
g_static_mutex_get_mutex_impl
g_static_private_free
g_static_private_get
g_static_private_init
g_static_private_set
g_static_rec_mutex_free
g_static_rec_mutex_init
g_static_rec_mutex_lock
g_static_rec_mutex_trylock
g_static_rec_mutex_unlock
g_static_rw_lock_free
g_static_rw_lock_init
g_static_rw_lock_reader_lock
g_static_rw_lock_reader_trylock
g_static_rw_lock_reader_unlock

View File

@ -5,7 +5,7 @@ AUTOMAKE_OPTIONS = 1.4
SUBDIRS = . gobject gmodule gthread docs tests build
INCLUDES = -DG_LOG_DOMAIN=g_log_domain_glib @GLIB_DEBUG_FLAGS@ \
-DG_DISABLE_COMPAT_H
-DG_DISABLE_COMPAT_H -DGLIB_COMPILATION
EXTRA_DIST = \
ChangeLog.pre-1-2 \

View File

@ -456,12 +456,17 @@ EXPORTS
g_spawn_error_quark
g_spawn_sync
g_static_mutex_get_mutex_impl
g_static_private_free
g_static_private_get
g_static_private_init
g_static_private_set
g_static_rec_mutex_free
g_static_rec_mutex_init
g_static_rec_mutex_lock
g_static_rec_mutex_trylock
g_static_rec_mutex_unlock
g_static_rw_lock_free
g_static_rw_lock_init
g_static_rw_lock_reader_lock
g_static_rw_lock_reader_trylock
g_static_rw_lock_reader_unlock

View File

@ -28,21 +28,10 @@
#define __G_THREAD_H__
#include <gerror.h>
#include <gtypes.h>
G_BEGIN_DECLS
#ifndef GLIB_VAR
# ifdef G_OS_WIN32
# ifdef GLIB_COMPILATION
# define GLIB_VAR __declspec(dllexport)
# else /* !GLIB_COMPILATION */
# define GLIB_VAR extern __declspec(dllimport)
# endif /* !GLIB_COMPILATION */
# else /* !G_OS_WIN32 */
# define GLIB_VAR extern
# endif /* !G_OS_WIN32 */
#endif /* GLIB_VAR */
/* GLib Thread support
*/

View File

@ -163,18 +163,6 @@ gunichar *g_unicode_canonical_decomposition (gunichar ch,
* We prefix variable declarations so they can
* properly get exported in windows dlls.
*/
#ifndef GLIB_VAR
# ifdef G_OS_WIN32
# ifdef GLIB_COMPILATION
# define GLIB_VAR __declspec(dllexport)
# else /* !GLIB_COMPILATION */
# define GLIB_VAR extern __declspec(dllimport)
# endif /* !GLIB_COMPILATION */
# else /* !G_OS_WIN32 */
# define GLIB_VAR extern
# endif /* !G_OS_WIN32 */
#endif /* !GLIB_VAR */
GLIB_VAR char g_utf8_skip[256];
#define g_utf8_next_char(p) (char *)((p) + g_utf8_skip[*(guchar *)(p)])

View File

@ -461,6 +461,9 @@ g_path_is_absolute (const gchar *file_name)
#ifdef G_OS_WIN32
if (isalpha (file_name[0]) && file_name[1] == ':' && file_name[2] == G_DIR_SEPARATOR)
return TRUE;
if (file_name[0] == G_DIR_SEPARATOR && file_name[1] == G_DIR_SEPARATOR)
return TRUE;
#endif
return FALSE;
@ -727,11 +730,20 @@ g_get_any_init (void)
while ((p = strchr (g_home_dir, '/')) != NULL)
*p = '\\';
}
else
if (!g_home_dir)
{
/* The official way to specify a home directory on NT is
* the HOMEDRIVE and HOMEPATH environment variables. At least
* it was at some time.
/* USERPROFILE is probably the closest equivalent to $HOME? */
if (getenv ("USERPROFILE") != NULL)
g_home_dir = g_getenv ("USERPROFILE");
}
if (!g_home_dir)
{
/* At least at some time, HOMEDRIVE and HOMEPATH were used
* to point to the home directory, I think. But on Windows
* 2000 HOMEDRIVE seems to be equal to SYSTEMDRIVE, and
* HOMEPATH is its root "\"?
*/
if (getenv ("HOMEDRIVE") != NULL && getenv ("HOMEPATH") != NULL)
{

View File

@ -3,10 +3,6 @@
## Use: make -f makefile.mingw
# Change this to wherever you want to install the DLLs. This directory
# should be in your PATH.
BIN = /bin
TOP = ..
include build/win32/make.mingw
@ -23,7 +19,7 @@ DEFINES = -DHAVE_CONFIG_H -DGLIB_COMPILATION -DG_LOG_DOMAIN=g_log_domain_glib -D
DEPCFLAGS = $(INTL_CFLAGS) $(LIBICONV_CFLAGS)
DLLS_TO_BUILD = \
glib-$(GLIB_VER).dll \
glib-$(GLIB_VER).dll \
sub-gmodule \
sub-gthread \
sub-gobject
@ -37,9 +33,6 @@ all : \
testgdate.exe \
testgdateparser.exe
install : all
$(INSTALL) $(DLLS_TO_BUILD) $(BIN)
glib_OBJECTS = \
garray.o \
gasyncqueue.o \

View File

@ -1,4 +1,7 @@
*.lo
*.obj
*.lib
*.dll
Makefile
Makefile.in
makefile.msc

View File

@ -1,4 +1,8 @@
*.lo
*.obj
*.lib
*.dll
*.exe
Makefile
Makefile.in
makefile.msc

View File

@ -28,21 +28,10 @@
#define __G_THREAD_H__
#include <gerror.h>
#include <gtypes.h>
G_BEGIN_DECLS
#ifndef GLIB_VAR
# ifdef G_OS_WIN32
# ifdef GLIB_COMPILATION
# define GLIB_VAR __declspec(dllexport)
# else /* !GLIB_COMPILATION */
# define GLIB_VAR extern __declspec(dllimport)
# endif /* !GLIB_COMPILATION */
# else /* !G_OS_WIN32 */
# define GLIB_VAR extern
# endif /* !G_OS_WIN32 */
#endif /* GLIB_VAR */
/* GLib Thread support
*/

View File

@ -5,6 +5,9 @@ Makefile
.deps
*.lo
*.o
*.obj
*.lib
*.dll
.libs
*.la
so_locations

View File

@ -163,18 +163,6 @@ gunichar *g_unicode_canonical_decomposition (gunichar ch,
* We prefix variable declarations so they can
* properly get exported in windows dlls.
*/
#ifndef GLIB_VAR
# ifdef G_OS_WIN32
# ifdef GLIB_COMPILATION
# define GLIB_VAR __declspec(dllexport)
# else /* !GLIB_COMPILATION */
# define GLIB_VAR extern __declspec(dllimport)
# endif /* !GLIB_COMPILATION */
# else /* !G_OS_WIN32 */
# define GLIB_VAR extern
# endif /* !G_OS_WIN32 */
#endif /* !GLIB_VAR */
GLIB_VAR char g_utf8_skip[256];
#define g_utf8_next_char(p) (char *)((p) + g_utf8_skip[*(guchar *)(p)])

View File

@ -461,6 +461,9 @@ g_path_is_absolute (const gchar *file_name)
#ifdef G_OS_WIN32
if (isalpha (file_name[0]) && file_name[1] == ':' && file_name[2] == G_DIR_SEPARATOR)
return TRUE;
if (file_name[0] == G_DIR_SEPARATOR && file_name[1] == G_DIR_SEPARATOR)
return TRUE;
#endif
return FALSE;
@ -727,11 +730,20 @@ g_get_any_init (void)
while ((p = strchr (g_home_dir, '/')) != NULL)
*p = '\\';
}
else
if (!g_home_dir)
{
/* The official way to specify a home directory on NT is
* the HOMEDRIVE and HOMEPATH environment variables. At least
* it was at some time.
/* USERPROFILE is probably the closest equivalent to $HOME? */
if (getenv ("USERPROFILE") != NULL)
g_home_dir = g_getenv ("USERPROFILE");
}
if (!g_home_dir)
{
/* At least at some time, HOMEDRIVE and HOMEPATH were used
* to point to the home directory, I think. But on Windows
* 2000 HOMEDRIVE seems to be equal to SYSTEMDRIVE, and
* HOMEPATH is its root "\"?
*/
if (getenv ("HOMEDRIVE") != NULL && getenv ("HOMEPATH") != NULL)
{

View File

@ -3,10 +3,6 @@
## Use: make -f makefile.mingw
# Change this to wherever you want to install the DLLs. This directory
# should be in your PATH.
BIN = /bin
TOP = ..
include build/win32/make.mingw
@ -23,7 +19,7 @@ DEFINES = -DHAVE_CONFIG_H -DGLIB_COMPILATION -DG_LOG_DOMAIN=g_log_domain_glib -D
DEPCFLAGS = $(INTL_CFLAGS) $(LIBICONV_CFLAGS)
DLLS_TO_BUILD = \
glib-$(GLIB_VER).dll \
glib-$(GLIB_VER).dll \
sub-gmodule \
sub-gthread \
sub-gobject
@ -37,9 +33,6 @@ all : \
testgdate.exe \
testgdateparser.exe
install : all
$(INSTALL) $(DLLS_TO_BUILD) $(BIN)
glib_OBJECTS = \
garray.o \
gasyncqueue.o \

View File

@ -1,3 +1,6 @@
#ifdef GLIB_COMPILATION
#undef GLIB_COMPILATION
#endif
#include "glib.h"

View File

@ -1,3 +1,6 @@
#ifdef GLIB_COMPILATION
#undef GLIB_COMPILATION
#endif
#include "glib.h"

View File

@ -28,6 +28,10 @@
#undef G_LOG_DOMAIN
#ifdef GLIB_COMPILATION
#undef GLIB_COMPILATION
#endif
#include <stdio.h>
#include <string.h>
#include <errno.h>

View File

@ -1,4 +1,8 @@
*.lo
*.obj
*.lib
*.dll
*.exe
.deps
.libs
Makefile

View File

@ -1,3 +1,6 @@
#ifdef GLIB_COMPILATION
#undef GLIB_COMPILATION
#endif
#include "glib.h"

View File

@ -1,3 +1,6 @@
#ifdef GLIB_COMPILATION
#undef GLIB_COMPILATION
#endif
#include "glib.h"

View File

@ -28,6 +28,10 @@
#undef G_LOG_DOMAIN
#ifdef GLIB_COMPILATION
#undef GLIB_COMPILATION
#endif
#include <stdio.h>
#include <string.h>
#include <errno.h>