libftdi: initial commit, version 1.5
This commit is contained in:
parent
094f388c26
commit
981348e37b
31
libftdi/.footprint
Normal file
31
libftdi/.footprint
Normal file
@ -0,0 +1,31 @@
|
||||
drwxr-xr-x root/root lib/
|
||||
drwxr-xr-x root/root lib/udev/
|
||||
drwxr-xr-x root/root lib/udev/rules.d/
|
||||
-rw-r--r-- root/root lib/udev/rules.d/69-libftdi.rules
|
||||
drwxr-xr-x root/root usr/
|
||||
drwxr-xr-x root/root usr/bin/
|
||||
-rwxr-xr-x root/root usr/bin/ftdi_eeprom
|
||||
-rwxr-xr-x root/root usr/bin/libftdi1-config
|
||||
drwxr-xr-x root/root usr/include/
|
||||
drwxr-xr-x root/root usr/include/libftdi1/
|
||||
-rw-r--r-- root/root usr/include/libftdi1/ftdi.h
|
||||
-rw-r--r-- root/root usr/include/libftdi1/ftdi.hpp
|
||||
drwxr-xr-x root/root usr/lib/
|
||||
drwxr-xr-x root/root usr/lib/cmake/
|
||||
drwxr-xr-x root/root usr/lib/cmake/libftdi1/
|
||||
-rw-r--r-- root/root usr/lib/cmake/libftdi1/LibFTDI1Config.cmake
|
||||
-rw-r--r-- root/root usr/lib/cmake/libftdi1/LibFTDI1ConfigVersion.cmake
|
||||
-rw-r--r-- root/root usr/lib/cmake/libftdi1/UseLibFTDI1.cmake
|
||||
lrwxrwxrwx root/root usr/lib/libftdi1.so -> libftdi1.so.2
|
||||
lrwxrwxrwx root/root usr/lib/libftdi1.so.2 -> libftdi1.so.2.5.0
|
||||
-rwxr-xr-x root/root usr/lib/libftdi1.so.2.5.0
|
||||
lrwxrwxrwx root/root usr/lib/libftdipp1.so -> libftdipp1.so.3
|
||||
-rwxr-xr-x root/root usr/lib/libftdipp1.so.2.5.0
|
||||
lrwxrwxrwx root/root usr/lib/libftdipp1.so.3 -> libftdipp1.so.2.5.0
|
||||
drwxr-xr-x root/root usr/lib/pkgconfig/
|
||||
-rw-r--r-- root/root usr/lib/pkgconfig/libftdi1.pc
|
||||
-rw-r--r-- root/root usr/lib/pkgconfig/libftdipp1.pc
|
||||
drwxr-xr-x root/root usr/lib/python3.10/
|
||||
drwxr-xr-x root/root usr/lib/python3.10/site-packages/
|
||||
-rwxr-xr-x root/root usr/lib/python3.10/site-packages/_ftdi1.so
|
||||
-rw-r--r-- root/root usr/lib/python3.10/site-packages/ftdi1.py
|
6
libftdi/.signature
Normal file
6
libftdi/.signature
Normal file
@ -0,0 +1,6 @@
|
||||
untrusted comment: verify with /etc/ports/contrib.pub
|
||||
RWSagIOpLGJF38ApTH5YVi3GZEK7tAF8oy1s7Qu2oP/F9Qrai/ynxJdthu8YJDLsj/ZPgZq1vuwM4+Hl6tE4MrcaMIrlXYzf2wk=
|
||||
SHA256 (Pkgfile) = 8636e5c83ca7010b7a0a2e070c67a0665a9cf3113e7982ba575b97a2caffca19
|
||||
SHA256 (.footprint) = b68c710939deacf23af21be98ccf95c6eea00e2cc80815b4282e3b73d6dd3007
|
||||
SHA256 (libftdi1-1.5.tar.bz2) = 7c7091e9c86196148bd41177b4590dccb1510bfe6cea5bf7407ff194482eb049
|
||||
SHA256 (fix_includes_path.patch) = 065a157326f28c61d1ec470a3064b0cb2fd3c13497a9b496ca76a9dac573de07
|
40
libftdi/Pkgfile
Normal file
40
libftdi/Pkgfile
Normal file
@ -0,0 +1,40 @@
|
||||
# Description: A library to talk to FTDI chips, optional python bindings
|
||||
# URL: https://www.intra2net.com/en/developer/libftdi/index.php
|
||||
# Maintainer: Tim Biermann, tbier at posteo dot de
|
||||
# Depends on: confuse libusb boost swig
|
||||
|
||||
name=libftdi
|
||||
version=1.5
|
||||
release=3
|
||||
source=(https://www.intra2net.com/en/developer/libftdi/download/${name}1-$version.tar.bz2
|
||||
fix_includes_path.patch)
|
||||
|
||||
build() {
|
||||
sed -i 's|LIB_SUFFIX 64|LIB_SUFFIX ""|' ${name}1-$version/CMakeLists.txt
|
||||
sed -i "s|MODE=\"0664\", GROUP=\"plugdev\"|TAG+=\"wheel\"|g" ${name}1-$version/packages/99-libftdi.rules
|
||||
|
||||
patch -p1 -d ${name}1-$version < $SRC/fix_includes_path.patch
|
||||
|
||||
cmake -S ${name}1-$version -B build -G Ninja \
|
||||
-D CMAKE_INSTALL_PREFIX=/usr \
|
||||
-D CMAKE_INSTALL_LIBDIR=lib \
|
||||
-D CMAKE_BUILD_TYPE=Release \
|
||||
-D CMAKE_CXX_FLAGS_RELEASE="$CXXFLAGS" \
|
||||
-D CMAKE_C_FLAGS_RELEASE="$CFLAGS" \
|
||||
-D CMAKE_SKIP_BUILD_RPATH=ON \
|
||||
-D BUILD_SHARED_LIBS=ON \
|
||||
-D FTDI_EEPROM=ON \
|
||||
-D FTDIPP=ON \
|
||||
-D PYTHON_BINDINGS=ON \
|
||||
-D LINK_PYTHON_LIBRARY=ON \
|
||||
-D STATICLIBS=OFF \
|
||||
-D EXAMPLES=OFF \
|
||||
-D DOCUMENTATION=OFF \
|
||||
-Wno-dev
|
||||
cmake --build build
|
||||
DESTDIR=$PKG cmake --install build
|
||||
|
||||
install -Dm644 ${name}1-$version/packages/99-libftdi.rules $PKG/lib/udev/rules.d/69-libftdi.rules
|
||||
|
||||
rm -r $PKG/usr/share
|
||||
}
|
41
libftdi/fix_includes_path.patch
Normal file
41
libftdi/fix_includes_path.patch
Normal file
@ -0,0 +1,41 @@
|
||||
From: Fabrice Fontaine <fontaine.fabrice@gmail.com>
|
||||
Date: Fri, 17 Jul 2020 19:25:03 +0000 (+0200)
|
||||
Subject: CMakeLists.txt: fix paths when FTDIPP is set
|
||||
X-Git-Url: http://developer.intra2net.com/git/?p=libftdi;a=commitdiff_plain;h=cdb28383402d248dbc6062f4391b038375c52385;hp=5c2c58e03ea999534e8cb64906c8ae8b15536c30
|
||||
|
||||
CMakeLists.txt: fix paths when FTDIPP is set
|
||||
|
||||
Use the same project name (i.e. libftdi1 and not libftdipp1) when FTDIPP
|
||||
is enabled as suggested by Aurelien Jarno in
|
||||
http://developer.intra2net.com/mailarchive/html/libftdi/2020/msg00044.html
|
||||
|
||||
Without this change, the libftdi1.pc config file defines the include
|
||||
path as /usr/local/include/libftdipp1 while the ftdi.h file is actually
|
||||
installed in /usr/local/include/libftdi1
|
||||
|
||||
This is an issue for example for libsigrok which will fail on:
|
||||
|
||||
In file included from src/hardware/asix-sigma/protocol.c:27:
|
||||
src/hardware/asix-sigma/protocol.h:28:10: fatal error: ftdi.h: No such file or directory
|
||||
28 | #include <ftdi.h>
|
||||
| ^~~~~~~~
|
||||
|
||||
Fixes:
|
||||
- http://autobuild.buildroot.org/results/1427f44e36752c337791597fab47a1889552a2fe
|
||||
|
||||
Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
|
||||
---
|
||||
|
||||
diff --git a/CMakeLists.txt b/CMakeLists.txt
|
||||
index 5aecafc..3b0b87c 100644
|
||||
--- a/CMakeLists.txt
|
||||
+++ b/CMakeLists.txt
|
||||
@@ -136,7 +136,7 @@ endif ()
|
||||
|
||||
add_subdirectory(src)
|
||||
if ( FTDIPP )
|
||||
- project(libftdipp1 C CXX)
|
||||
+ project(libftdi1 C CXX)
|
||||
add_subdirectory(ftdipp)
|
||||
endif ()
|
||||
if ( PYTHON_BINDINGS )
|
Loading…
x
Reference in New Issue
Block a user