繁体   English   中英

travis CI不能在GitHub上使用C编译器吗?

[英]travis CI did not work with C compiler on GitHub?

travis CI不适用于C编译器。

.travis.yml:

sudo: required

language: c
 os:
   - linux

compiler:
   - gcc

GitHib回购链接: 算法

travis CI错误:

travis_time:end:0dcb3648:start=1438359476527442359,finish=1438359476614557866,duration=87115507
[0K$ cd piyush-maurya/algorithms
$ git checkout -qf 37da548d8f6e1ced6df4b3e22e2b5afd5435c2a2
travis_fold:end:git.checkout
[0K$ export CC=gcc
$ gcc --version
gcc (Ubuntu/Linaro 4.6.3-1ubuntu5) 4.6.3
Copyright (C) 2011 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

travis_time:start:2b2b89e2
[0K$ ./configure && make && make test
/home/travis/build.sh: line 41: ./configure: No such file or directory
travis_time:end:2b2b89e2:start=1438359476633265005,finish=1438359476641026855,duration=7761850
[0K
[31;1mThe command "./configure && make && make test" exited with 127.[0m

Done. Your build exited with 1.

错误链接: travis CI错误日志

您尚未指定如何构建项目 对于C项目,默认值为标准的autotools样式./configure && make ,但是您的项目没有配置脚本(或Makefile)。

您可以添加类似

build: cc file1.c file2.c …

要直接调用C编译器,但是如果您希望该项目对其他人有用,则应提供一个Makefile(或使用诸如autotools,CMake,waf等构建系统),然后执行

build: make

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM