I have three files to compile: main.c, func.c,  func.h

The steps:

1   main.c   to   main.o

2   func.c    to   func.o

3    link main.o func.o to main(file that can execute)

So, u need to run at least three commands without a Makefile.Then if u have 100 files to compile, how to do?

If u have a Makefile, u just need to type one word 'make'.

EASY

And I writed a Makefile:

test:

My first makefile to compile multiple C files的更多相关文章

  1. Linux Compile Multiple C++ Files

    Compile Two Files: $ CC -c Main.cc Sales_item.cc # by default generates a.exe # some compilers gener ...

  2. TN035: Using Multiple Resource Files and Header Files with Visual C++

    TN035: Using Multiple Resource Files and Header Files with Visual C++ This note describes how the Vi ...

  3. Multiple dex files define Lcom/google/gson/internal/Streams$AppendableWriter$CurrentWrite;

    开发中引入第三方 aar 时编译同过,运行时出现问题: Multiple dex files define Lcom/google/gson/internal/Streams$AppendableWr ...

  4. Error:Error converting bytecode to dex: Cause: com.android.dex.DexException: Multiple dex files define Lcom/lidroid/xutils/task/TaskHandler;

    Error:Error converting bytecode to dex: Cause: com.android.dex.DexException: Multiple dex files defi ...

  5. Android Studio:Multiple dex files define Landroid/support/annotation/AnimRes

    近期真的比較忙,一不小心博客又荒了两个月. 从今天起.决定重返csdn,多多纪录和分享. 先从一个近期被折磨的死去活来的问题. 由于升级了V4包,就一直报这个问题: com.android.dex.D ...

  6. Android Studio com.android.dex.DexException: Multiple dex files define(重复引用包),androiddefine

    Android Studio com.android.dex.DexException: Multiple dex files define(重复引用包),androiddefine 如果你用Andr ...

  7. Android 友盟和微信的包冲突:Multiple dex files define Lcom/tencent/a/a/a/a/a;

    最近App中有个需求是添加微信支付,就在微信技术官网 http://open.weixin.qq.com,查看一下文档,然后下载SDk,Demo.把SDK集成进项目. 照着微信的文档,把jar包和进来 ...

  8. 解决com.android.dex.DexException: Multiple dex files define Lcom/google/gson/JsonSerializer;

    我在开发Windows Azure的Mobile Service(隔天补上创建过程)的安卓客户端时,报出了com.android.dex.DexException: Multiple dex file ...

  9. Multiple dex files define Lokhttp3/internal/wsWebSocketProtocol

    Multiple dex files define Lokhttp3/internal/wsWebSocketProtocol 老套路,先晒图 图一:如题,在编译打包时遇到了如上错误,很明显这是一个依 ...

随机推荐

  1. weibform中Application、ViewState对象和分页

    Application: 全局公共变量组 存放位置:服务器 特点:所有访问用户都是访问同一个变量,但只要服务器不停机,变量一直存在于服务器的内存中,不要使用循环大量的创建Application对象,可 ...

  2. javascript的对象

    简介: JavaScript 中的所有事物都是对象:字符串.数字.数组.日期,等等.在 JavaScript 中,对象是拥有属性和方法的数据. 一.对象的类型 本地对象:就是ECMA定义好的一些对象, ...

  3. iOS之 状态栏字体颜色的设置

    前一段时间接手一个项目后,熟悉的过程中发现了不少问题,其中有一个就是关于状态栏的问题. 我们都知道:状态栏字体颜色在不同界面不一样的,原因是系统设置的时候把状态栏的字体颜色的界面控制器设置的yes. ...

  4. 【算法杂谈】Miller-Rabin素性测试算法

    额,我们今天来讲一讲Miller-Rabin素性测试算法. 读者:怎么又是随机算法!!!(⊙o⊙)… [好了,言归正传] [费马小定理] 费马小定理只是个必要条件,符合费马小定理而非素数的数叫做Car ...

  5. 压力测试相关之ab命令

    1. 短时压力测试工具 ab 命令(apache的工具) 关键指标: Requests per second:    98.52 [#/sec] (mean)      ###平均每秒的请求数 Tim ...

  6. MongoDB实现分页(两种方法)

    1.插入实验数据 偷懒用下samus,100条. ; i < ; i++) { Document doc = new Document(); doc["ID"] = i; d ...

  7. mac osx 上面部署Django项目 apache+mysql+mod_wsgi

    1.安装Xcode command line tools 首先,编译mysql和Homebrew需要用到Xcode command line tools,所以首先安装command line tool ...

  8. C#在Linux+Mono环境中使用微信支付证书

    最近特殊的需求,要把微信平台一个功能页面部署到Linux(CentOS6.5)下,其中涉及到微信支付退款. 鉴于之前实践过mono+jexus+asp.net mvc的部署,于是问题重点在于解决对商户 ...

  9. centos 7 安装和配置vncserver

    前期准备: 关闭防火墙,centos的防火墙是firewalld,关闭防火墙的命令 systemctl stop firewalld.service 关闭enforce setenforce 0 ce ...

  10. JSON详解

    首先要知道JSON是一种轻量级的数据格式,不是一种编程语言,因此其他语言也可以使用. 一.JSON语法 JSON语法可以表现为下面三种值: 1.简单值:字符串.数值.布尔值和null,如"h ...