-
Notifications
You must be signed in to change notification settings - Fork 4
/
gcc_conf.inc
158 lines (146 loc) · 4.12 KB
/
gcc_conf.inc
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
FOR EACH WORKSPACE
REMOVE %(¯PATH)make.bat
FILE %(¯PATH)GNUmakefile
IFDEF TARGET_QTOPIA
IF %(QPEDIR)
// needed to run some of the Qtopia/Greenphone (stupid) scripts like gph
PRINTNL PREFIX?=%(QPEDIR)/image
PRINTNL DPREFIX?=%(QPEDIR)/dimage/opt/Qtopia
PRINTNL D="-d"
ENDIF
ENDIF
IF defined(NO_MAKE_EXE) || defined(NO_MAKE_EXE_JAVA)
FOR EACH USE
IF %(TYPE)==EXE && defined(NO_MAKE_EXE)
// do nothing
ELIF %(TYPE)==EXE_ANDROID && defined(NO_MAKE_EXE_JAVA)
// do nothing
ELSE
../ALL_NAMES += %(NAME)
ENDIF
ENDFOR
ELSE
ALL_NAMES = %(USE)
ENDIF
PRINTNL .PHONY: all clean depend cleandep install %(ALL_NAMES)
PRINTNL
PRINTNL all: %(ALL_NAMES)
PRINTNL
IFDEF TARGET_PS2SDK
PRINT run:
FOR EACH USE
IF %(TYPE)==EXE || %(TYPE)==CON
PRINT %(NAME)_run
ENDIF
ENDFOR
PRINTNL
PRINTNL
PRINTNL reset:
PRINTNL @$(PS2DEV)/bin/ps2client reset
PRINTNL
ENDIF
FOR EACH USE
IF defined(TARGET_PS2SDK) // direct references is too slow otherwise
PRINTNL %(NAME): %(USE)
ELSE
PRINTNL %(NAME):
ENDIF
PRINTNL @$(MAKE) -C %(¯!PATH) -f %(NAME).mak
IFDEF TARGET_PS2SDK
IF %(TYPE)==EXE || %(TYPE)==CON
PRINTNL %(NAME)_run: %(NAME)
PRINTNL @$(PS2DEV)/bin/ps2client execee host:%(¯!OUTPUTPATH)%(+OUTPUT_DIR)%(OUTPUT)
ENDIF
ENDIF
ENDFOR
PRINTNL clean depend cleandep install:
FOR EACH USE
PRINTNL @$(MAKE) -C %(¯!PATH) -f %(NAME).mak $@
ENDFOR
// PRINTNL @rm -rf %(!BUILDPATH)
// PRINTNL @rm -rf %(!OUTPUTPATH)
IFDEF TARGET_QTOPIA
PRINTNL install:
FOR EACH USE
IF %(TYPE)==EXE
PRINTNL @$(MAKE) -C %(¯!PATH) -f %(NAME).mak install
ENDIF
ENDFOR
ENDIF
ENDFOR
FOR EACH LIB,DLL,EXE,CON
IF "%(TRANSLATION_QT4)"!=""
FILE %(¯PATH)%(NAME).tmp.pro
#include "qmake.inc"
ENDIF
ENDFOR
FOR EACH LIB,DLL,EXE,CON,EXE_ANDROID,DLL_ANDROID
IF defined(TARGET_PALMOS) && (%(TYPE)==exe)
SOURCE_M68K += %(¯PATH)%(NAME)_palmos.rcp
FILE %(¯PATH)%(NAME)_palmos.rcp
PRINTNL APPLICATIONICONNAME 1000 "%(PROJECT_NAME)"
IF "%(ICON)"!=""
PRINTNL
PRINTNL ICONFAMILYEX
PRINTNL BEGIN
PRINTNL BITMAP "%(!ICON)_palmos_22x22.bmp" BPP 8 TRANSPARENT 255 0 255 DENSITY 72
PRINTNL BITMAP "%(!ICON)_palmos_44x44.bmp" BPP 8 TRANSPARENT 255 0 255 DENSITY 144
PRINTNL END
PRINTNL
PRINTNL SMALLICONFAMILYEX
PRINTNL BEGIN
PRINTNL BITMAP "%(!ICON)_palmos_15x9.bmp" BPP 8 TRANSPARENT 255 0 255 DENSITY 72
PRINTNL BITMAP "%(!ICON)_palmos_30x18.bmp" BPP 8 TRANSPARENT 255 0 255 DENSITY 144
PRINTNL END
ENDIF
ENDIF
IFDEF TARGET_OSX
IF (%(TYPE)==EXE || %(TYPE)==DLL)
PLIST_FILE = %(¯PATH)%(NAME).plist
FILE %(¯PATH)%(NAME).plist
#include "osx_plist.inc"
ENDIF
ENDIF
IFDEF TARGET_QTOPIA
#include "qtopia_desktop.inc"
#include "qtopia_resource.inc"
ENDIF
FILE %(¯PATH)%(NAME).mak
#include "gcc_mak.inc"
IFDEF TARGET_PALMOS
IF (%(TYPE)==exe || %(TYPE)==dll)
FILE %(¯PATH)%(NAME)_palmos.def
IF (%(TYPE)==exe)
PRINTNL application { "%(PROJECT_NAME)" "%('PROJECT_FOURCC)" backup }
ELSE
PRINTNL database "%('PROJECT_FOURCC)" { "%(PROJECT_NAME)" "%('PROJECT_TYPE)" backup }
ENDIF
ENDIF
IF "%(INSTALL)"!=""
// 1: input
// 2: split
// 3: fourcc
// 4: output
FILEBIN %(¯PATH)%(NAME)_split.sh
SCRIPT
PRINTNL #!/bin/sh
PRINTNL
PRINTNL total=`wc -c $1 | cut -d" " -f1`
PRINTNL rm -f $4.rcp
PRINTNL
PRINTNL n=0
PRINTNL while [ $total -gt `expr $n "*" $2` ]
PRINTNL do
PRINTNL if [ $total -gt `expr $n "*" $2 + $2` ]
PRINTNL then
PRINTNL part=$2
PRINTNL else
PRINTNL part=`expr $total - $n "*" $2`
PRINTNL fi
PRINTNL dd iflag=binary oflag=binary bs=1 skip=`expr $n "*" $2` count=$part if=$1 of=$4.$n 2>nul
PRINTNL echo DATA \"$3\" ID `expr 1000 + $n` \"$4.$n\" >>$4.rcp
PRINTNL n=`expr $n + 1`
PRINTNL done
ENDIF
ENDIF
ENDFOR