DXR is a code search and navigation tool aimed at making sense of large projects. It supports full-text and regex searches as well as structural queries.

Untracked file

Line Code
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170
#
# The contents of this file are subject to the Netscape Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/NPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is mozilla.org code.
#
# The Initial Developer of the Original Code is Netscape
# Communications Corporation.  Portions created by Netscape are
# Copyright (C) 1998 Netscape Communications Corporation. All
# Rights Reserved.
#
# Contributor(s): 
#

DEPTH		= ../../..
topsrcdir	= @top_srcdir@
srcdir		= @srcdir@
VPATH		= @srcdir@

include $(DEPTH)/config/autoconf.mk

MODULE		= uconv
LIBRARY_NAME	= uconv
EXPORT_LIBRARY  = 1
IS_COMPONENT	= 1
MODULE_NAME	= nsUConvModule
GRE_MODULE	= 1

ifneq ($(OS_ARCH),WINNT)
# To avoid conflict with OS/2 system uconv.dll
SHORT_LIBNAME  = mozuconv
endif

PACKAGE_FILE = uconv.pkg

REQUIRES	= xpcom \
		  string \
		  intl \
		  locale \
		  unicharutil \
		  chardet \
		  ucnative \
		  $(NULL)

CSRCS		= \
		ugen.c \
		uscan.c \
		umap.c \
		$(NULL)

CPPSRCS		= \
		nsUConvModule.cpp \
		nsCharsetAliasImp.cpp \
		nsConverterInputStream.cpp \
		nsTextToSubURI.cpp \
		nsURLProperties.cpp \
		nsCharsetConverterManager.cpp \
		nsUTF8ConverterService.cpp \
		$(NULL)

ifndef MOZ_USE_NATIVE_UCONV
CPPSRCS         += \
		nsScriptableUConv.cpp \
		nsUnicodeDecodeHelper.cpp \
		nsUnicodeEncodeHelper.cpp \
		nsMappingCache.cpp \
		nsISO88591ToUnicode.cpp \
		nsCP1252ToUnicode.cpp \
		nsMacRomanToUnicode.cpp \
		nsUTF8ToUnicode.cpp \
		nsUnicodeToISO88591.cpp \
		nsUnicodeToCP1252.cpp \
		nsUnicodeToMacRoman.cpp \
		nsUnicodeToUTF8.cpp \
		$(NULL)
endif

EXPORT_RESOURCE	= \
		charsetalias.properties \
		charsetData.properties \
		$(NULL)

ifeq ($(MOZ_WIDGET_TOOLKIT),os2)
CPPSRCS			+= nsOS2Charset.cpp
EXPORT_RESOURCE		+= os2charset.properties
else
ifeq ($(MOZ_WIDGET_TOOLKIT),windows)
CPPSRCS			+= nsWinCharset.cpp
EXPORT_RESOURCE		+= wincharset.properties
else
ifneq (,$(filter cocoa mac, $(MOZ_WIDGET_TOOLKIT)))
CPPSRCS			+= nsMacCharset.cpp
EXPORT_RESOURCE		+= maccharset.properties
else
ifeq ($(OS_ARCH),BeOS)
CPPSRCS			+= nsBeOSCharset.cpp
else
CPPSRCS			+= nsUNIXCharset.cpp
EXPORT_RESOURCE		+= unixcharset.properties
# add platform charset remapping properties files here if necessary
# (see unixcharset.sample.properties for an example file)
# eg: if we needed a charset remap for OSARCH=Linux then add the following line:
#EXPORT_RESOURCE		+= unixcharset.Linux.properties
endif
endif
endif
endif

EXTRA_DSO_LDOPTS = \
		$(DIST)/lib/$(LIB_PREFIX)ucvutil_s.$(LIB_SUFFIX) \
		$(MOZ_UNICHARUTIL_LIBS) \
		$(MOZ_NECKO_UTIL_LIBS) \
		$(MOZ_COMPONENT_LIBS) \
		$(NULL)

LOCAL_INCLUDES	= -I$(srcdir)/../util

ifneq (,$(filter cocoa mac, $(MOZ_WIDGET_TOOLKIT)))
EXTRA_DSO_LDOPTS += $(TK_LIBS)
endif

LOCAL_INCLUDES	= -I$(srcdir)/../util \
		  -I$(srcdir)/../ucvlatin \
		  -I$(srcdir)/../ucvibm \
		  -I$(srcdir)/../ucvja \
		  -I$(srcdir)/../ucvtw2 \
		  -I$(srcdir)/../ucvtw \
		  -I$(srcdir)/../ucvko \
		  -I$(srcdir)/../ucvcn \
		  -I$(srcdir)/../native \
		  $(NULL)

ifndef MOZ_USE_NATIVE_UCONV
SHARED_LIBRARY_LIBS += \
	$(DIST)/lib/$(LIB_PREFIX)ucvlatin_s.$(LIB_SUFFIX) \
	$(DIST)/lib/$(LIB_PREFIX)ucvibm_s.$(LIB_SUFFIX) \
	$(DIST)/lib/$(LIB_PREFIX)ucvja_s.$(LIB_SUFFIX) \
	$(DIST)/lib/$(LIB_PREFIX)ucvtw2_s.$(LIB_SUFFIX) \
	$(DIST)/lib/$(LIB_PREFIX)ucvtw_s.$(LIB_SUFFIX) \
	$(DIST)/lib/$(LIB_PREFIX)ucvko_s.$(LIB_SUFFIX) \
	$(DIST)/lib/$(LIB_PREFIX)ucvcn_s.$(LIB_SUFFIX) \
	$(NULL)
else
SHARED_LIBRARY_LIBS += \
	$(DIST)/lib/$(LIB_PREFIX)ucnative_s.$(LIB_SUFFIX) \
	$(NULL)
endif

include $(topsrcdir)/config/rules.mk

# CODESET is not automatically defined on some older versions of Redhat.
# Define _XOPEN_SOURCE so CODESET will get defined and thus allow 
# nl_langinfo(CODESET) to compile on these systems.
ifeq ($(OS_ARCH), Linux)
DEFINES         += -D_XOPEN_SOURCE=500
endif

libs:: $(EXPORT_RESOURCE)
	$(INSTALL) $^ $(DIST)/bin/res

install:: $(EXPORT_RESOURCE)
	$(SYSINSTALL) $(IFLAGS1) $^ $(DESTDIR)$(mozappdir)/res