ICU-2705 Fixes for CygWin/MSVC configuration
X-SVN-Rev: 11075
This commit is contained in:
parent
3670030ff7
commit
cd9de6d966
@ -3,7 +3,7 @@
|
||||
## Copyright (c) 2001, International Business Machines Corporation and
|
||||
## others. All Rights Reserved.
|
||||
##
|
||||
## $Id: mh-cygwin,v 1.7 2003/02/11 00:13:03 grhoten-oss Exp $
|
||||
## $Id: mh-cygwin,v 1.8 2003/02/17 17:48:50 grhoten-oss Exp $
|
||||
|
||||
## Commands to generate dependency files
|
||||
GEN_DEPS.c= $(CC) -E -MM $(DEFS) $(CPPFLAGS)
|
||||
@ -32,7 +32,7 @@ LD_SONAME = -Wl,-soname -Wl,$(MIDDLE_SO_TARGET)
|
||||
## Shared object suffix
|
||||
SO = dll
|
||||
## Non-shared intermediate object suffix
|
||||
STATIC_O = lib
|
||||
STATIC_O = o
|
||||
#LIBICU = $(ICUPREFIX)
|
||||
|
||||
## Link commands to link to ICU libs
|
||||
|
@ -3,7 +3,7 @@
|
||||
## Copyright (c) 2001, International Business Machines Corporation and
|
||||
## others. All Rights Reserved.
|
||||
##
|
||||
## $Id: mh-cygwin-msvc,v 1.1 2003/02/11 00:13:48 grhoten-oss Exp $
|
||||
## $Id: mh-cygwin-msvc,v 1.2 2003/02/17 17:48:50 grhoten-oss Exp $
|
||||
|
||||
## Commands to generate dependency files
|
||||
GEN_DEPS.c= :
|
||||
@ -23,16 +23,16 @@ DEFS+=/D"WIN32"
|
||||
LDFLAGS+=/nologo
|
||||
|
||||
# Commands to compile
|
||||
COMPILE.c= $(CC) $(CPPFLAGS) $(DEFS) $(CFLAGS) /c
|
||||
COMPILE.cc= $(CXX) $(CPPFLAGS) $(DEFS) $(CXXFLAGS) /c
|
||||
COMPILE.c= $(CC) $(CPPFLAGS) $(DEFS) $(CFLAGS) /GF /c
|
||||
COMPILE.cc= $(CXX) $(CPPFLAGS) $(DEFS) $(CXXFLAGS) /GF /c
|
||||
|
||||
# Commands to link
|
||||
LINK.c= LINK.EXE /subsystem:console $(CFLAGS) $(LDFLAGS)
|
||||
LINK.cc= LINK.EXE /subsystem:console $(CXXFLAGS) $(LDFLAGS)
|
||||
LINK.c= LINK.EXE /subsystem:console $(LDFLAGS)
|
||||
LINK.cc= LINK.EXE /subsystem:console $(LDFLAGS)
|
||||
|
||||
## Commands to make a shared library
|
||||
SHLIB.c= LINK.EXE /DLL $(CFLAGS) $(LDFLAGS)
|
||||
SHLIB.cc= LINK.EXE /DLL $(CXXFLAGS) $(LDFLAGS)
|
||||
SHLIB.c= LINK.EXE /DLL $(LDFLAGS)
|
||||
SHLIB.cc= LINK.EXE /DLL $(LDFLAGS)
|
||||
|
||||
## Compiler switch to embed a runtime search path
|
||||
LD_RPATH=
|
||||
@ -44,7 +44,7 @@ LD_SONAME =
|
||||
## Shared object suffix
|
||||
SO = dll
|
||||
## Non-shared intermediate object suffix
|
||||
STATIC_O = lib
|
||||
STATIC_O = o
|
||||
# OUTOPT is for creating a specific output name
|
||||
OUTOPT = /out:
|
||||
|
||||
@ -97,6 +97,10 @@ LIBUSTDIO= $(top_builddir)/extra/ustdio/libustdio$(ICULIBSUFFIX)$(SO_TARGET_VERS
|
||||
@echo "generating dependency information for $<"
|
||||
@$(GEN_DEPS.cc) $< > $@
|
||||
|
||||
## Compile a Windows resource file
|
||||
%.res : $(srcdir)/%.rc
|
||||
@rc.exe /fo$@ $<
|
||||
|
||||
## Versioned target for a shared library.
|
||||
FINAL_SO_TARGET= $(basename $(SO_TARGET))$(SO_TARGET_VERSION_MAJOR)$(ICULIBSUFFIX).$(SO)
|
||||
MIDDLE_SO_TARGET=
|
||||
|
@ -30,6 +30,7 @@ LINK = $(LINK.c)
|
||||
endif
|
||||
|
||||
BUILDDIR := $(shell pwd)/../../
|
||||
BUILDDIR := $(BUILDDIR:test/cintltst/../../=)
|
||||
|
||||
# we define ICU_UNICODE_VERSION so we can test it
|
||||
CPPFLAGS += -I$(top_builddir)/common -I$(top_srcdir)/common -I$(top_srcdir)/i18n -I$(top_srcdir)/tools/ctestfw -I$(top_srcdir)/tools/toolutil
|
||||
|
@ -20,6 +20,8 @@ CLEANFILES = *~ $(DEPS)
|
||||
TARGET = intltest$(EXEEXT)
|
||||
|
||||
BUILDDIR := $(shell pwd)/../../
|
||||
BUILDDIR := $(BUILDDIR:test/intltest/../../=)
|
||||
|
||||
CPPFLAGS += -I$(top_builddir)/common -I$(top_srcdir)/common -I$(top_srcdir)/i18n -I$(top_srcdir)/tools/toolutil
|
||||
DEFS += -D'U_TOPSRCDIR="$(top_srcdir)/"' -D'U_TOPBUILDDIR="$(BUILDDIR)"'
|
||||
LIBS = $(LIBICUI18N) $(LIBICUUC) $(LIBICUTOOLUTIL) $(DEFAULT_LIBS) $(LIB_M)
|
||||
|
@ -61,6 +61,15 @@ findBasename(const char *filename) {
|
||||
if(basename!=NULL) {
|
||||
return basename+1;
|
||||
} else {
|
||||
#ifdef WIN32
|
||||
/* Use lenient matching on Windows, which can accept either \ or /
|
||||
This is useful for CygWin environments which has both
|
||||
*/
|
||||
basename=uprv_strrchr(filename, '/');
|
||||
if(basename!=NULL) {
|
||||
return basename+1;
|
||||
}
|
||||
#endif
|
||||
return filename;
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user