上篇大概数了下怎么调用DCC32然后给了几个选项的解释,不过,那些选项都很粗糙,现在,我详细说下自己的理解,当然,这个是个人理解,可能不是很准确,欢迎大家更正,先谢谢了O(∩_∩)O。
本文地址:http://blog.csdn.net/sushengmiyan/article/details/10285347
ID:sushengmiyan
先看看当我们成功调用了DCC32之后的dos提示信息吧,我把那些信息都贴在下面了:
// DCC32编译器的设置说明。
//CodeGear Delphi for Win32 compiler version 18.0
//Copyright (c) 1983,2005 CodeGear
//
//Syntax: dcc32 [options] filename [options]
//
// -A<unit>=<alias> = Set unit alias
// -B = Build all units
// -CC = Console target
// -CG = GUI target
// -D<syms> = Define conditionals
// -E<path> = EXE/DLL output directory
// -F<offset> = Find error
// -GD = Detailed map file
// -GP = Map file with publics
// -GS = Map file with segments
// -H = Output hint messages
// -I<paths> = Include directories
// -J = Generate .obj file
// -JPHNE = Generate C++ .obj file, .hpp file, in namespace, export all
// -K<addr> = Set image base addr
// -LE<path> = package .bpl output directory
// -LN<path> = package .dcp output directory
// -LU<package> = Use package
// -M = Make modified units
// -N0<path> = unit .dcu output directory
// -NH<path> = unit .hpp output directory
// -NO<path> = unit .obj output directory
// -NB<path> = unit .bpi output directory
// -NS<namespaces> = Namespace search path
// -O<paths> = Object directories
// -P = look for 8.3 file names also
// -Q = Quiet compile
// -R<paths> = Resource directories
// -U<paths> = Unit directories
// -V = Debug information in EXE
// -VR = Generate remote debug (RSM)
// -W[+|-][warn_id] = Output warning messages
// -Z = Output 'never build' DCPs
// -$<dir> = Compiler directive
// --help = Show this help screen
// --version = Show name and version
// --codepage:<cp> = specify source file encoding
// --default-namespace:<namespace> = set namespace
// --depends = output unit dependency information
// --doc = output XML documentation
// --drc = output resource string .drc file
// --no-config = do not load default DCC32.CFG file
//Compiler switches: -$<letter><state> (defaults are shown below)
// A8 Aligned record fields
// B- Full boolean Evaluation
// C+ Evaluate assertions at runtime
// D+ Debug information
// G+ Use imported data references
// H+ Use long strings by default
// I+ I/O checking
// J- Writeable structured consts
// L+ Local debug symbols
// M- Runtime type info
// O+ Optimization
// P+ Open string params
// Q- Integer overflow checking
// R- Range checking
// T- Typed @ operator
// U- Pentium(tm)-safe divide
// V+ Strict var-strings
// W- Generate stack frames
// X+ Extended syntax
// Y+ Symbol reference info
// Z1 Minimum size of enum types
东西比较多,不可能全部都说,大概我们平时用到的,我都会说一下,如果大家平时有经常用的,可以及时给我补充,O(∩_∩)O谢谢
首先,我写了一个注释,说明下面都是DCC32编译器的说明。
下面就是具体的语法介绍, DCC32 [操作选项] 文件名称 [操作选项]
其中,选项 -A是指,给单元设置别名,这个选项目前一般不在使用,不过多介绍。
-B 编译所有的单元,这个肯定对于编译项目的时候是必选的,要不然,漏一个dcu就不能正常生成了呗,好理解。
-CC 指定编译目标,如果你写的是console程序,那么你就选这个,否则一般情况下,我们选择的是可视化编辑,就是 -CG
-CG 可理解,就是现在windows的可视化程序,不是CMD那样的dos程序。
-D 编译条件符号定义
-E 制定生成的EXE的路径,即可执行文件的输出地方
-F 是否关闭查找运行期间错误
-GD 生成详细的Map文件,map文件,不同于可二进制的可执行文件和.dcu文件,.map文件是一个可读的文本文件,可以被打印或是其它文本编辑器编辑
-GP 生成map的public字段
-GS 生成map的segment字段 一个.MAP文件被分成三个节:Segment 、 Publics 、Line Numbers
-H 输出提示信息
-I 文件包含路径 可用
-J 生成 .obj文件 不怎么使用
-JPHNE 生成C++的obj文件
--K 图片文件基址
-LE .bpl文件输出路径 常用
-LN .dcp文件输出路径 常用
-LU 使用的运行期列表
-M 编译有变化的单元
-NO 单元的dcu输出路径 常用
-NH 单元的.hpp输出路径
-O obj文件
-P 8.3文件格式(不懂)
-Q 安静模式 ?啥意思 选不选有啥区别,谁给个解释
-R资源文件(.res)路径
-V 生成debugger调试信息文件
这个东西貌似网上也能搜的到,不过貌似都很稀少,这里给整理一下,然后方便自己查找,也方便后来人,如果想找的话,少走些弯路。
本文详细解析DCC32编译器的命令行选项,包括-A, -B, -CC, -CG, -D等,帮助读者理解如何在编译Delphi项目时正确使用这些参数。通过了解这些参数,可以更高效地管理和控制编译过程,如指定编译目标、设定输出路径和生成调试信息。"
109957156,9857683,找第一个只出现一次的字符 - C++实现,"['C++', '算法', '字符串']
3159

被折叠的 条评论
为什么被折叠?



