Skip to content

Commit

Permalink
Update from upstream to get ARM support fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
connorimes committed Oct 8, 2015
1 parent cc770dc commit 3ca261b
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 7 deletions.
7 changes: 7 additions & 0 deletions heartbeats-simple/.travis.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,12 @@
sudo: required

language: c

install:
- sudo add-apt-repository ppa:kubuntu-ppa/backports -y
- sudo apt-get update
- sudo apt-get install --only-upgrade cmake

script:
- mkdir _build
- cd _build
Expand Down
10 changes: 3 additions & 7 deletions heartbeats-simple/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
cmake_minimum_required(VERSION 2.8)
cmake_minimum_required(VERSION 2.8.9)

project(heartbeats-simple)
set(PROJECT_VERSION 0.1.0)
Expand All @@ -18,6 +18,8 @@ set(HBS_POW_SRC src/hb.c src/hb-util.c src/hb-pow-util.c)
set(HBS_POW_PROP HEARTBEAT_MODE_POW;HEARTBEAT_USE_POW)
set(HBS_ACC_POW_SRC src/hb.c src/hb-util.c src/hb-acc-util.c src/hb-pow-util.c)
set(HBS_ACC_POW_PROP HEARTBEAT_MODE_ACC_POW;HEARTBEAT_USE_ACC;HEARTBEAT_USE_POW)
# force fPIC on static libs
set(CMAKE_POSITION_INDEPENDENT_CODE TRUE)

add_library(hbs SHARED ${HBS_SRC})
add_library(hbs-static STATIC ${HBS_SRC})
Expand All @@ -37,12 +39,6 @@ set_target_properties(hbs-acc-pow PROPERTIES COMPILE_DEFINITIONS "${HBS_ACC_POW_
add_library(hbs-acc-pow-static STATIC ${HBS_ACC_POW_SRC})
set_target_properties(hbs-acc-pow-static PROPERTIES COMPILE_DEFINITIONS "${HBS_ACC_POW_PROP}")

# Required to force fPIC on static libs
# 'set (CMAKE_POSITION_INDEPENDENT_CODE TRUE)' not supported until cmake 2.8.9
IF(CMAKE_SYSTEM_PROCESSOR STREQUAL "x86_64")
SET_TARGET_PROPERTIES(hbs-static hbs-acc-static hbs-pow-static hbs-acc-pow-static PROPERTIES COMPILE_FLAGS "-fPIC")
ENDIF(CMAKE_SYSTEM_PROCESSOR STREQUAL "x86_64")

# Examples

add_executable(hb-pow-example example/hb-pow-example.c)
Expand Down

0 comments on commit 3ca261b

Please sign in to comment.