懒人学习automake, Makefile.am,configure.ac
已经存在Makefile.am,如何生成Makefile?
步骤:
- [root@localhost hello]# autoscan .///在当前文件夹中搜索
- [root@localhost hello]# cp configure.scan configure.ac //复制文件
- [root@localhost hello]# vi configure.ac //编辑文件
- 编辑configure.ac,加入下面一行:
- AM_INIT_AUTOMAKE(hello,1.0) //automake所必备的宏,必须添加
- [root@localhost hello]# aclocal //执行aclocal生成aclocal.m4文件
- [root@localhost hello]# autoconf //执行autoconf生成configure文件
- [root@localhost hello]# autoheader
- [root@localhost hello]# automake --add-missing
- [root@localhost hello]# touch NEWS; touch README; touch AUTHORS; touch ChangeLog //创建NEWS等文件,如果没有自动生成,手工创建
- [root@localhost hello]# automake --add-missing //再运行一次
- [root@localhost hello]# ./configure //配置,生成Makefile文件
- [root@localhost hello]# make //执行make命令
以上过程可能出现一些警告,请忽略。最后,给出一个Makefile.am的内容作为例子:
- AM_LDFLAGS = -lpthread -lc -lm -lrt -ldl
- CXXFLAGS = -D__STDC_LIMIT_MACROS -g -Wall -DORDER_SERIALIZE #-O2 -fno-strict-aliasing
- bin_PROGRAMS = parser_main
- parser_main_SOURCES = parser_main.cpp \
- Parser.cpp \
- Lexer.cpp \
- SelectStmt.cpp \
- InsertStmt.cpp \
- UpdateStmt.cpp \
- DeleteStmt.cpp \
- Stmt.cpp \
- Expr.cpp \
- Identifier.cpp
- ~
参考文献:
http://os.51cto.com/art/201006/207098.htm
http://os.51cto.com/art/201006/207099.htm
http://os.51cto.com/art/201006/207101.htm
懒人学习automake, Makefile.am,configure.ac的更多相关文章
- 懒人学习automake, Makefile.am,configure.ac(转)
已经存在Makefile.am,如何生成Makefile? 步骤: [root@localhost hello]# autoscan .///在当前文件夹中搜索 [root@localhost hel ...
- automake中Makefile.am和configure.ac的格式及编译过程
step1:写Makefile.am step2:执行autoscan,会生成configurae.scan,修改configure.scan内容之后,命名为configure.ac step3:执行 ...
- configure.ac和Makefile.am的格式解析概述
1. configure.ac和Makefile.am的格式解析概述 1.1. Autotools相关工具链 1.1.1. Autotools 1.1.2. 其他相关工具 1.2. 工具链的流程 1. ...
- C# 嵌入dll 动软代码生成器基础使用 系统缓存全解析 .NET开发中的事务处理大比拼 C#之数据类型学习 【基于EF Core的Code First模式的DotNetCore快速开发框架】完成对DB First代码生成的支持 基于EF Core的Code First模式的DotNetCore快速开发框架 【懒人有道】在asp.net core中实现程序集注入
C# 嵌入dll 在很多时候我们在生成C#exe文件时,如果在工程里调用了dll文件时,那么如果不加以处理的话在生成的exe文件运行时需要连同这个dll一起转移,相比于一个单独干净的exe,这种形 ...
- 如何根据configure.ac和Makefile.am为开源代码产生当前平台的Makefile
1 2 3 4 5 6 7 8 9 //根据configure.in和Makefile.am生成makefile的步骤,基于UBUNTU 12.04 1.autoscan (可选) 2.aclocal ...
- 关于Makefile,Makefile.in,Makefile.am,Configure功能及相互关系的问题
makefile写法 在 Unix 上写程式的人大概都碰过 Makefile,尤其是用 C 来开发程式的人.用 make来开发和编译程式的确很方便,可是要写出一个 Makefile就不简单了.偏偏介绍 ...
- 编写configure.ac
configure.ac由一些宏组成(如果已经有源代码,你可以运行autoscan来产生一个configure.scan文件,在此基础修改成configure.ac将更加方便) 最基本的组成可以是下面 ...
- 源码编译Redis Desktop Manager | 懒人屋
原文:源码编译Redis Desktop Manager | 懒人屋 源码编译Redis Desktop Manager 2.3k 字 10 分钟 2019-10-10 文章背景 本 ...
- 【转】[教程]在 win7 / win8 下安装苹果系统 (懒人版)
前言 这篇安装教程的素材在国庆就准备好了,但那时学习任务比较重,没有时间发帖,一直拖到现在.趁这个周末有空,赶紧写完它,希望能帮助一些景友. 论坛已经有不少安装教程,如果对这篇安装教程有疑问可以去 ...
随机推荐
- js继承的方式
深入理解继承的实现方式不仅仅有利于自己去造轮子,封装插件,更有利于我们去阅读一些框架的源码, 以下记录几种常见的继承方式 1. 原型链实现继承 function Father(){ this.name ...
- svn更新报错Please execute the 'Cleanup' command.
更新svn报错 要Clearnup一下就可以再更新了 点击svn中 clear up ok之后恢复正常
- Luogu P1692 部落卫队
解题思路 数据范围不是很大,那应该不是那些普遍的图论的算法.考虑搜索,用暴力解决.从1到N枚举每一个点的位置,搜索这个点事选还是不选.如果在这个点之前选到的点中又和他冲突的点,那就不选,要么就选. 附 ...
- python3.x Day2 购物车程序练习
购物车程序: 1.启动程序后,输入用户名密码后,如果是第一次登录,让用户输入工资,然后打印商品列表 2.允许用户根据商品编号购买商品 3.用户选择商品后,检测余额是否够,够就直接扣款,不够就提醒 4. ...
- JDBC插入数据时中文变为问号的解决方法
JDBC插入数据时中文变为问号的解决方法 制作人:全心全意 出现中文变问号的代码: String url = "jdbc:mysql://localhost:3306/test"; ...
- vue-cli中src/main.js 的作用
// The Vue build version to load with the `import` command // (runtime-only or standalone) has been ...
- ndk编译libpcap 1.7.4
android完全菜鸟,绝对的第一次接触,想做手机抓包,在网上搜又是NDK 又是JNI 又是JNETPCAP 完全蒙了,让我这种android和java都弄不明白什么关系的人情何以堪! 静下心想一想, ...
- Oracle操作管理之用户和角色
1.用户管理 (1)建立用户(数据库验证) CREATE USER smith IDENTIFIED BY smith_pwd DEFAULTTABLESPACE users TEMPORARY TA ...
- N的倍数
题目来源: Ural 1302 基准时间限制:1 秒 空间限制:131072 KB 分值: 40 难度:4级算法题 一个长度为N的数组A,从A中选出若干个数,使得这些数的和是N的倍数. 例如:N = ...
- code wars quiz: toInteger
Your task is to program a function which converts any input to an integer. Do not perform rounding, ...