|
|
通过使用unicode编译,软件可以适应多种情况,如何在自己的工程中添加这两种编译方式呢?下面是一个简单的步骤
3 Q, R8 X4 L% V5 [0 t1 F i* @+ m0 @* g2 \
1、新建一个工程;" g6 T; C5 a2 j( c
2、选择“Build->Configurations”菜单8 @3 H2 \2 |& _2 E8 ~: J( y
3、点击“Add”按钮,添加“Unicode Debug”-拷贝“win32 Debug”配置
- C# [0 a* l' j4 F, I 添加“Unicode Release”-拷贝“win32 Release”配置 ,然后点击“OK”" A* F' U# J. a# c6 u2 ~
4、选择“Project->Setting”菜单# f$ {6 E6 T; O+ o/ G3 Z+ g; ]7 a
5、切换到“General ”TAB页
0 h- D, }4 y) E; u( z+ i 6、修改“Win32 Unicode Debug”的Intermediate Files和Output Files为DebugU 3 Z% r: Q3 s+ q
7、修改“Win32 Unicode Release”的Intermediate Files和Output Files为ReleaseU 9 w% n4 R5 [4 f2 k7 Y& j& P- ~) L
8、切换到“C++ ” Tab页) r3 i9 `6 h' ?& @3 T+ a( H' P
9、从下拉列表框中选择“Preprocessor”
; P3 t5 u3 ?" v& |, f 10、为“Win32 Unicode Debug”和“Win32 Unicode Release”分别添加_UNICODE和UNICODE variables |
|