2 # Copyright (C) 2017 Yegor Yefremov <yegorslists@googlemail.com>
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
8 include $(TOPDIR
)/rules.mk
14 PKG_SOURCE_URL
:=https
://github.com
/jackmitch
/libsoc.git
15 PKG_SOURCE_DATE
:=2016-12-22
16 PKG_SOURCE_VERSION
:=5b788d4d558a78c52e6cfe97325e4564b307a3a0
18 PKG_MAINTAINER
:=Yegor Yefremov
<yegorslists@googlemail.com
>
20 PKG_LICENSE_FILES
:=LICENCE
26 include $(INCLUDE_DIR
)/package.mk
33 URL
:=https
://github.com
/jackmitch
/libsoc
36 define Package
/libsoc
/description
37 libsoc
: C library for interfacing with common SoC peripherals through
38 generic kernel interfaces
47 CFLAGS
="$(TARGET_CFLAGS)" \
48 DESTDIR
="$(PKG_INSTALL_DIR)" \
51 define Build
/InstallDev
52 $(INSTALL_DIR
) $(1)/usr
/include
53 $(CP
) $(PKG_INSTALL_DIR
)/usr
/include/libsoc_board.h
$(1)/usr
/include/
54 $(CP
) $(PKG_INSTALL_DIR
)/usr
/include/libsoc_conffile.h
$(1)/usr
/include/
55 $(CP
) $(PKG_INSTALL_DIR
)/usr
/include/libsoc_debug.h
$(1)/usr
/include/
56 $(CP
) $(PKG_INSTALL_DIR
)/usr
/include/libsoc_gpio.h
$(1)/usr
/include/
57 $(CP
) $(PKG_INSTALL_DIR
)/usr
/include/libsoc_i2c.h
$(1)/usr
/include/
58 $(CP
) $(PKG_INSTALL_DIR
)/usr
/include/libsoc_pwm.h
$(1)/usr
/include/
59 $(CP
) $(PKG_INSTALL_DIR
)/usr
/include/libsoc_spi.h
$(1)/usr
/include/
60 $(INSTALL_DIR
) $(1)/usr
/lib
61 $(CP
) $(PKG_INSTALL_DIR
)/usr
/lib
/libsoc.
{a
,so
*} $(1)/usr
/lib
/
62 $(INSTALL_DIR
) $(1)/usr
/lib
/pkgconfig
63 $(CP
) $(PKG_INSTALL_DIR
)/usr
/lib
/pkgconfig
/libsoc.
pc $(1)/usr
/lib
/pkgconfig
66 define Package
/libsoc
/install
67 $(INSTALL_DIR
) $(1)/usr
/lib
68 $(CP
) $(PKG_INSTALL_DIR
)/usr
/lib
/libsoc.so.
* $(1)/usr
/lib
/
71 $(eval
$(call BuildPackage
,libsoc
))