Skip to content

Commit

Permalink
Release binaries and unittest on mac (#60)
Browse files Browse the repository at this point in the history
* upload unabto_tunnel on releases

* build matrix update

* travis update

* travis update

* travis update

* appveyor update

* travis update

* travis update

* unittest linker flags for mac

* travis update

* travis update

* travis update

* travis update
  • Loading branch information
fusionfoxy committed Dec 14, 2017
1 parent 94db573 commit 900a570
Show file tree
Hide file tree
Showing 3 changed files with 25 additions and 6 deletions.
24 changes: 21 additions & 3 deletions .travis.yml
Expand Up @@ -2,13 +2,17 @@ language: c

matrix:
include:
- compiler: gcc
- os: linux
compiler: gcc
env: CFLAGS="-std=gnu99"
- compiler: clang
- os: linux
compiler: clang
env: CFLAGS="-std=gnu99"
# test that we can compile on old compilers.
- compiler: clang
- os: linux
compiler: clang
env: CFLAGS="-std=c89 -Wno-endif-labels -D_POSIX_C_SOURCE=200809L -D_DEFAULT_SOURCE -D_BSD_SOURCE -Wno-comment"
- os: osx

addons:
apt:
Expand All @@ -26,3 +30,17 @@ script:
- cd cibuild
- cmake .. && make -j VERBOSE=1
- ./test/unittest/unabto_unittest
- mkdir -p bin
- cp apps/tunnel/unabto_tunnel bin/unabto_tunnel_${TRAVIS_OS_NAME}

deploy:
provider: releases
api_key:
secure: wDgmZWEIp9YqVIaE/RvDqG6CdENT9+omuUuavEf3ttHS8eOJSp4XUxvLZnNqLMS7mjA36uLFwAxlQ2/b7R4IIRf/v0L9zc24yUbuff2pZUxyfYHq9UVJtsm/KWEgBs8X+oinCVBevoGx1HyvNARf4Jt2jtFW2kOYyJGWugRhInWE7wRx/bTch5eMhw80E97ATQlcnb9dtnQa4I1mkYty0qwO3n+LQbyDMpEF6vHk4z/7vaCehIOofFAJJwDv5Trci3qzr/Z3kgfD6ZUXefa1ffh3LuxY8kAmkHea2Gp1G2rFr/Uotus1t89klrskMZHb7Y/ci2kWcU9S8o7NXInn7+hN5t/AYSeY/gPyYo9ZIePYOJLXoip3B2yvXJPD+b4ImOEot2faiqj2p6x9F4gIbaoXRKXsZeHV+MKVTD8W3E6IPFU/6wWr4V/VBeNtn2tgew51s84/Q/VaoJJqxSHisNZhY28rK3tQkX0fZXRH7HH3SQm8p5XMPL7sEr1X7FcGsi6jLCZYWB4ZDK3Ts32ULsyS5Fcnq77uPwHQVOwy/FY/W8Bj7N8qUQEDopdXU57R++uh6IqG23HIP7B/iAHEn2MGYhbh4k5Y1ZaGkRuhnv19nvp899WsLdYxA3JWVYhkhuCPJswMjyF0ddKUf7ZPVm6aehSN9AXipYvddlzY86I=
skip_cleanup: true
file:
- ${TRAVIS_BUILD_DIR}/cibuild/bin/unabto_tunnel_${TRAVIS_OS_NAME}
on:
repo: nabto/unabto
tags: true
all_branches: true
1 change: 0 additions & 1 deletion appveyor.yml
Expand Up @@ -25,5 +25,4 @@ deploy:
prerelease: false
force_update: true
on:
branch: master # release from master branch only
appveyor_repo_tag: true
6 changes: 4 additions & 2 deletions test/unittest/CMakeLists.txt
Expand Up @@ -52,10 +52,12 @@ endif()

add_executable(${PROJECT_NAME} ${src})

if (NOT MSVC)
if (MSVC)
target_link_libraries(${PROJECT_NAME} Ws2_32)
elseif(${CMAKE_SYSTEM_NAME} MATCHES "Linux")
target_link_libraries(${PROJECT_NAME} pthread rt m)
else()
target_link_libraries(${PROJECT_NAME} Ws2_32)
target_link_libraries(${PROJECT_NAME} pthread m)
endif()

install( TARGETS ${PROJECT_NAME}
Expand Down

0 comments on commit 900a570

Please sign in to comment.