aboutsummaryrefslogtreecommitdiff
path: root/nx-X11/lib/X11/xlibi18n/Xi18nLib.conf
blob: d2abd0d1aaa4173c2aad3eb0f9f8892dd56d4987 (plain)
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

#define DoNormalLib NO
#define DoSharedLib YES
#define DoDebugLib DebugLibX11
#define DoProfileLib ProfileLibX11
#define PassCDebugFlags CDEBUGFLAGS="$(CDEBUGFLAGS)"

#include <Threads.tmpl>

     SOXI18NREV = 2
     POSTLOCALE = common
#if defined (LibDirName)
     POSTLOCALELIB = LibDirName
#else
     POSTLOCALELIB = lib
#endif

#if Malloc0ReturnsNull
     MALLOC_DEFINES = -DMALLOC_0_RETURNS_NULL
#endif
#if NeedLibInsideFlag
    LIB_DEFINES = -D_XLIBINT_
#endif

DYNAMIC_DEFINES = -DDYNAMIC_LOAD
        DEFINES = $(MALLOC_DEFINES) $(LIB_DEFINES) $(SUNSOFT_DEFINES)

#include <Library.tmpl>

#if defined(HPArchitecture) && OSMajorVersion > 9
    EXTRA_SHLIBLDFLAGS = +s +b $(USRLIBDIR)
#else
    EXTRA_SHLIBLDFLAGS = 
#endif

#if defined(SparcArchitecture)
#if defined(HasSunC) && HasSunC
CFLAGS += -xregs=no%appl
#endif
#if HasGcc
CFLAGS += -mno-app-regs
#endif
#endif

all::
	$(_NULLCMD_)
.c.o:
	$(_NULLCMD_)
	$(_NULLCMD_)
	$(_NULLCMD_)
	$(RM) $@
	$(CC) -c $(CFLAGS) $(_NOOP_) $(SHLIBDEF) $(SHAREDCODEDEF) $(PICFLAGS) $*.c

clean::
	rm -rf *.so.$(SOXI18NREV)

lint::
	$(LINT) $(LINTFLAGS) $(SRCS) $(LINTLIBS)

#ifndef BuildI18NTop
# define BuildI18NTop $(BUILDLIBTOP)/../../..
#endif

BUILDI18NTOP = BuildI18NTop

#ifndef LinkBuildXi18nLibrary
# ifdef UseInstalled
#  define LinkBuildXi18nLibrary(libname,rev) 
# else
#  define LinkBuildXi18nLibrary(libname,rev)				@@\
AllTarget(AllTarget(Concat(lib,libname.so.rev)))			@@\
	MakeDir($(BUILDI18NDIR)/$(POSTLOCALELIB)/$(POSTLOCALE))	@@\
	RemoveFile($(BUILDI18NDIR)/$(POSTLOCALELIB)/$(POSTLOCALE)/libname.so.$(SOXI18NREV))	@@\
	cd $(BUILDI18NDIR)/$(POSTLOCALELIB)/$(POSTLOCALE) && $(LN) $(BUILDI18NTOP)/$(CURRENT_DIR)/Concat(lib,libname.so.rev) ./libname.so.rev
# endif
#endif

#ifndef Xi18nLibraryTarget
# if 0 /* !CrossCompiling */
#  define	Xi18nLibraryTarget(libname)		@@\
all:: libname.so.$(SOXI18NREV)			@@\
libname.so.$(SOXI18NREV): $(OBJS)		@@\
	$(RM) $@~				@@\
	(cd .; T=`echo $@ | sed 's/\.[^\.]*$$//'`; $(LD) -o ./$@~ $(SHLIBLDFLAGS) $(OBJS) $(REQUIREDLIBS) $(EXTRA_SHLIBLDFLAGS); $(RM) $$T && $(LN) $@ $$T) @@\
	$(RM) $@				@@\
	$(MV) $@~ $@				@@\
install:: libname.so.$(SOXI18NREV)		@@\
	@if [ -d $(DESTDIR)$(XLOCALEDIR)/$(POSTLOCALELIB)/$(POSTLOCALE) ]; then set +x; \ @@\
	else (set -x; $(MKDIRHIER) $(DESTDIR)$(XLOCALEDIR)/$(POSTLOCALELIB)/$(POSTLOCALE)); fi @@\
	$(RM) $(DESTDIR)$(XLOCALEDIR)/$(POSTLOCALELIB)/$(POSTLOCALE)/libname.so.$(SOXI18NREV)	@@\
	$(INSTALL) $(INSTALLFLAGS) $(INSTLIBFLAGS) libname.so.$(SOXI18NREV) $(DESTDIR)$(XLOCALEDIR)/$(POSTLOCALELIB)/$(POSTLOCALE)
# else
#  define Xi18nLibraryTarget(libname)				@@\
DependTarget()							@@\
SharedLibraryTarget(libname,$(SOXI18NREV),$(OBJS),.,.)		@@\
LinkBuildXi18nLibrary(libname,$(SOXI18NREV))			@@\
install:: Concat(lib,libname.so.$(SOXI18NREV))			@@\
	MakeDir($(DESTDIR)$(XLOCALEDIR)/$(POSTLOCALELIB)/$(POSTLOCALE))		@@\
	$(RM) $(DESTDIR)$(XLOCALEDIR)/$(POSTLOCALELIB)/$(POSTLOCALE)/libname.so.$(SOXI18NREV)	@@\
	$(INSTALL) $(INSTALLFLAGS) $(INSTLIBFLAGS) Concat(lib,libname.so.$(SOXI18NREV)) $(DESTDIR)$(XLOCALEDIR)/$(POSTLOCALELIB)/$(POSTLOCALE)/libname.so.$(SOXI18NREV)

# endif
#endif