tcc-win32译文

Tiny C Compiler 是一个微型的 C 语言编译器,支持 Windows 和 Linux 平台。



  标签:                  C/C++                          Windows                          Linux                          编译器           




    TinyCC
    ======


    这个文件包含了TinyCC在MS-Windows下用法的详细信息。所有的特性详见tcc-doc.html。



    从源代码编译:
    ------------------------
    * You can use the MinGW and MSYS tools available at

        http://www.mingw.org

    Untar the TCC archive and type in the MSYS shell:
   
       ./configure
       make
       make install

    默认的安装位置是c:\Program Files\tcc


    * 另一个方法是你可以使用GCC from MinGW 来编译TCC,使用
    win32\build-tcc.bat
    来安装,复制完整的win32内容 到你想安装的目录




    使用2进制zip包来安装:
    -----------------------------------------
    解压到你选择的目录下。


    (注意2进制包不包含libtcc.如果你想TCC作为动态代码生成器,请使用源码版本)
   

    设置系统环境变量PATH:
    --------------------
    为了能够随时随地通过键入“tcc”就调用此编译器,请把包含tcc.exe的目录放到你的系统路径下。


    Examples示例:
    ---------
    打开一个控制台窗口(dos窗口),'cd'到examples 目录下。


    For the 'Fibonacci' example type:

    tcc fib.c

    For the 'Hello Windows' GUI example type:

    tcc hello_win.c

    for the 'Hello DLL' example type

    tcc -shared dll.c
    tiny_impdef dll.dll (optional)
        tcc hello_dll.c dll.def



    引入指定文件:
    ------------------------
    为了连接Windows 系统的DLL,TCC 使用引入指定文件(.def) 来代替类库


    内置的'tiny_impdef' 程序用于增加其他任意的DLL的.def文件,例如

     tiny_impdef.exe opengl32.dll
  
    把opengl32.def放到 tcc/lib目录下。在TCC命令行下指定-lopengl32来连接一个使用opengl32.dll的程序



    Header Files:
    -------------
    系统头文件(除了_mingw.h) 都来自于 MinGW 版本:

    http://www.mingw.org/

    里面的windows 头部文件,仅仅包含了一小部分。如果你需要更多,去MinGW的"w32api" 包下找。



    资源文件:
    ---------------
    TCC 能够以一种通用的对象格式连接由MinGW的windres.exe生成的windows 资源 。例如
        windres -O coff app.rc -o appres.o
        tcc app.c appres.o -o app.exe


     /*译者注:coff ---一种通用的对象文件格式(Common Object File Format)*/

    极小的类库制造器:
    --------------
    内置的 Timovj Lahde写的tiny_libmaker 工具用于
    替换'ar' 通过许多对象文件来产生一个类库
        tiny_libmaker [rcs] library objectfiles ...



    局限:
    ------------
    - On the object file level, currently TCC supports only the ELF format,
      not COFF as used by MinGW and MSVC.  It is not possible to exchange
      object files or libraries between TCC and these compilers.  However
      libraries for TCC from objects by TCC can be made using tiny_libmaker
      or MinGW's ar.

    - No leading underscore is generated in the ELF symbols.

    - With DLLs, only functions (not data) can be im-/exported.

    - Bounds checking (option -b) is not supported currently.

    - 64-bit systems are not (yet) supported.



    文档和License:
    --------------------------
    TCC is distributed under the GNU Lesser General Public License. (See
    COPYING file or http://www.gnu.org/licenses/lgpl-2.1.html)

    TinyCC homepage is at:

    http://fabrice.bellard.free.fr/tcc/



   WinAPI 帮助和第三方工具:
    --------------------------------
   Windows API文档 (Win95) 在单独的 .hlp是可用的,在lcc-win32 网址的"win32hlp.exe"或其他地方

的"win32hlp_big.zip"

   一个非常好的名为"ResEd"的用于创建windows资源RAD工具 (对话框等 ),在RadASM 网站上可以找到



    --- grischka
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值