簡體   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