mirror of
git://git.openembedded.org/meta-openembedded
synced 2026-01-01 13:58:06 +00:00
i2c-tools: import from OE rev d4f0211e2078d5033ae0dee74664de5520d8392d
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
This commit is contained in:
parent
a6a2f048d1
commit
1998f8ef89
72
meta-oe/recipes-support/i2c-tools/i2c-tools-3.0.3/Module.mk
Normal file
72
meta-oe/recipes-support/i2c-tools/i2c-tools-3.0.3/Module.mk
Normal file
|
|
@ -0,0 +1,72 @@
|
|||
# EEPROMER
|
||||
#
|
||||
# Licensed under the GNU General Public License.
|
||||
|
||||
EEPROMER_DIR := eepromer
|
||||
|
||||
EEPROMER_CFLAGS := -Wstrict-prototypes -Wshadow -Wpointer-arith -Wcast-qual \
|
||||
-Wcast-align -Wwrite-strings -Wnested-externs -Winline \
|
||||
-W -Wundef -Wmissing-prototypes -Iinclude
|
||||
|
||||
EEPROMER_TARGETS := eepromer eeprom eeprog
|
||||
|
||||
#
|
||||
# Programs
|
||||
#
|
||||
|
||||
$(EEPROMER_DIR)/eepromer: $(EEPROMER_DIR)/eepromer.o
|
||||
$(CC) $(LDFLAGS) -o $@ $^
|
||||
|
||||
$(EEPROMER_DIR)/eeprom: $(EEPROMER_DIR)/eeprom.o
|
||||
$(CC) $(LDFLAGS) -o $@ $^
|
||||
|
||||
$(EEPROMER_DIR)/eeprog: $(EEPROMER_DIR)/eeprog.o $(EEPROMER_DIR)/24cXX.o
|
||||
$(CC) $(LDFLAGS) -o $@ $^
|
||||
|
||||
#
|
||||
# Objects
|
||||
#
|
||||
|
||||
$(EEPROMER_DIR)/eepromer.o: $(EEPROMER_DIR)/eepromer.c
|
||||
$(CC) $(CFLAGS) $(EEPROMER_CFLAGS) -c $< -o $@
|
||||
|
||||
$(EEPROMER_DIR)/eeprom.o: $(EEPROMER_DIR)/eeprom.c
|
||||
$(CC) $(CFLAGS) $(EEPROMER_CFLAGS) -c $< -o $@
|
||||
|
||||
$(EEPROMER_DIR)/eeprog.o: $(EEPROMER_DIR)/eeprog.c
|
||||
$(CC) $(CFLAGS) $(EEPROMER_CFLAGS) -c $< -o $@
|
||||
|
||||
$(EEPROMER_DIR)/24cXX.o: $(EEPROMER_DIR)/24cXX.c
|
||||
$(CC) $(CFLAGS) $(EEPROMER_CFLAGS) -c $< -o $@
|
||||
|
||||
#
|
||||
# Commands
|
||||
#
|
||||
|
||||
all-eepromer: $(addprefix $(EEPROMER_DIR)/,$(EEPROMER_TARGETS))
|
||||
|
||||
strip-eepromer: $(addprefix $(EEPROMER_DIR)/,$(EEPROMER_TARGETS))
|
||||
strip $(addprefix $(EEPROMER_DIR)/,$(EEPROMER_TARGETS))
|
||||
|
||||
clean-eepromer:
|
||||
$(RM) $(addprefix $(EEPROMER_DIR)/,*.o $(EEPROMER_TARGETS))
|
||||
|
||||
install-eepromer: $(addprefix $(EEPROMER_DIR)/,$(EEPROMER_TARGETS))
|
||||
$(INSTALL_DIR) $(DESTDIR)$(sbindir) $(DESTDIR)$(man8dir)
|
||||
for program in $(EEPROMER_TARGETS) ; do \
|
||||
$(INSTALL_PROGRAM) $(EEPROMER_DIR)/$$program $(DESTDIR)$(sbindir) ; done
|
||||
|
||||
uninstall-eepromer:
|
||||
for program in $(EEPROMER_TARGETS) ; do \
|
||||
$(RM) $(DESTDIR)$(sbindir)/$$program ; \
|
||||
$(RM) $(DESTDIR)$(man8dir)/$$program.8 ; done
|
||||
|
||||
all: all-eepromer
|
||||
|
||||
strip: strip-eepromer
|
||||
|
||||
clean: clean-eepromer
|
||||
|
||||
install: install-eepromer
|
||||
|
||||
uninstall: uninstall-eepromer
|
||||
24
meta-oe/recipes-support/i2c-tools/i2c-tools_3.0.3.bb
Normal file
24
meta-oe/recipes-support/i2c-tools/i2c-tools_3.0.3.bb
Normal file
|
|
@ -0,0 +1,24 @@
|
|||
DESCRIPTION = "Set of i2c tools for linux"
|
||||
SECTION = "base"
|
||||
LICENSE = "GPLv2"
|
||||
LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe"
|
||||
|
||||
SRC_URI = "http://dl.lm-sensors.org/i2c-tools/releases/i2c-tools-${PV}.tar.bz2 \
|
||||
file://Module.mk \
|
||||
"
|
||||
SRC_URI[md5sum] = "511376eed04455cdb277ef19c5f73bb4"
|
||||
SRC_URI[sha256sum] = "23b28e474741834e3f1b35b0686528769a13adc92d2ff5603cbda1d6bd5e5629"
|
||||
|
||||
inherit autotools
|
||||
|
||||
do_compile_prepend() {
|
||||
cp ${WORKDIR}/Module.mk ${S}/eepromer/
|
||||
sed -i 's#/usr/local#/usr#' Makefile
|
||||
echo "include eepromer/Module.mk" >> Makefile
|
||||
}
|
||||
|
||||
do_install_append() {
|
||||
install -d ${D}${includedir}/linux
|
||||
install -m 0644 include/linux/i2c-dev.h ${D}${includedir}/linux/i2c-dev-user.h
|
||||
rm -f ${D}${includedir}/linux/i2c-dev.h
|
||||
}
|
||||
Loading…
Reference in New Issue
Block a user