1#*************************************************************************
2#
3# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4#
5# Copyright 2000, 2010 Oracle and/or its affiliates.
6#
7# OpenOffice.org - a multi-platform office productivity suite
8#
9# This file is part of OpenOffice.org.
10#
11# OpenOffice.org is free software: you can redistribute it and/or modify
12# it under the terms of the GNU Lesser General Public License version 3
13# only, as published by the Free Software Foundation.
14#
15# OpenOffice.org is distributed in the hope that it will be useful,
16# but WITHOUT ANY WARRANTY; without even the implied warranty of
17# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
18# GNU Lesser General Public License version 3 for more details
19# (a copy is included in the LICENSE file that accompanied this code).
20#
21# You should have received a copy of the GNU Lesser General Public License
22# version 3 along with OpenOffice.org.  If not, see
23# <http://www.openoffice.org/license.html>
24# for a copy of the LGPLv3 License.
25#
26#*************************************************************************
27
28PRJ=..$/..$/..
29PRJNAME=sal
30TARGET=uwinapi
31
32USE_DEFFILE=TRUE
33LIBTARGET=NO
34
35# --- Settings ----------------------------------
36
37.INCLUDE : settings.mk
38
39CFLAGS+= $(LFS_CFLAGS)
40CXXFLAGS+= $(LFS_CFLAGS)
41
42# --- Targets ----------------------------------
43
44
45.IF "$(GUI)"=="WNT"
46.IF "$(COM)"=="GCC"
47CFLAGSCXX+=-Wno-unused-parameter -Wno-return-type
48.ENDIF
49
50.IF "$(COMEX)"=="9"
51.IF "$(PSDK_HOME)"!=""
52# Since the 02/2003 PSDK the "new" linker is needed here.
53LINK=$(WRAPCMD) "$(PSDK_HOME)$/Bin$/Win64$/LINK.EXE"
54.ENDIF
55.ENDIF
56
57SLOFILES=\
58		$(SLO)$/CheckTokenMembership.obj\
59		$(SLO)$/CommandLineToArgvW.obj\
60		$(SLO)$/CopyFileExA.obj\
61		$(SLO)$/CopyFileExW.obj\
62		$(SLO)$/DrawStateW.obj\
63		$(SLO)$/EnumProcesses.obj\
64		$(SLO)$/GetLogicalDriveStringsW.obj\
65		$(SLO)$/GetLongPathNameA.obj\
66		$(SLO)$/GetLongPathNameW.obj\
67		$(SLO)$/GetModuleFileNameExA.obj\
68		$(SLO)$/GetModuleFileNameExW.obj\
69		$(SLO)$/GetProcessId.obj\
70		$(SLO)$/GetUserDefaultUILanguage.obj\
71		$(SLO)$/GetUserDomainA.obj\
72		$(SLO)$/GetUserDomainW.obj\
73		$(SLO)$/GetDiskFreeSpaceExA.obj\
74		$(SLO)$/GetDiskFreeSpaceExW.obj\
75		$(SLO)$/MoveFileExA.obj\
76		$(SLO)$/MoveFileExW.obj\
77		$(SLO)$/toolhelp.obj\
78		$(SLO)$/DllGetVersion.obj\
79		$(SLO)$/DllMain.obj\
80		$(SLO)$/ResolveThunk.obj\
81		$(SLO)$/ResolveUnicows.obj\
82		$(SLO)$/snprintf.obj\
83		$(SLO)$/snwprintf.obj\
84		$(SLO)$/FindFirstVolumeA.obj\
85		$(SLO)$/FindFirstVolumeW.obj\
86		$(SLO)$/FindNextVolumeA.obj\
87		$(SLO)$/FindNextVolumeW.obj\
88		$(SLO)$/FindVolumeClose.obj\
89		$(SLO)$/FindFirstVolumeMountPointA.obj\
90		$(SLO)$/FindFirstVolumeMountPointW.obj\
91		$(SLO)$/FindNextVolumeMountPointA.obj\
92		$(SLO)$/FindNextVolumeMountPointW.obj\
93		$(SLO)$/FindVolumeMountPointClose.obj\
94		$(SLO)$/GetVolumeNameForVolumeMountPointA.obj\
95		$(SLO)$/GetVolumeNameForVolumeMountPointW.obj\
96		$(SLO)$/DeleteVolumeMountPointA.obj\
97		$(SLO)$/DeleteVolumeMountPointW.obj\
98		$(SLO)$/GetVolumePathNameA.obj\
99		$(SLO)$/GetVolumePathNameW.obj\
100		$(SLO)$/SetVolumeMountPointA.obj\
101		$(SLO)$/SetVolumeMountPointW.obj\
102		$(SLO)$/PathAddBackslashW.obj\
103		$(SLO)$/PathCompactPathExW.obj\
104		$(SLO)$/PathFileExistsW.obj\
105		$(SLO)$/PathFindExtensionW.obj\
106		$(SLO)$/PathFindFileNameW.obj\
107		$(SLO)$/PathIsFileSpecW.obj\
108		$(SLO)$/PathIsUNCW.obj\
109		$(SLO)$/PathRemoveExtensionW.obj\
110		$(SLO)$/PathRemoveFileSpecW.obj\
111		$(SLO)$/PathSetDlgItemPathW.obj\
112		$(SLO)$/PathStripToRootW.obj\
113		$(SLO)$/SHCreateItemFromParsingName.obj
114
115SHL1TARGET=$(TARGET)
116SHL1IMPLIB=$(SHL1TARGET)
117SHL1DEF=$(MISC)/$(SHL1TARGET).def
118DEF1NAME=$(SHL1TARGET)
119.IF "$(COM)"=="GCC"
120DEF1EXPORTFILE=\
121	$(SHL1TARGET)_mingw.dxp\
122	unicows_mingw.dxp
123.ELSE
124DEF1EXPORTFILE=\
125	$(SHL1TARGET).dxp\
126	unicows.dxp
127.ENDIF
128DEF1DEPN=\
129		$(DEF1EXPORTFILE)\
130		makefile.mk
131
132#SHL1VERINFO=$(SHL1TARGET).rc
133SHL1OBJS=$(SLOFILES)
134
135#No default libraries
136STDSHL=
137
138.IF "$(COM)"=="GCC"
139SHL1STDLIBS=\
140		-lmingw32 \
141		$(MINGW_LIBGCC)
142MINGWSSTDOBJ=
143MINGWSSTDENDOBJ=
144.ELSE
145SHL1STDLIBS=\
146		unicows.lib
147.ENDIF
148
149SHL1STDLIBS+=\
150		$(KERNEL32LIB)\
151		$(USER32LIB)\
152		$(ADVAPI32LIB)\
153		$(VERSIONLIB)\
154		$(LIBCMT)\
155		$(SHLWAPILIB)
156
157
158.ENDIF
159
160.IF "$(COM)"=="GCC"
161ALL: ALLTAR $(LB)$/libuwinapi.a
162
163$(LB)$/libuwinapi.a: $(MISC)$/uwinapi.def
164	dlltool --dllname uwinapi.dll --input-def=$(MISC)$/uwinapi.def --kill-at --output-lib=$(LB)$/libuwinapi.a
165.ENDIF
166
167.INCLUDE : target.mk
168