使用 jsc.exe 把 JavaScript(.js)檔,轉換為exe執行檔
- 如何取得 jsc.exe
在安裝Windows的磁碟下,搜尋jsc.exe,複製到工作目錄下即可使用。 - jsc.exe 指令的參數
- C:\Users\hanni>jsc /help
 - Microsoft (R) JScript Compiler version 14.00.9032
 - for Microsoft (R) .NET Framework version 4.0.30319
 - Copyright (C) Microsoft Corporation. 著作權所有,並保留一切權利。
 
- jsc [options] <source files> [[options] <source files>...]
 
-                          JScript 編譯器選項
 
-                            - 輸出檔 -
 -   /out:<file>              指定二進位輸出檔案的名稱
 -   /t[arget]:exe            建立主控台應用程式 (預設)
 -   /t[arget]:winexe         建立 Windows 應用程式
 -   /t[arget]:library        建立程式庫組件
 -   /platform:<platform>     限制這個程式碼可以在哪些平台執行; 必須是 x86、Itanium、x64 或任何 CPU (預設)
 
-                            - 輸入檔 -
 -   /autoref[+|-]            以匯入的命名空間和完整名稱為基礎的自動參考組件 (預設值為 On)
 -   /lib:<path>              指定搜尋其他目錄以供參考之用
 -   /r[eference]:<file list> 從指定的組件檔來參考中繼資料
 -                            <file list>: <assembly name>[;<assembly name>...]
 
-                            - 資源 -
 -   /win32res:<file>         指定 Win32 資源檔 (.res)
 -   /res[ource]:<info>       嵌入指定的資源
 -                            <info>: <filename>[,<name>[,public|private]]
 -   /linkres[ource]:<info>   將指定的資源連結至此組件
 -                            <info>: <filename>[,<name>[,public|private]]
 
-                            - 程式碼產生 -
 -   /debug[+|-]              發出偵錯資訊
 -   /fast[+|-]               停用語言功能以產生較佳的程式碼
 -   /warnaserror[+|-]        警告視為錯誤
 -   /w[arn]:<level>          設定警告層級 (0-4)
 
-                            - 其他 -
 -   @<filename>              讀取回應檔以取得更多選項
 -   /?                       顯示說明
 -   /help                    顯示說明
 -   /d[efine]:<symbols>      定義條件式編譯的符號
 -   /nologo                  不要顯示編譯器著作權橫幅
 -   /print[+|-]              提供 print() 函式
 
-                            - 進階 -
 -   /codepage:<id>           使用指定的字碼頁 ID 開啟原始程式檔
 -   /lcid:<id>               為訊息和預設字碼頁使用指定的 LCID
 -   /nostdlib[+|-]           不要匯入標準程式庫 (mscorlib.dll) 並將 autoref 的預設值變更為 Off
 -   /utf8output[+|-]         以 UTF-8 字元編碼發出編譯器輸出
 -   /versionsafe[+|-]        指定未標記為 'override' 或 'hide' 成員的預設值
 
 
 
 
 
 
 
 
  
 
 
 
 
 
 
 
 
 
 
 
沒有留言:
張貼留言