libupm: update to 2.0.0
Signed-off-by: Hirokazu MORIKAWA <morikw2@gmail.com>
This commit is contained in:
parent
59c9ec6bfe
commit
6e6740b0a5
3 changed files with 116 additions and 9 deletions
|
@ -8,12 +8,12 @@
|
||||||
include $(TOPDIR)/rules.mk
|
include $(TOPDIR)/rules.mk
|
||||||
|
|
||||||
PKG_NAME:=libupm
|
PKG_NAME:=libupm
|
||||||
PKG_VERSION:=1.7.1
|
PKG_VERSION:=2.0.0
|
||||||
PKG_RELEASE:=1
|
PKG_RELEASE:=1
|
||||||
|
|
||||||
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
|
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
|
||||||
PKG_SOURCE_URL:=https://codeload.github.com/intel-iot-devkit/upm/tar.gz/v$(PKG_VERSION)?
|
PKG_SOURCE_URL:=https://codeload.github.com/intel-iot-devkit/upm/tar.gz/v$(PKG_VERSION)?
|
||||||
PKG_HASH:=b253742b01146f4b86e20714aa24e75ca1e9d46629eab9aa8db070ce94cf3619
|
PKG_HASH:=7dd2f4165b71e071d100b58d6a392f3cf57b0f257c82ffabf49e931b5ed6bc23
|
||||||
PKG_BUILD_DIR:=$(BUILD_DIR)/upm-$(PKG_VERSION)
|
PKG_BUILD_DIR:=$(BUILD_DIR)/upm-$(PKG_VERSION)
|
||||||
|
|
||||||
PKG_MAINTAINER:=John Crispin <blogic@openwrt.org>, Hirokazu MORIKAWA <morikw2@gmail.com>
|
PKG_MAINTAINER:=John Crispin <blogic@openwrt.org>, Hirokazu MORIKAWA <morikw2@gmail.com>
|
||||||
|
@ -21,7 +21,9 @@ PKG_LICENSE:=MIT
|
||||||
PKG_LICENSE_FILES:=LICENSE
|
PKG_LICENSE_FILES:=LICENSE
|
||||||
|
|
||||||
CMAKE_INSTALL:=1
|
CMAKE_INSTALL:=1
|
||||||
|
CMAKE_BINARY_SUBDIR:=build
|
||||||
PKG_USE_MIPS16:=0
|
PKG_USE_MIPS16:=0
|
||||||
|
PKG_BUILD_PARALLEL:=1
|
||||||
|
|
||||||
include $(INCLUDE_DIR)/package.mk
|
include $(INCLUDE_DIR)/package.mk
|
||||||
include $(INCLUDE_DIR)/cmake.mk
|
include $(INCLUDE_DIR)/cmake.mk
|
||||||
|
@ -33,9 +35,7 @@ UPM_MODULES:= \
|
||||||
adxrs610 am2315 apa102 apds9002 apds9930 at42qt1070 bh1749 bh1750 bh1792 biss0001 bma220 \
|
adxrs610 am2315 apa102 apds9002 apds9930 at42qt1070 bh1749 bh1750 bh1792 biss0001 bma220 \
|
||||||
bma250e bmg160 bmi160 bmm150 bmp280 bmpx8x bmx055 bno055 button buzzer cjq4435 collision \
|
bma250e bmg160 bmi160 bmm150 bmp280 bmpx8x bmx055 bno055 button buzzer cjq4435 collision \
|
||||||
cwlsxxa dfrec dfrorp dfrph ds1307 ds1808lc ds18b20 ds2413 ecezo ecs1030 \
|
cwlsxxa dfrec dfrorp dfrph ds1307 ds1808lc ds18b20 ds2413 ecezo ecs1030 \
|
||||||
ehr eldriver electromagnet emg enc03r flex gas gp2y0a gprs grove grovecollision groveehr \
|
ehr eldriver electromagnet emg enc03r flex gas gp2y0a gprs \
|
||||||
groveeldriver groveelectromagnet groveemg grovegprs grovegsr grovelinefinder grovemd \
|
|
||||||
grovemoisture groveo2 grovescam grovespeaker groveultrasonic grovevdiv grovewater grovewfs \
|
|
||||||
gsr guvas12d h3lis331dl hcsr04 hdc1000 hdxxvxta hka5 hlg150h hm11 hmc5883l hmtrp hp20x \
|
gsr guvas12d h3lis331dl hcsr04 hdc1000 hdxxvxta hka5 hlg150h hm11 hmc5883l hmtrp hp20x \
|
||||||
ht9170 htu21d hx711 ili9341 ims ina132 interfaces isd1820 itg3200 jhd1313m1 joystick12 kx122 \
|
ht9170 htu21d hx711 ili9341 ims ina132 interfaces isd1820 itg3200 jhd1313m1 joystick12 kx122 \
|
||||||
kxcjk1013 kxtj3 l298 l3gd20 lcd lcdks lcm1602 ldt0028 led lidarlitev3 light linefinder lis2ds12 \
|
kxcjk1013 kxtj3 l298 l3gd20 lcd lcdks lcm1602 ldt0028 led lidarlitev3 light linefinder lis2ds12 \
|
||||||
|
@ -51,6 +51,7 @@ UPM_MODULES:= \
|
||||||
veml6070 water waterlevel wfs wheelencoder wt5001 xbee yg1006 zfm20 \
|
veml6070 water waterlevel wfs wheelencoder wt5001 xbee yg1006 zfm20 \
|
||||||
vcap t3311 hwxpxx h803x ozw curieimu
|
vcap t3311 hwxpxx h803x ozw curieimu
|
||||||
# (require libbacnet) tb7300 t8100 e50hx bacnetmstp
|
# (require libbacnet) tb7300 t8100 e50hx bacnetmstp
|
||||||
|
# (require libtinyb) 2jciebu01_ble 2jciebu01_usb
|
||||||
|
|
||||||
define Package/libupm/Default
|
define Package/libupm/Default
|
||||||
SECTION:=libs
|
SECTION:=libs
|
||||||
|
@ -96,7 +97,7 @@ endef
|
||||||
|
|
||||||
define Package/libupm/install/Default-python
|
define Package/libupm/install/Default-python
|
||||||
$(INSTALL_DIR) $(1)/usr/lib/python$(PYTHON_VERSION)/site-packages/upm
|
$(INSTALL_DIR) $(1)/usr/lib/python$(PYTHON_VERSION)/site-packages/upm
|
||||||
$(CP) $(PKG_BUILD_DIR)/src/$(2)/python$(PYTHON_VERSION)/pyupm_$(2).py \
|
$(CP) $(CMAKE_BINARY_DIR)/$(if $(filter interfaces, $(2)),,src/)$(2)/python$(PYTHON_VERSION)/pyupm_$(2).py \
|
||||||
$(1)/usr/lib/python$(PYTHON_VERSION)/site-packages/upm/
|
$(1)/usr/lib/python$(PYTHON_VERSION)/site-packages/upm/
|
||||||
$(CP) $(PKG_INSTALL_DIR)/usr/lib/python$(PYTHON_VERSION)/site-packages/upm/_pyupm_$(2).so \
|
$(CP) $(PKG_INSTALL_DIR)/usr/lib/python$(PYTHON_VERSION)/site-packages/upm/_pyupm_$(2).so \
|
||||||
$(1)/usr/lib/python$(PYTHON_VERSION)/site-packages/upm/ ;
|
$(1)/usr/lib/python$(PYTHON_VERSION)/site-packages/upm/ ;
|
||||||
|
@ -104,7 +105,7 @@ endef
|
||||||
|
|
||||||
define Package/libupm/install/Default-python3
|
define Package/libupm/install/Default-python3
|
||||||
$(INSTALL_DIR) $(1)/usr/lib/python$(PYTHON3_VERSION)/site-packages/upm
|
$(INSTALL_DIR) $(1)/usr/lib/python$(PYTHON3_VERSION)/site-packages/upm
|
||||||
$(CP) $(PKG_BUILD_DIR)/src/$(2)/python$(PYTHON3_VERSION)/pyupm_$(2).py \
|
$(CP) $(CMAKE_BINARY_DIR)/$(if $(filter interfaces, $(2)),,src/)$(2)/python$(PYTHON3_VERSION)/pyupm_$(2).py \
|
||||||
$(1)/usr/lib/python$(PYTHON3_VERSION)/site-packages/upm/
|
$(1)/usr/lib/python$(PYTHON3_VERSION)/site-packages/upm/
|
||||||
$(CP) $(PKG_INSTALL_DIR)/usr/lib/python$(PYTHON3_VERSION)/site-packages/upm/_pyupm_$(2).so \
|
$(CP) $(PKG_INSTALL_DIR)/usr/lib/python$(PYTHON3_VERSION)/site-packages/upm/_pyupm_$(2).so \
|
||||||
$(1)/usr/lib/python$(PYTHON3_VERSION)/site-packages/upm/ ;
|
$(1)/usr/lib/python$(PYTHON3_VERSION)/site-packages/upm/ ;
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
--- a/CMakeLists.txt
|
--- a/CMakeLists.txt
|
||||||
+++ b/CMakeLists.txt
|
+++ b/CMakeLists.txt
|
||||||
@@ -225,14 +225,7 @@ include(GNUInstallDirs)
|
@@ -231,14 +231,7 @@
|
||||||
set (LIB_INSTALL_DIR "${CMAKE_INSTALL_LIBDIR}" CACHE PATH "Installation path for libraries")
|
set (LIB_INSTALL_DIR "${CMAKE_INSTALL_LIBDIR}" CACHE PATH "Installation path for libraries")
|
||||||
|
|
||||||
# Make a version file containing the current version from git.
|
# Make a version file containing the current version from git.
|
||||||
|
@ -9,10 +9,10 @@
|
||||||
-# If git_describe fails, use a dirty version
|
-# If git_describe fails, use a dirty version
|
||||||
-if (${VERSION} MATCHES -NOTFOUND)
|
-if (${VERSION} MATCHES -NOTFOUND)
|
||||||
- set (VERSION "v1.7.1")
|
- set (VERSION "v1.7.1")
|
||||||
|
+ set (VERSION "v2.0.0")
|
||||||
- message (WARNING "Failed to retrieve UPM version with 'git describe' (using "
|
- message (WARNING "Failed to retrieve UPM version with 'git describe' (using "
|
||||||
- "${VERSION}). Check that git is installed and this is a valid git repo.")
|
- "${VERSION}). Check that git is installed and this is a valid git repo.")
|
||||||
-endif ()
|
-endif ()
|
||||||
+set (VERSION "v1.7.1")
|
|
||||||
|
|
||||||
message (STATUS "UPM Version ${VERSION}")
|
message (STATUS "UPM Version ${VERSION}")
|
||||||
|
|
||||||
|
|
106
libs/libupm/patches/004-uint8_t.patch
Normal file
106
libs/libupm/patches/004-uint8_t.patch
Normal file
|
@ -0,0 +1,106 @@
|
||||||
|
diff -urN a/src/bma250e/bma250e.cxx b/src/bma250e/bma250e.cxx
|
||||||
|
--- a/src/bma250e/bma250e.cxx 2019-05-09 00:06:25.000000000 +0900
|
||||||
|
+++ b/src/bma250e/bma250e.cxx 2019-05-13 16:43:04.344536227 +0900
|
||||||
|
@@ -195,35 +195,35 @@
|
||||||
|
fifoConfig(mode, axes);
|
||||||
|
}
|
||||||
|
if(tok.substr(0, 20) == "setInterruptEnable0:") {
|
||||||
|
- u_int8_t bits = (u_int8_t)std::stoul(tok.substr(20), nullptr, 0);
|
||||||
|
+ uint8_t bits = (uint8_t)std::stoul(tok.substr(20), nullptr, 0);
|
||||||
|
setInterruptEnable0(bits);
|
||||||
|
}
|
||||||
|
if(tok.substr(0, 20) == "setInterruptEnable1:") {
|
||||||
|
- u_int8_t bits = (u_int8_t)std::stoul(tok.substr(20), nullptr, 0);
|
||||||
|
+ uint8_t bits = (uint8_t)std::stoul(tok.substr(20), nullptr, 0);
|
||||||
|
setInterruptEnable1(bits);
|
||||||
|
}
|
||||||
|
if(tok.substr(0, 20) == "setInterruptEnable2:") {
|
||||||
|
- u_int8_t bits = (u_int8_t)std::stoul(tok.substr(20), nullptr, 0);
|
||||||
|
+ uint8_t bits = (uint8_t)std::stoul(tok.substr(20), nullptr, 0);
|
||||||
|
setInterruptEnable2(bits);
|
||||||
|
}
|
||||||
|
if(tok.substr(0, 17) == "setInterruptMap0:") {
|
||||||
|
- u_int8_t bits = (u_int8_t)std::stoul(tok.substr(17), nullptr, 0);
|
||||||
|
+ uint8_t bits = (uint8_t)std::stoul(tok.substr(17), nullptr, 0);
|
||||||
|
setInterruptMap0(bits);
|
||||||
|
}
|
||||||
|
if(tok.substr(0, 17) == "setInterruptMap1:") {
|
||||||
|
- u_int8_t bits = (u_int8_t)std::stoul(tok.substr(17), nullptr, 0);
|
||||||
|
+ uint8_t bits = (uint8_t)std::stoul(tok.substr(17), nullptr, 0);
|
||||||
|
setInterruptMap1(bits);
|
||||||
|
}
|
||||||
|
if(tok.substr(0, 17) == "setInterruptMap2:") {
|
||||||
|
- u_int8_t bits = (u_int8_t)std::stoul(tok.substr(17), nullptr, 0);
|
||||||
|
+ uint8_t bits = (uint8_t)std::stoul(tok.substr(17), nullptr, 0);
|
||||||
|
setInterruptMap2(bits);
|
||||||
|
}
|
||||||
|
if(tok.substr(0, 16) == "setInterruptSrc:") {
|
||||||
|
- u_int8_t bits = (u_int8_t)std::stoul(tok.substr(16), nullptr, 0);
|
||||||
|
+ uint8_t bits = (uint8_t)std::stoul(tok.substr(16), nullptr, 0);
|
||||||
|
setInterruptSrc(bits);
|
||||||
|
}
|
||||||
|
if(tok.substr(0, 26) == "setInterruptOutputControl:") {
|
||||||
|
- u_int8_t bits = (u_int8_t)std::stoul(tok.substr(26), nullptr, 0);
|
||||||
|
+ uint8_t bits = (uint8_t)std::stoul(tok.substr(26), nullptr, 0);
|
||||||
|
setInterruptOutputControl(bits);
|
||||||
|
}
|
||||||
|
if(tok.substr(0, 26) == "setInterruptLatchBehavior:") {
|
||||||
|
diff -urN a/src/bmg160/bmg160.cxx b/src/bmg160/bmg160.cxx
|
||||||
|
--- a/src/bmg160/bmg160.cxx 2019-05-09 00:06:25.000000000 +0900
|
||||||
|
+++ b/src/bmg160/bmg160.cxx 2019-05-13 16:44:25.516304666 +0900
|
||||||
|
@@ -173,23 +173,23 @@
|
||||||
|
fifoConfig(mode, axes);
|
||||||
|
}
|
||||||
|
if(tok.substr(0, 20) == "setInterruptEnable0:") {
|
||||||
|
- u_int8_t bits = (u_int8_t)std::stoul(tok.substr(20), nullptr, 0);
|
||||||
|
+ uint8_t bits = (uint8_t)std::stoul(tok.substr(20), nullptr, 0);
|
||||||
|
setInterruptEnable0(bits);
|
||||||
|
}
|
||||||
|
if(tok.substr(0, 17) == "setInterruptMap0:") {
|
||||||
|
- u_int8_t bits = (u_int8_t)std::stoul(tok.substr(17), nullptr, 0);
|
||||||
|
+ uint8_t bits = (uint8_t)std::stoul(tok.substr(17), nullptr, 0);
|
||||||
|
setInterruptMap0(bits);
|
||||||
|
}
|
||||||
|
if(tok.substr(0, 17) == "setInterruptMap1:") {
|
||||||
|
- u_int8_t bits = (u_int8_t)std::stoul(tok.substr(17), nullptr, 0);
|
||||||
|
+ uint8_t bits = (uint8_t)std::stoul(tok.substr(17), nullptr, 0);
|
||||||
|
setInterruptMap1(bits);
|
||||||
|
}
|
||||||
|
if(tok.substr(0, 16) == "setInterruptSrc:") {
|
||||||
|
- u_int8_t bits = (u_int8_t)std::stoul(tok.substr(16), nullptr, 0);
|
||||||
|
+ uint8_t bits = (uint8_t)std::stoul(tok.substr(16), nullptr, 0);
|
||||||
|
setInterruptSrc(bits);
|
||||||
|
}
|
||||||
|
if(tok.substr(0, 26) == "setInterruptOutputControl:") {
|
||||||
|
- u_int8_t bits = (u_int8_t)std::stoul(tok.substr(26), nullptr, 0);
|
||||||
|
+ uint8_t bits = (uint8_t)std::stoul(tok.substr(26), nullptr, 0);
|
||||||
|
setInterruptOutputControl(bits);
|
||||||
|
}
|
||||||
|
if(tok.substr(0, 26) == "setInterruptLatchBehavior:") {
|
||||||
|
diff -urN a/src/bmm150/bmm150.cxx b/src/bmm150/bmm150.cxx
|
||||||
|
--- a/src/bmm150/bmm150.cxx 2019-05-09 00:06:25.000000000 +0900
|
||||||
|
+++ b/src/bmm150/bmm150.cxx 2019-05-13 16:45:03.228197100 +0900
|
||||||
|
@@ -170,19 +170,19 @@
|
||||||
|
setOpmode(opmode);
|
||||||
|
}
|
||||||
|
if(tok.substr(0, 19) == "setInterruptEnable:") {
|
||||||
|
- u_int8_t bits = (u_int8_t)std::stoul(tok.substr(19), nullptr, 0);
|
||||||
|
+ uint8_t bits = (uint8_t)std::stoul(tok.substr(19), nullptr, 0);
|
||||||
|
setInterruptEnable(bits);
|
||||||
|
}
|
||||||
|
if(tok.substr(0, 19) == "setInterruptConfig:") {
|
||||||
|
- u_int8_t bits = (u_int8_t)std::stoul(tok.substr(19), nullptr, 0);
|
||||||
|
+ uint8_t bits = (uint8_t)std::stoul(tok.substr(19), nullptr, 0);
|
||||||
|
setInterruptConfig(bits);
|
||||||
|
}
|
||||||
|
if(tok.substr(0, 17) == "setRepetitionsXY:") {
|
||||||
|
- u_int8_t reps = (u_int8_t)std::stoul(tok.substr(17), nullptr, 0);
|
||||||
|
+ uint8_t reps = (uint8_t)std::stoul(tok.substr(17), nullptr, 0);
|
||||||
|
setRepetitionsXY(reps);
|
||||||
|
}
|
||||||
|
if(tok.substr(0, 16) == "setRepetitionsZ:") {
|
||||||
|
- u_int8_t reps = (u_int8_t)std::stoul(tok.substr(16), nullptr, 0);
|
||||||
|
+ uint8_t reps = (uint8_t)std::stoul(tok.substr(16), nullptr, 0);
|
||||||
|
setRepetitionsZ(reps);
|
||||||
|
}
|
||||||
|
if(tok.substr(0, 14) == "setPresetMode:") {
|
Loading…
Reference in a new issue