Commit 872fb1e2 authored by Eric Fossum's avatar Eric Fossum

Another attempt to get this build to work across platforms...

parent fc4489fc
......@@ -11,9 +11,7 @@ beaglebone:
- make test
raspberry:
image: armhf/alpine
tags:
- docker
- raspberry
- emc1072
variables:
......@@ -23,9 +21,7 @@ raspberry:
- make test
particle:
image: armhf/alpine
tags:
- docker
- particle
- emc1072
variables:
......
......@@ -75,12 +75,12 @@ ${CND_DISTDIR}/${CND_CONF}/${CND_PLATFORM}/libemc1072.${CND_DLIB_EXT}: ${OBJECTF
${MKDIR} -p ${CND_DISTDIR}/${CND_CONF}/${CND_PLATFORM}
${LINK.cc} -o ${CND_DISTDIR}/${CND_CONF}/${CND_PLATFORM}/libemc1072.${CND_DLIB_EXT} ${OBJECTFILES} ${LDLIBSOPTIONS} -v -shared -fPIC
${OBJECTDIR}/src/emc1072.o: src/emc1072.cpp
${OBJECTDIR}/src/emc1072.o: src/emc1072.cpp nbproject/Makefile-${CND_CONF}.mk
${MKDIR} -p ${OBJECTDIR}/src
${RM} "$@.d"
$(COMPILE.cc) -g -Iinclude -std=c++98 -fPIC -MMD -MP -MF "$@.d" -o ${OBJECTDIR}/src/emc1072.o src/emc1072.cpp
${OBJECTDIR}/src/linux-i2c.o: src/linux-i2c.cpp
${OBJECTDIR}/src/linux-i2c.o: src/linux-i2c.cpp nbproject/Makefile-${CND_CONF}.mk
${MKDIR} -p ${OBJECTDIR}/src
${RM} "$@.d"
$(COMPILE.cc) -g -Iinclude -std=c++98 -fPIC -MMD -MP -MF "$@.d" -o ${OBJECTDIR}/src/linux-i2c.o src/linux-i2c.cpp
......
......@@ -37,16 +37,20 @@
displayName="Important Files"
projectFiles="false"
kind="IMPORTANT_FILES_FOLDER">
<itemPath>.gitlab-ci.yml</itemPath>
<itemPath>Makefile</itemPath>
</logicalFolder>
</logicalFolder>
<sourceRootList>
<Elem>.</Elem>
</sourceRootList>
<projectmakefile>Makefile</projectmakefile>
<confs>
<conf name="Debug" type="2">
<toolsSet>
<compilerSet>GNU|GNU</compilerSet>
<dependencyChecking>true</dependencyChecking>
<rebuildPropChanged>false</rebuildPropChanged>
<rebuildPropChanged>true</rebuildPropChanged>
</toolsSet>
<compileType>
<cTool>
......
......@@ -9,7 +9,9 @@
<header-extensions>h</header-extensions>
<sourceEncoding>UTF-8</sourceEncoding>
<make-dep-projects/>
<sourceRootList/>
<sourceRootList>
<sourceRootElem>.</sourceRootElem>
</sourceRootList>
<confList>
<confElem>
<name>Debug</name>
......
......@@ -14,11 +14,15 @@
#include "emc1072testclass.h"
#include <ctime>
#include <stdlib.h>
CPPUNIT_TEST_SUITE_REGISTRATION(emc1072testclass);
emc1072testclass::emc1072testclass() {
i2c_dev = std::getenv("I2C_BUS");
char *dev = std::getenv("I2C_BUS");
if (dev) {
i2c_dev = dev;
}
}
emc1072testclass::~emc1072testclass() {
......
......@@ -8,12 +8,16 @@
#include "linuxi2ctestclass.h"
#include <cstdlib>
#include <stdlib.h>
CPPUNIT_TEST_SUITE_REGISTRATION(linuxi2ctestclass);
linuxi2ctestclass::linuxi2ctestclass() {
i2c_dev = std::getenv("I2C_BUS");
char *dev = std::getenv("I2C_BUS");
if (dev) {
i2c_dev = dev;
}
std::cout << "I2C Bus " << i2c_dev << std::endl;
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment