File: gen_vcpp_proj.sh

package info (click to toggle)
aspectc%2B%2B 1.0pre4~svn.20080711-1
  • links: PTS, VCS
  • area: main
  • in suites: lenny
  • size: 104,504 kB
  • ctags: 363,975
  • sloc: cpp: 1,645,814; ansic: 16,601; sh: 2,175; makefile: 1,043
file content (167 lines) | stat: -rw-r--r-- 6,051 bytes parent folder | download
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
#!/bin/sh

# This file is part of PUMA.
# Copyright (C) The PUMA developer team.
#                                                                
# This program is free software;  you can redistribute it and/or 
# modify it under the terms of the GNU General Public License as 
# published by the Free Software Foundation; either version 2 of 
# the License, or (at your option) any later version.            
#                                                                
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of 
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the  
# GNU General Public License for more details.                   
#                                                                
# You should have received a copy of the GNU General Public      
# License along with this program; if not, write to the Free     
# Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, 
# MA  02111-1307  USA                                            

PRJFILE="Puma.vcproj"

echo "Generating Puma project file $PRJFILE..."

rm -f "$PRJFILE"
  
cat >> "$PRJFILE" << EOF
<?xml version="1.0" encoding="Windows-1252"?>
<VisualStudioProject
	ProjectType="Visual C++"
	Version="7.00"
	Name="Puma"
	ProjectGUID="{37F3A735-0447-48C0-8FC5-832F01725A47}"
	Keyword="Win32Proj">
	<Platforms>
		<Platform
			Name="Win32"/>
	</Platforms>
	<Configurations>
		<Configuration
			Name="Debug|Win32"
			OutputDirectory=".\lib\\\$(ConfigurationName)"
			IntermediateDirectory=".\lib"
			ConfigurationType="4"
			CharacterSet="2">
			<Tool
				Name="VCCLCompilerTool"
				Optimization="0"
				AdditionalIncludeDirectories="&quot;.\gen-release\step2\inc&quot;;&quot;.\gen-release\step2\src&quot;;.\src\win32\regex"
				PreprocessorDefinitions="WIN32;_DEBUG;_LIB;__SIZE_TYPE__=size_t;__PTRDIFF_TYPE__=ptrdiff_t;HAVE_STRING_H;STDC_HEADERS"
				MinimalRebuild="true"
				BasicRuntimeChecks="3"
				RuntimeLibrary="3"
				UsePrecompiledHeader="0"
				WarningLevel="3"
				Detect64BitPortabilityProblems="true"
				DebugInformationFormat="4"
				DisableSpecificWarnings="4800;4355;4996;4244;4267"/>
			<Tool
				Name="VCPostBuildEventTool"
				CommandLine="copy &quot;\$(ProjectDir)\src\win32\regex\regex.h&quot; &quot;\$(ProjectDir)\include&quot;"/>
		</Configuration>
		<Configuration
			Name="Release|Win32"
			OutputDirectory=".\lib\\\$(ConfigurationName)"
			IntermediateDirectory=".\lib"
			ConfigurationType="4"
			CharacterSet="2"
			WholeProgramOptimization="1">
			<Tool
				Name="VCCLCompilerTool"
				AdditionalIncludeDirectories="&quot;.\gen-release\step2\inc&quot;;&quot;.\gen-release\step2\src&quot;;.\src\win32\regex"
				PreprocessorDefinitions="WIN32;NDEBUG;_LIB;__SIZE_TYPE__=size_t;__PTRDIFF_TYPE__=ptrdiff_t;HAVE_STRING_H;STDC_HEADERS"
				RuntimeLibrary="2"
				UsePrecompiledHeader="0"
				WarningLevel="3"
				Detect64BitPortabilityProblems="true"
				DebugInformationFormat="0"
				DisableSpecificWarnings="4355;4800;4996;4244;4267"/>
			<Tool
				Name="VCPostBuildEventTool"
				CommandLine="copy &quot;\$(ProjectDir)\src\win32\regex\regex.h&quot; &quot;\$(ProjectDir)\include&quot;"/>
		</Configuration>
		<Configuration
			Name="Debug DLL|Win32"
			OutputDirectory=".\lib\\\$(ConfigurationName)"
			IntermediateDirectory=".\lib"
			ConfigurationType="2"
			CharacterSet="2">
			<Tool
				Name="VCCLCompilerTool"
				Optimization="0"
				AdditionalIncludeDirectories="&quot;.\gen-release\step2\inc&quot;;&quot;.\gen-release\step2\src&quot;;.\src\win32\regex"
				PreprocessorDefinitions="WIN32;_DEBUG;_LIB;__SIZE_TYPE__=size_t;__PTRDIFF_TYPE__=ptrdiff_t;HAVE_STRING_H;STDC_HEADERS"
				MinimalRebuild="true"
				BasicRuntimeChecks="3"
				RuntimeLibrary="3"
				UsePrecompiledHeader="0"
				WarningLevel="3"
				Detect64BitPortabilityProblems="true"
				DebugInformationFormat="4"
				DisableSpecificWarnings="4800;4355;4996;4244;4267"/>
			<Tool
				Name="VCLinkerTool"
				GenerateDebugInformation="true"/>
			<Tool
				Name="VCPostBuildEventTool"
				CommandLine="copy &quot;\$(ProjectDir)\src\win32\regex\regex.h&quot; &quot;\$(ProjectDir)\include&quot;"/>
		</Configuration>
		<Configuration
			Name="Release DLL|Win32"
			OutputDirectory=".\lib\\\$(ConfigurationName)"
			IntermediateDirectory=".\lib"
			ConfigurationType="2"
			CharacterSet="2"
			WholeProgramOptimization="1">
			<Tool
				Name="VCCLCompilerTool"
				AdditionalIncludeDirectories="&quot;.\gen-release\step2\inc&quot;;&quot;.\gen-release\step2\src&quot;;.\src\win32\regex"
				PreprocessorDefinitions="WIN32;NDEBUG;_LIB;__SIZE_TYPE__=size_t;__PTRDIFF_TYPE__=ptrdiff_t;HAVE_STRING_H;STDC_HEADERS"
				RuntimeLibrary="2"
				UsePrecompiledHeader="0"
				WarningLevel="3"
				Detect64BitPortabilityProblems="true"
				DebugInformationFormat="0"
				DisableSpecificWarnings="4355;4800;4996;4244;4267"/>
			<Tool
				Name="VCPostBuildEventTool"
				CommandLine="copy &quot;\$(ProjectDir)\src\win32\regex\regex.h&quot; &quot;\$(ProjectDir)\include&quot;"/>
		</Configuration>
	</Configurations>
	<Files>
		<Filter
			Name="Source Files"
			Filter="cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx">
EOF

function add_files() {
  find $1 -type f -regex "$2" -printf "%f\n" | \
  while read file; do
    echo "			<File RelativePath=\"$3\\$file\"></File>" >> "$PRJFILE"
  done
}

add_files "./gen-release/step2/src" "\./.*\.\(c\|cc\|cxx\|cpp\)" ".\gen-release\step2\src"
add_files "./src/win32/regex" "\./.*\.\(c\|cc\|cxx\|cpp\)" ".\src\win32\regex"

cat >> "$PRJFILE" << EOF
		</Filter>
		<Filter
			Name="Header Files"
			Filter="h;hpp;hxx;ah;ot;hm;inl;inc;xsd">
EOF

add_files "./gen-release/step2/inc/Puma" "\./.*\.\(h\|ah\|hpp\|ot\)" ".\gen-release\step2\inc\Puma"
add_files "./gen-release/step2/src" "\./.*\.\(h\|ah\|hpp\|ot\)" ".\gen-release\step2\src"
add_files "./src/win32/regex" "\./.*\.\(h\|ah\|hpp\|ot\)" ".\src\win32\regex"

cat >> "$PRJFILE" << EOF
		</Filter>
	</Files>
	<Globals>
	</Globals>
</VisualStudioProject>
EOF
  
recode lat1..ibmpc -q "$PRJFILE"