Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(36)

Side by Side Diff: third_party/libusb/msvc/ddk_build.cmd

Issue 9826025: Import libusb 1.0.9-rc3 into third_party (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Cleaning up import instructions Created 8 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « third_party/libusb/msvc/config.h ('k') | third_party/libusb/msvc/inttypes.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 @rem default builds static library.
2 @rem you can pass the following arguments (case insensitive):
3 @rem - "DLL" to build a DLL instead of a static library
4 @rem - "/MT" to build a static library compatible with MSVC's /MT option (LIBCMT vs MSVCRT)
5 @echo off
6
7 if Test%BUILD_ALT_DIR%==Test goto usage
8
9 rem process commandline parameters
10 set TARGET=LIBRARY
11 set STATIC_LIBC=
12 set version=1.0
13
14 if "%1" == "" goto no_more_args
15 rem /I for case insensitive
16 if /I Test%1==TestDLL set TARGET=DYNLINK
17 if /I Test%1==Test/MT set STATIC_LIBC=1
18 :no_more_args
19
20 cd ..\libusb\os
21 echo TARGETTYPE=%TARGET% > target
22 copy target+..\..\msvc\libusb_sources sources >NUL 2>&1
23 del target
24 @echo on
25 build -cwgZ
26 @echo off
27 if errorlevel 1 goto builderror
28 cd ..\..
29
30 set cpudir=i386
31 set destType=Win32
32 if %_BUILDARCH%==x86 goto isI386
33 set cpudir=amd64
34 set destType=x64
35 :isI386
36
37 set srcPath=libusb\os\obj%BUILD_ALT_DIR%\%cpudir%
38
39 set dstPath=%destType%\Debug
40 if %DDKBUILDENV%==chk goto isDebug
41 set dstPath=%destType%\Release
42 :isDebug
43
44 if exist %destType% goto md2
45 mkdir %destType%
46 :md2
47 if exist %dstPath% goto md3
48 mkdir %dstPath%
49 :md3
50 if exist %dstPath%\dll goto md4
51 mkdir %dstPath%\dll
52 :md4
53 if exist %dstPath%\lib goto md5
54 md %dstPath%\lib
55 :md5
56 if exist %dstPath%\examples goto md6
57 md %dstPath%\examples
58 :md6
59 @echo on
60
61 @if /I NOT Test%1==TestDLL goto copylib
62 copy %srcPath%\libusb-%version%.dll %dstPath%\dll
63 copy %srcPath%\libusb-%version%.pdb %dstPath%\dll
64 :copylib
65 copy %srcPath%\libusb-%version%.lib %dstPath%\lib
66
67 @echo off
68
69 if exist examples\lsusb_ddkbuild goto md7
70 md examples\lsusb_ddkbuild
71 :md7
72
73 cd examples\lsusb_ddkbuild
74 copy ..\..\msvc\lsusb_sources sources >NUL 2>&1
75 @echo on
76 build -cwgZ
77 @echo off
78 if errorlevel 1 goto buildlsusberror
79 cd ..\..
80
81 set srcPath=examples\lsusb_ddkbuild\obj%BUILD_ALT_DIR%\%cpudir%
82 @echo on
83
84 copy %srcPath%\lsusb.exe %dstPath%\examples
85 copy %srcPath%\lsusb.pdb %dstPath%\examples
86
87 cd msvc
88 goto done
89
90
91 :builderror
92 cd ..\..\msvc
93 echo Build failed
94 goto done
95
96 :buildlsusberror
97 cd ..\..\msvc
98 echo lsusb build failed
99 goto done
100
101 :usage
102 echo ddk_build must be run in a WDK build environment
103 pause
104 goto done
105
106 :done
OLDNEW
« no previous file with comments | « third_party/libusb/msvc/config.h ('k') | third_party/libusb/msvc/inttypes.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698