2011年7月18日 星期一
Android - 撥號字串 android_secret_code
Android中 這個號碼有固定格式 *#*# 開頭,#*#*結尾的撥號字串
Ex:進入撥號程式,輸入*#*#4636#*#* 可以看到一個測試發佈文章應用
Step:1. AndroidManifest.xml添加Filter就可以
2. Write a class: TestingSettingsBroadcastReceiver
========================================
查看Phone的原始程式碼 SpecialCharSequenceMgr.java,
有一個函數專門處理*#*# 開頭,#*#*結尾的撥號字串。
Reference:
http://android.amberfog.com/?p=422
http://blog.csdn.net/learnrose/article/details/6223048
2011年7月15日 星期五
proguard 連結
ProGuard
.apk
file that is more difficult to reverse engineer. Because ProGuard makes your application harder to reverse engineer, it is important that you use it when your application utilizes features that are sensitive to security like when you areLicensing Your Applications.ProGuard is integrated into the Android build system, so you do not have to invoke it manually. ProGuard runs only when you build your application in release mode, so you do not have to deal with obfuscated code when you build your application in debug mode. Having ProGuard run is completely optional, but highly recommended.
2011年7月12日 星期二
Samba 開啟分享 筆記
1.目的
讓 Linux 與 Windows 的機器能共享資源。
所使用的 protocol 為 SMB 。
2.所需套件
samba-common , samba 以及 samba-client
(一). service 的名稱為:smb
(二). 在 samba 中,主要的 daemon 有 smbd / nmbd ,各肩負不同的責任:
a. smbd:File and Printer Sharing
b. nmbd:Resource Browsing / WINS Server
相關紀錄檔(Log)檔在 /var/log/samba 下。
3.samba 的設定檔為 /etc/samba/smb.conf。
其中以 # 或 ; 為首的資料行被視為註解。
4.預設的設定檔,內有三段:
[global]
workgroup = __________ # Workgroup / Domain Name
server string = _________ # 說明文字
log file = /var/log/samba/%m.log # %m --> The NetBIOS Name of client host
security = user # Or Anonymous
encrypt password = yes
smb password file = /etc/samba/smbpasswd
netbios name = ________ # 若無指定,預設為 hostname
[homes]
comment = home Directories
browseable = no
writable = yes
valid users = %S # %S --> User
create mode = 0664
directory mode = 0775
[printers]
comment = All Printers
path = /var/spool/samba
browseable = no
guest ok = no # guest ok = yes 等同 public = yes
writable = no
printable = yes # 印表機特定選項
5.檢測 smb.conf:
# testparm
6.啟動 samba:
# service smb [ status | start | stop | restart ]
[On ubuntu 10.10]
# service smbd [ status | start | stop | restart ]7.查看特定主機分享出的資源:
# smbclient -L 主機之NetBIOS名稱
8.[nmblookup]
a. 要查詢在目前的區域網路上是否有哪台主機之 NetBIOS name 為某個字
時,可以使用 nmblookup ,如 # nmblookup NetBIOSName
b. 也可用來像某台 WINS server 查詢:
# nmblookup -U wins_server -R NetBIOSName
9.要讓使用者以 john 的身分來使用 samba server 上的資源時,步驟如下:
(請留意 encrypt password = 及 smb passwd file =)
a. 在 samba server 上建立帳號
b. 利用 smbpasswd -a 為 john 設定 samba 的密碼
c. 利用 smbclient //host//homes -U john 測試
10.使用某 windows 網路上某台機器所分享出來的資源:
a. smbclient 資源名稱 -U 使用者名稱
# smbclient //hostname/test -U username
b. 把 windows 上的一個資源掛載(mount)過來
mount
# mount -t smbfs -o passwd=xxx //host/docs /mnt/samba
smbmount
11.請嘗試建立兩個 share
a. myshare:讓所有人均可讀取。
b. rhce:只有屬於 rhce 群組的使用者才可以存取。
[myshare]
path = /tmp/test
browseable = yes
public = yes
writeable = yes
[rhce]
path = /tmp/rhce
browseable = no
public = no
valid users = john , mary , @rhce
writeable = yes
12.利用 swat 來設定 samba
13.smbstatus 可用來顯示目前有多少客戶端正在使用本機所提供的 samba 服務
2011年6月15日 星期三
2009年4月26日 星期日
[轉載]List of Best Open Souce projects written in VC++/MFC
http://www.codeproject.com/KB/cpp/OpenSource_VC_MFC.aspx
Introduction
List of some of the best Open Source projects written in VC++/MFC.
Background
Codeproject has the best source code repository for VC++ developers. But another site Sourceforge.net also have some of the best quality projects available for VC++. Here I lists some of the best open source projects written in Visual C++. These are very good reference for all VC++ programmers.
List of Best Open Souce projects written in VC++/MFC
- 7-Zip (http://sourceforge.net/projects/sevenzip/) :
7-Zip is a file archiver with the high compression ratio. The program supports 7z, ZIP, CAB, RAR, ARJ, LZH, CHM, GZIP, BZIP2, Z, TAR, CPIO, RPM and DEB formats. Compression ratio in the new 7z format is 30-50% better than ratio in ZIP format. - eMule (http://sourceforge.net/projects/emule/):
eMule is a filesharing client which is based on the eDonkey2000 network but offers more features than the standard client. - eMule Plus (http://sourceforge.net/projects/emuleplus/) :
eMule Plus is an evolution of the original eMule project, created to improve its abilities and features, in both work efficiency and user interface. - eMule Morph (http://sourceforge.net/projects/emulemorph/):
eMule Morph Mod - eMule Modding Project. - FileZilla (http://sourceforge.net/projects/filezilla/):
FileZilla is a fast FTP and SFTP client for Windows with a lot of features. FileZilla Server is a reliable FTP server. - KeePass Password Safe (http://sourceforge.net/projects/keepass/):
KeePass Password Safe is a free, open source, light-weight and easy-to-use password manager for Windows. You can store your passwords in a highly-encrypted database, which is locked with one master password or key file. - K-Meleon (http://sourceforge.net/projects/kmeleon/):
K-Meleon is a fast and customizable web browser that can be used instead of Internet Explorer on Windows. Powered by the same Gecko engine as the Firefox and Mozilla browsers, K-Meleon provides users with a secure browsing experience. - MiKTeX (http://sourceforge.net/projects/miktex/):
MiKTeX is an up-to-date implementation of TeX & Friends for Windows (all current variants). - MyNapster (http://sourceforge.net/projects/mynapster/):
MyNapster is a Win32 client using Gnutella and IRC for chat. It is based on Gnucleus and utilizes MFC (works with WINE). - Nokia Composer (http://sourceforge.net/projects/nokiacomposer/):
This is a Win32, VC++ MFC application to manage Nokia mobile phones melodies. Includes VC++ source code and Rational Rose UML model. - Peters Backup (http://sourceforge.net/projects/pbackup):
Peters Backup is a program for backing up your important data files on to diskette, zip drive, fixed disk or CD/RW. It uses an extremely efficient compression algorithm. It keeps track of all versions of your files in full and incremental backups. - Password Safe (https://sourceforge.net/projects/passwordsafe/):
Password Safe is a password database utility. Users can keep their passwords securely encrypted on their computers. A single Safe Combination unlocks them all. - RenFile (http://sourceforge.net/projects/renfile/):
rename files and folders in bulk using this vc++ .net program. - Shareaza (https://sourceforge.net/projects/shareaza/):
Multi-network peer-to-peer file-sharing client supporting Gnutella2, Gnutella1, eDonkey2000/eMule and BitTorrent protocols. Using C++, MFC and ATL, for Windows. - SunshineUN (http://sourceforge.net/projects/sunshineun/):
SunshineUN is a free Napster based file sharing program for Opennap/Slavanap which allows you to share and download multiple files of different types for example music, pictures and videos. It is for Windows and it is written in C++ using MFC . - TortoiseCVS (http://sourceforge.net/projects/tortoisecvs/):
TortoiseCVS is an extension for Microsoft Windows Explorer that makes using CVS fun and easy. Features include: colored icons, tight integration with SSH, and context-menu interactivity. - TortoiseSVN (http://sourceforge.net/projects/tortoisesvn):
TortoiseSVN is a Subversion (SVN) client, implemented as a windows shell extension. It's intuitive and easy to use, since it doesn't require the Subversion command line client to run. Simply the coolest Interface to (Sub)Version Control! - WinDirStat: Windows Directory Statistics (http://sourceforge.net/projects/windirstat/):
WinDirStat (WDS) is a disk usage statistics viewer and cleanup tool for Windows. It shows disk, file and directory sizes in a treelist as well as graphically in a treemap, much like KDirStat or SequoiaView. - WinDjView (http://sourceforge.net/projects/windjview):
WinDjView is a fast, compact and powerful DjVu viewer for Windows with continuous scrolling and advanced printing options, based on free DjVuLibre library. MacDjView is a simple DjVu viewer for Mac OS X, also with continuous scrolling. - C++ Library for Windows (http://sourceforge.net/projects/rulib):
A C++ library for the Windows platform containing classes for MIME, video capture, socket, Windows registry, files, images, and other basic purposes. - WinMerge (https://sourceforge.net/projects/winmerge/):
WinMerge is a Win32 tool for visual difference display and merging, for both files and directories. Unicode support. Flexible syntax coloring editor. Windows Shell integration. Regexp filtering. Side-by-side line diff and highlights diffs inside lines. - Disk Cleaner (http://sourceforge.net/projects/dclean/):
Disk Cleaner is a tool to quickly and easily free disk space that is used by temporary files like the system temporary folder, the Internet Explorer Cache and Cookies folder, and the Recycle Bin. It can be expanded with text-based plug-ins & DLLs. - Shared IIS Server Log/Bandwidth-Analyzer (http://sourceforge.net/projects/sharediis/):
This utility is intended to be used to analyze and present a per-site (in case of WWW logs), or (in case of FTP logs) a per-web summary of bandwidth used, hits, and average bandwidth used. - Remote Control Center (http://sourceforge.net/projects/remotectrlctr/):
Remote Control Center is an application designed to help a system/network administrators taking control of remote devices in the network from a single GUI. - RevConnect - Enhanced DC++ (http://sourceforge.net/projects/reverseconnect/):
RevConnect is a file sharing program based on DC++. It is fully compatible with the Direct Connect network and made some major features. - Show Traffic (http://sourceforge.net/projects/showtraf):
"Show Traffic" monitors network traffic on the chosen network interface and displays it continuously. It could be used for locating suspicious network traffic or to evaluate current utilization of the network interface. - War FTP Daemon Engine (http://sourceforge.net/projects/wfde/):
A generic C++ class library for FTP server implementations, including a full-featured, mature FTP server. - AxCrypt - File Encryption for Windows (http://sourceforge.net/projects/axcrypt/):
AxCrypt - Personal Privacy and Security with AES-128 File Encryption and Compression for Windows 98/ME/NT/2K/XP. Double-click to automatically decrypt and open documents. Store strong keys on removable USB-devices. - Open Source Firewall For Windows (http://sourceforge.net/projects/firewallpapi/):
FirewallPAPI is an open source firewall for Windows 2000 and above. It is a simple utility for filter network traffic. - MinkSonic Jukebox (http://sourceforge.net/projects/minksonic):
MFC-based front-end to Winamp that provides jukebox behavior as well as "explorer-like" MP3 library management, a web-based network interface and MP3 frame error detection/correction. - p2pfire: super p2p driver firewall (http://sourceforge.net/projects/p2pfire):
Super P2P firewall 32/64 bits (driver + aplication). - WABAccess (http://sourceforge.net/projects/wabaccess/):
The WABAccess component give an access to the Windows Address Book (or WAB) used by Outlook Express. It's a COM/ATL component that give an access from Visual Basic language or Scripting language (VBS) to WAB. - Yet Another Fractal Explorer (http://sourceforge.net/projects/yafe):
Yet Another Fractal Explorer is an interactive fractal renderer for Windows. It features extremely simple and intuitive user interface and is capable of producing mathematically-sound renderings. - CDDA Ripper XP (http://sourceforge.net/projects/cddarip):
CDDA Ripper XP is an audio CD ripper program that provides support for NT/2000/XP natively (ASPI manager is optional). It supports WAV-MP3-OGG-FLAC-ACM codec encoding and can be used to rip multiple CDs. It uses newest encoders like LAME and Ogg/Vorbis. - [ mp3 - explorer ] (http://sourceforge.net/projects/mp3explorer):
[ mp3 - explorer ] is a MP3 Manager providing advanced features : multi-folders file scaning with cache - id3v1 and id3v2 tagging - Intellitag - Html view of the tracks displaying album cover and Lyrics. - ultraMaGE (http://sourceforge.net/projects/ultramage):
ultraMage is a powerful dual-window file manager for Windows with many useful features like bookmarks, advanced file operations and folder synchronisation. It is still very easy to use, because the user interface is similar to that of Windows Explorer. - WinTarBall (http://sourceforge.net/projects/wintarball/):
WinTarBall adds a control panel and an Explorer shell extension that allow users to compress directories into .tgz or .tbz files simply by right-clicking on them and choosing "compress to tarball". - XML Explorer (http://sourceforge.net/projects/xpathexplorer/):
A utility to query xml files using XPath and also extend XPath to more documents than one. Win32 platform/MFC. - Emerge Desktop (http://sourceforge.net/projects/emerge/):
emerge is an alternate windows shell. It's purpose is to replace Windows Explorer as your desktop user interface, providing similar functionality, with the additional plugins to provide even more. - Folder Size for Windows (http://sourceforge.net/projects/foldersize/):
Folder Size for Windows adds a new column to the Windows Explorer details view that displays the sizes of files and folders. A service scans your hard disk in the background and caches the results. Designed for performance! - Rename-It! (https://sourceforge.net/projects/renameit/):
Define some filters to apply to a list of files, which can be in multiple folders, to rename the whole list at once. It checks the file names, integrates in the Shell (via Explorer context menu), supports regular expressions, ID3 tags, and much more. - ShellWM (http://sourceforge.net/projects/shellwm/):
Windows skinning application to be used with a Win32 Shell replacement (like Litestep, geOshell, sharpE, etc.) or just native Explorer. - Blackbox for Windows (http://sourceforge.net/projects/bb4win/):
Blackbox for Windows is an alternative shell for Microsoft Windows. It is based stylistically on the Blackbox window manager for the X Window System, however it does not use the same codebase except for the gradient rendering code. - HideThatWindow! (http://sourceforge.net/projects/hidethatwindow/):
HideThatWindow! enables you to Hide or Show a window; minimize, maximize and restore its original size (or change the size to fit your needs). Disable the window's taskbar button or send it to tray. Other features are transparency, docking and top-most. - Security & Privacy Complete 3 (http://sourceforge.net/projects/cmia/):
Security & Privacy Complete is mainly a security tool for Windows. It can disable all services which might be a securit-risk, harden registry settings... Also included privacy features for Internet Explorer, Media Player, and of course: Mozilla Firefox. - TaskSwitchXP (http://sourceforge.net/projects/taskswitchxp/):
TaskSwitchXP provides the same functionality as the existing application switching mechanism in Windows XP today. In addition to displaying an icon list, however, the application will also show a thumbnail preview of the window that will be switched to. - Windows Process Tools (http://sourceforge.net/projects/winpstools):
Command-line utilities to find, list, and terminate running processes under Windows, similar to the Unix ps and kill commands. Good for command-line folks who don't like to use the Windows Task Manager. - OpenSTA (http://sourceforge.net/projects/opensta/):
Open System Testing Architecture - a distributed software testing architecture designed around CORBA. The current toolset has the capability of performing scripted Web (HTTP and HTTPS) heavy load tests with performance measurements from Win32 platforms. - MFC MUTE (http://sourceforge.net/projects/mfc-mute-net/):
MFC MUTE is a MS Windows *ONLY* client for the MUTE anonymous P2P network. This application derives from the original MUTE (mute-net.sourceforge.net) app supporting anonymous file sharing. The GUI is the best/most polished Windows MUTE available. - DeepNetScanner (http://sourceforge.net/projects/nbtenum):
This is a internet security scanner which scans a specified machine or a range of IPs for all possible information like NetBIOS enumeration, gathering sharelist, domain, os, lan manager, remote connection, SNMP walking, ... - WinSCP (http://sourceforge.net/projects/winscp/):
WinSCP is a SFTP and SCP client for Windows using SSH. Its main function is secure copying of files between a local and a remote computer. Beyond this basic function, WinSCP manages some other actions with files. Plugin to FAR manager is available too. - winfingerprint (http://sourceforge.net/projects/winfingerprint/):
Winfingerprint is a Win32 MFC VC++ .NET based security tool that is able to Determine OS, enumerate users, groups, shares, SIDs, transports, sessions, services, service pack and hotfix level, date and time, disks, and open tcp and udp ports. - Visual Component Framework (http://vcf-online.org/): The Visual Component Framework is an advanced C++ application framework that makes it easy to produce powerful C++ applications. The framework is a based on a thoroughly modern C++ design and has built in support for Rapid Application Development (RAD).
Some Very good VC++/MFC resources beside Codeproject.com
- http://www.naughter.com/ (VC++/MFC huge code repository)
By PJ naughter Personally my favorite beside codeproject.com. This site contains huge source code repository for MFC programmer. It has some of the best addon classes written for MFC programmers. What I like most about PJ naughter is that he keeps on improving these classes and fix each and every bug in the code. Some of the classes has now is 70 to 80th version. - http://flounder.com/mvp_tips.htm (VC++/MFC)
BY Joseph M. Newcomer
This is very nice site containing lots and lots of VC++ tips tricks and very detailed essays + great code examples. Main focus is on how to write the code in right way. - http://www.cheztabor.com/ (ATL/WTL)
by cheztabor
This site contains very nice code examples for ATL , WTL and Shell programming. - http://www.viksoe.dk/code/ (ATL/WTL)
By author of Gmail Drive
Although code for GmailDrive is not provided but this site contains lots of other code example covering MFC, ATL, WTL and Shell programming. - http://www.codeguru.com/ (VC++/MFC/ATL and lot more)
Does not need any introduction. I think most of us already know about this site. - http://programmerworld.net/personal/projects.htm (VC++/MFC )
This is my personal web site. It has one firewall software with source code. Will be adding more code soon. - http://vcfaq.mvps.org/ (VC++/MFC FAQs)
This is the MVP's Frequently Asked Questions Page for Microsoft Visual C++. In here you'll find answers to several common asked questions about Visual C++, MFC and Windows development in C/C++, as well as other. - http://www.developersvoice.com/programming/article/vc-mfc (VC++/MFC)
VC++/ MFC related FAQS - http://www.functionx.com/ (VC++/MFC )
A beginners site for VC++ and MFC programming. Contains some very nice beginner articles. - http://www.softlookup.com/tutorial/vc++/index.asp A beginners site for VC++ and MFC programming. Contains some very nice beginner articles.
- http://www.mathcs.sjsu.edu/faculty/pearce/mfc/ A very vice web site. Very well written. One of the best resource for beginner in the field of VC++/MFC.
Points of Interest
I have written this article to provide all VC++ developers a place where they can find some of the best open source VC++/MFC applications. I personally find them very useful.
Kindly help me in adding more good open source VC++/MFC projects in this list.
You can find more articles and software projects with free source code on my web site :-
2009年4月17日 星期五
Lua與C語言的結合- Part1 設定檔的應用
Lua是一個C語言寫成的script language.
Lua是什麼 google 一下就有了 我擷取wiki的一部分資料來使用
Lua 的wiki (http://zh.wikipedia.org/w/index.php?title=Lua&variant=zh-hant)
特性
Lua是一種輕量語言,它的官方版本只包括一個精簡的核心和最基本的庫。這使得Lua體積小、啟動速度快。它用標準C語言編寫並以源代碼形式開放,編譯後僅僅一百餘K,可以很方便的嵌入別的程式裡。和許多"大而全"的語言不一樣,網路通訊、圖形界面等都沒有預設提供。但是Lua可以很容易地被擴展:由宿主語言(通常是C或C++)提供這些功能,Lua可以使用它們,就像是本來就內置的功能一樣。事實上,現在已經有很多成熟的擴展模塊可供選用。
Lua是一種多重編程範式的程式設計語言:它只提供了很小的一個特性集合來滿足不同編輯範式的需要,而不是為某種特定的編輯範式提供繁雜的特性支援。例如,Lua並不提供繼承這個特性,但是你可以用元表來模擬它。諸如名字空間、類這些概念都沒有在語言基本特性中實現,但是我們可以輕易的用表結構(Lua唯一提供的複雜數據結構)輕易模擬。Lua可以在運行時隨時構造出一個函數,並把它看作一個對象(正是所謂的first class function),這個特性可以很好的滿足函數式編程的需要。這是提供了這些基本的元特性,我們可以任意的對語言進行自需的改造。
Lua原生支援的數據類型非常之少,它只提供了 數字(缺省是雙精度浮點數,可配置)、布爾量、字符串、表、子程序、協程(coroutine)以及用戶自定義數據這幾種。但是其處理表和字符串的效率非常之高,加上元表的支援,我們可以高效的模擬出需要的複雜數據類型(比如集合、數組等)。
Lua是一個動態弱類型語言,支援增量式垃圾收集策略。有內建的,與操作系統無關的協作式多線程(coroutine)支援。
================================================================
比起python perl來說lua非常的小 資源需求量也很低
Perl的原始碼 很亂 有些架構上 非常不適合C/C++ embed
python 就好很多 python 比起來 比perl好學 也好debug多
至於embed這方便 也處理得非常好 python架構有想到embed這一塊
但是python有一個缺點 就是他需要C++的compiler
那我們可以拿Lua作什麼用 除了拿來作script engine外
因為1. Lua 需求資源少 2.Lua API 好使用 3. 當檔案文法錯誤 會有訊息指出
還有一個很有用的功能 就是 當作"設定檔"或是"文字資源檔"
接下來 提供下面的作法 跟大家分享
1.Init lua
2. Load Lua file
3. How to trace lua object
前置作業 到Lua的網站download一份原始碼 跟你的程式結合在一起
Lua 5.1.4 Link: http://www.lua.org/ftp/lua-5.1.4.tar.gz
1.如何init Lua
lua_State 可以產生很多個 每一個代表一個Lua virtual machine
這也是lua 有考慮到embed之後的設計 ,perl就沒有這樣的好處
2. Load Lua file
3. Trace Lua object.
這邊提供一個trace/dump object的function
可以參考codes的作法 可以隨意implement 自己讀取變數或是儲存變數的函式
這邊 有一個非常重要的一點 就是 如何trace table
一般都會用 lua_objlen() 去讀取table的obj len
但是 你會發現 會有點怪怪的
如果你的table裡面 有另外一個table你會發現 lua_objlen()回來的數字並不包含sub-table
這個部分 我有機會 再另外開一篇來解釋這個東西
如果 你的table不會有含有string-index的table 請用lua-objlen() 然後用index去取得obj
要完整的trace一個table 要利用 lua_next() api (這樣出來的順序是不固定的)
如何使用請參考我提供的codes
setting.lua
----------------------------
----------------------------
trace後的結果
----------------------------
----------------------------
Source code:
_traceLuaGlobalObject(g_pLuaState,"ConfigDB",stdout);
參考資料:
在可插入脚本的应用程序中嵌入 Lua (http://www.ibm.com/developerworks/cn/linux/l-embed-lua/)
使用 Lua 编写可嵌入式脚本 (http://www.ibm.com/developerworks/cn/linux/l-lua.html)
2009年4月15日 星期三
[其他筆記]Visual C++ 編譯器選項
選項 | 用途 |
---|---|
建立小型程式碼。 | |
建立快速程式碼。 | |
控制內嵌展開。 | |
停用最佳化。 | |
使用全域最佳化。 | |
產生內建函式。 | |
偏好小的程式碼。 | |
偏好快的程式碼。 | |
使用最大最佳化 (/Ob2gity /Gs)。 | |
省略框架指標 (僅適用於 x86)。 |
選項 | 用途 |
---|---|
在程式碼產生時使用 SSE 或 SSE2 指令 (僅適用於 x86)。 | |
增加 .obj 檔中可定址區段的數目。 | |
產生輸出檔案,以便在 Common Language Runtime 上執行。 | |
指定例外處理模型。 | |
產生已為特定 x64 架構最佳化的程式碼,或為 AMD64 和 延伸記憶體 64 技術 (Extended Memory 64 Technology,EM64T) 架構中微架構特性最佳化的程式碼。 | |
指定浮點行為。 | |
為 Itanium 處理器執行最佳化。只有 IPF 跨平台編譯器或 IPF 原生編譯器才有提供。 | |
為 Itanium2 處理器執行最佳化。只有 IPF 跨平台編譯器或 IPF 原生編譯器才有提供。 | |
使用 __cdecl 呼叫慣例 (僅適用於 x86)。 | |
啟動堆疊探查。 | |
啟用字串共用。 | |
呼叫攔截函式 _penter。 | |
呼叫攔截函式 _pexit。 | |
啟用整個程式最佳化。 | |
啟用最少重建。 | |
啟用執行階段型別資訊 (RTTI)。 | |
使用 __fastcall 呼叫慣例 (僅適用於 x86)。 | |
控制堆疊探查。 | |
對使用靜態執行緒區域儲存區配置的資料支援 Fiber 安全性。 | |
啟用同步例外處理。 | |
啟用函式階層連結。 | |
使用 __stdcall 呼叫慣例 (僅適用於 x86)。 | |
使用 MSVCRT.lib 建立多執行緒 DLL。 | |
使用 MSVCRTD.lib 建立偵錯多執行緒 DLL。 | |
使用 LIBCMT.lib 建立多執行緒可執行檔。 | |
使用 LIBCMTD.lib 建立偵錯多執行緒可執行檔。 | |
產生快速超越函式。 | |
移除 try 區塊內的 fwait 命令。 |
選項 | 用途 |
---|---|
建立清單檔 設定清單檔名稱。 | |
建立清單檔 設定清單檔名稱。 | |
重新命名程式資料庫檔案。 | |
重新命名可執行檔。 | |
建立對應檔 (Mapfile)。 | |
建立目的檔。 | |
指定先行編譯標頭檔的名稱。 | |
產生瀏覽器檔案。 | |
將插入的程式碼與原始程式檔合併。 |
選項 | 用途 |
---|---|
緩衝區安全性檢查。 | |
與 /RTC1 相同。 | |
在函式進入時,強制暫存器中所傳遞的參數寫入至堆疊上的位置。這個編譯器選項只適用於 x64 編譯器 (原生和跨平台編譯)。 | |
啟用執行階段錯誤檢查。 | |
偵測 64 位元可移植性問題。 | |
將完整的偵錯資訊置於所有目的檔中。 | |
在建立偵錯程式庫時插入一個 PCH 參考。 | |
產生 C 7.0 相容的偵錯資訊。 | |
產生完整偵錯資訊。 | |
將偵錯資訊包括在與「編輯後繼續」相容的程式資料庫中 (僅適用於 x86)。 | |
產生可偵錯最佳化程式碼。只有 IPF 跨平台編譯器或 IPF 原生編譯器才有提供。 |
選項 | 用途 |
---|---|
指定一個要搜尋的目錄,以解析傳遞給 #using 指示詞的檔案參考。 | |
在前置處理過程中保留註解。 | |
定義常數和巨集。 | |
複製前置處理器輸出至標準輸出。 | |
複製前置處理器輸出至標準輸出。 | |
前置處理指定的包含檔。 | |
強制使用某一檔名,就如同它已傳遞給 #using 指示詞一樣。 | |
搜尋包含檔的目錄。 | |
將前置處理器輸出寫入檔案。 | |
移除某個預先定義巨集。 | |
移除所有預先定義巨集。 | |
忽略標準 Include 目錄。 |
選項 | 用途 |
---|---|
在原始程式碼中啟用 #pragma omp。 | |
抑制或啟用隱藏的 vtordisp 類別成員。 | |
對指向成員的指標使用最佳基底。 | |
對指向成員的指標使用完整一般性。 | |
宣告多重繼承。 | |
宣告單一繼承。 | |
宣告虛擬繼承。 | |
停用語言擴充功能。 | |
指定 /Ze 下的標準行為。 | |
啟用語言擴充功能。 | |
產生函式原型。 | |
從 .obj 檔案移除預設程式庫名稱。 | |
/Zpn | 封裝結構成員。 |
僅檢查語法。 |
選項 | 用途 |
---|---|
設定堆疊大小。 | |
建立動態連結程式庫。 | |
建立偵錯動態連結程式庫。 | |
建立 MSIL 模組。 | |
傳遞指定的選項給 LINK。 | |
使用 MSVCRT.lib 編譯以建立多執行緒 DLL。 | |
使用 MSVCRTD.lib 編譯以建立偵錯多執行緒 DLL。 | |
使用 LIBCMT.lib 編譯以建立多執行緒可執行檔。 | |
使用 LIBCMTD.lib 編譯以建立偵錯多執行緒可執行檔。 |
選項 | 用途 |
---|---|
列出編譯器選項。 | |
指定回應檔 (Response File)。 | |
啟用程式碼分析。 | |
編譯而不連結。 | |
將文件註解處理成 XML 檔案。 | |
讓您直接提供內部編譯器錯誤 (ICE) 資訊給 Visual C++ 團隊。 | |
顯示在診斷測試中傳遞給 cl.exe 的原始程式檔完整路徑。 | |
限制外部 (共用) 名稱的長度。 | |
列出編譯器選項。 | |
建立可線上修補的影像。 | |
變更預設 char 型別。 | |
同時建置多重原始程式檔。 | |
隱藏登入程式的啟始資訊。 | |
在必須從浮點型別轉換為整數型別時,抑制呼叫 Helper 函式 _ftol (僅適用於 x86)。 | |
根據 B CPU 逐步偵錯的 errata,不會產生指令順序,而導致意外結果(僅適用於 IPF)。 | |
根據 C CPU 逐步偵錯的 errata,不會產生指令順序,而導致意外結果(僅適用於 IPF)。 | |
不要使用上層 96 浮點暫存器(僅適用於 IPF)。 | |
產生影像加上與位置有關的程式碼 (僅適用於 IPF)。 | |
為不在執行階段建立函式的程式增強效能(僅適用於 IPF)。 | |
在編譯時顯示所有包含檔清單。 | |
指定 C 原始程式檔。 | |
指定 C++ 原始程式檔。 | |
設定版本字串。 | |
啟用所有警告,包括預設停用的警告。 | |
設定警告層級。 | |
停用所有警告。 | |
從命令列編譯 C++ 原始程式碼時啟用一行錯誤和警告訊息診斷。 | |
指定先行編譯標頭檔的記憶體配置上限。 |