zoukankan      html  css  js  c++  java
  • automake

    (1) 编写源文件hello.c:

    include
    int main(int argc, char** argv)
    {
    printf("Hello, GNU!n");
    return 0;
    }

    (2) #autoscan
    ->生成 configure.scan 和 autoscan.log

    (3) 将configure.scan 修改为 configure.in:

    # Process this file with autoconf to produce a configure script.
    AC_INIT(hello.c)
    AM_INIT_AUTOMAKE(hello, 1.0)

    # Checks for programs.
    AC_PROG_CC

    # Checks for library functions.
    AC_OUTPUT(Makefile)

    (4) #aclocal
    ->生成 aclocal.m4 和 autom4te.cache (生成aclocal.m4的过程中涉及到configure.in)

    (5) #autoconf
    ->生成 configure (根据 configure.in, 和 aclocal.m4)

    (6) 编写Makefile.am:

    AUTOMAKE_OPTIONS= foreign
    bin_PROGRAMS= hello
    hello_SOURCES= hello.c

    (7) #automake --add-missing
    ->生成 Makefile.in, depcomp, install-sh, 和 missing (根据 Makefile.am, 和 aclocal.m4)

    (8) #./configure
    ->生成 Makefile, config.log, 和 config.status

  • 相关阅读:
    C#数组添加元素
    C#数组排序方法
    C#遍历数组
    C#动态数组ArrayList
    C#传递数组参数
    基础题(四)
    基础题(三)
    CMDB概述(二)
    CMDB概述(一)
    Django(基础篇)
  • 原文地址:https://www.cnblogs.com/greencolor/p/2105820.html
Copyright © 2011-2022 走看看