Move all to deprecated folder.
This commit is contained in:
@@ -0,0 +1,81 @@
|
||||
Add support for static only build
|
||||
|
||||
This patch adds support for a BUILD_SHARED_LIB variable that allows to
|
||||
enable/disable the build of the shared library, in order to support
|
||||
static-only builds.
|
||||
|
||||
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
|
||||
|
||||
Index: b/Makefile
|
||||
===================================================================
|
||||
--- a/Makefile
|
||||
+++ b/Makefile
|
||||
@@ -85,6 +85,9 @@
|
||||
# Build and install static library
|
||||
BUILD_STATIC_LIB := 1
|
||||
|
||||
+# Build and install shared library
|
||||
+BUILD_SHARED_LIB := 1
|
||||
+
|
||||
# Set these to add preprocessor or compiler flags, or use
|
||||
# environment variables
|
||||
# CFLAGS :=
|
||||
Index: b/lib/Module.mk
|
||||
===================================================================
|
||||
--- a/lib/Module.mk
|
||||
+++ b/lib/Module.mk
|
||||
@@ -43,8 +43,14 @@
|
||||
LIBSTLIBNAME := libsensors.a
|
||||
LIBSHSONAME := libsensors.so.$(LIBMAINVER)
|
||||
|
||||
+ifeq ($(BUILD_SHARED_LIB),1)
|
||||
LIBTARGETS := $(MODULE_DIR)/$(LIBSHLIBNAME) \
|
||||
$(MODULE_DIR)/$(LIBSHSONAME) $(MODULE_DIR)/$(LIBSHBASENAME)
|
||||
+LIBDEP_FOR_PROGS := $(LIBSHBASENAME)
|
||||
+else
|
||||
+LIBDEP_FOR_PROGS := $(LIBSTLIBNAME)
|
||||
+endif
|
||||
+
|
||||
ifeq ($(BUILD_STATIC_LIB),1)
|
||||
LIBTARGETS += $(MODULE_DIR)/$(LIBSTLIBNAME)
|
||||
endif
|
||||
@@ -131,9 +137,11 @@
|
||||
ifeq ($(BUILD_STATIC_LIB),1)
|
||||
$(INSTALL) -m 644 $(LIB_DIR)/$(LIBSTLIBNAME) $(DESTDIR)$(LIBDIR)
|
||||
endif
|
||||
+ifeq ($(BUILD_SHARED_LIB),1)
|
||||
$(INSTALL) -m 755 $(LIB_DIR)/$(LIBSHLIBNAME) $(DESTDIR)$(LIBDIR)
|
||||
$(LN) $(LIBSHLIBNAME) $(DESTDIR)$(LIBDIR)/$(LIBSHSONAME)
|
||||
$(LN) $(LIBSHSONAME) $(DESTDIR)$(LIBDIR)/$(LIBSHBASENAME)
|
||||
+endif
|
||||
@if [ -z "$(DESTDIR)" -a "$(LIBDIR)" != "/usr/lib" -a "$(LIBDIR)" != "/lib" ] ; then \
|
||||
if [ -e "/usr/lib/$(LIBSHSONAME)" -o -e "/usr/lib/$(LIBSHBASENAME)" ] ; then \
|
||||
echo '******************************************************************************' ; \
|
||||
Index: b/prog/sensord/Module.mk
|
||||
===================================================================
|
||||
--- a/prog/sensord/Module.mk
|
||||
+++ b/prog/sensord/Module.mk
|
||||
@@ -41,7 +41,7 @@
|
||||
REMOVESENSORDBIN := $(patsubst $(MODULE_DIR)/%,$(DESTDIR)$(SBINDIR)/%,$(PROGSENSORDTARGETS))
|
||||
REMOVESENSORDMAN := $(patsubst $(MODULE_DIR)/%,$(DESTDIR)$(PROGSENSORDMAN8DIR)/%,$(PROGSENSORDMAN8FILES))
|
||||
|
||||
-$(PROGSENSORDTARGETS): $(PROGSENSORDSOURCES:.c=.ro) lib/$(LIBSHBASENAME)
|
||||
+$(PROGSENSORDTARGETS): $(PROGSENSORDSOURCES:.c=.ro) lib/$(LIBDEP_FOR_PROGS)
|
||||
$(CC) $(EXLDFLAGS) -o $@ $(PROGSENSORDSOURCES:.c=.ro) -Llib -lsensors -lrrd
|
||||
|
||||
all-prog-sensord: $(PROGSENSORDTARGETS)
|
||||
Index: b/prog/sensors/Module.mk
|
||||
===================================================================
|
||||
--- a/prog/sensors/Module.mk
|
||||
+++ b/prog/sensors/Module.mk
|
||||
@@ -39,8 +39,8 @@
|
||||
|
||||
LIBICONV := $(shell if /sbin/ldconfig -p | grep -q '/libiconv\.so$$' ; then echo \-liconv; else echo; fi)
|
||||
|
||||
-$(PROGSENSORSTARGETS): $(PROGSENSORSSOURCES:.c=.ro) lib/$(LIBSHBASENAME)
|
||||
- $(CC) $(EXLDFLAGS) -o $@ $(PROGSENSORSSOURCES:.c=.ro) $(LIBICONV) -Llib -lsensors
|
||||
+$(PROGSENSORSTARGETS): $(PROGSENSORSSOURCES:.c=.ro) lib/$(LIBDEP_FOR_PROGS)
|
||||
+ $(CC) $(EXLDFLAGS) -o $@ $(PROGSENSORSSOURCES:.c=.ro) $(LIBICONV) -Llib -lsensors -lm
|
||||
|
||||
all-prog-sensors: $(PROGSENSORSTARGETS)
|
||||
user :: all-prog-sensors
|
||||
@@ -0,0 +1,29 @@
|
||||
Remove usage of host ldconfig
|
||||
|
||||
To know whether the libiconv library is available, lm-sensors is using
|
||||
the host ldconfig, which is obviously wrong in cross-compilation.
|
||||
|
||||
Moreover, the lm-sensors program making use of the iconv_*() API
|
||||
already does it when __UCLIBC__ is *not* defined. In this case, the
|
||||
iconv_*() functions are already part of the C library, so there is no
|
||||
need to link against a separate library. Therefore, this patch simply
|
||||
removes the libiconv handling.
|
||||
|
||||
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
|
||||
|
||||
Index: b/prog/sensors/Module.mk
|
||||
===================================================================
|
||||
--- a/prog/sensors/Module.mk
|
||||
+++ b/prog/sensors/Module.mk
|
||||
@@ -37,10 +37,8 @@
|
||||
REMOVESENSORSBIN := $(patsubst $(MODULE_DIR)/%,$(DESTDIR)$(BINDIR)/%,$(PROGSENSORSTARGETS))
|
||||
REMOVESENSORSMAN := $(patsubst $(MODULE_DIR)/%,$(DESTDIR)$(PROGSENSORSMAN1DIR)/%,$(PROGSENSORSMAN1FILES))
|
||||
|
||||
-LIBICONV := $(shell if /sbin/ldconfig -p | grep -q '/libiconv\.so$$' ; then echo \-liconv; else echo; fi)
|
||||
-
|
||||
$(PROGSENSORSTARGETS): $(PROGSENSORSSOURCES:.c=.ro) lib/$(LIBDEP_FOR_PROGS)
|
||||
- $(CC) $(EXLDFLAGS) -o $@ $(PROGSENSORSSOURCES:.c=.ro) $(LIBICONV) -Llib -lsensors -lm
|
||||
+ $(CC) $(EXLDFLAGS) -o $@ $(PROGSENSORSSOURCES:.c=.ro) -Llib -lsensors -lm
|
||||
|
||||
all-prog-sensors: $(PROGSENSORSTARGETS)
|
||||
user :: all-prog-sensors
|
||||
@@ -0,0 +1,100 @@
|
||||
From 6d85773537c9f277ed342f57500f784ccb2c4a3e Mon Sep 17 00:00:00 2001
|
||||
From: Brendan Heading <brendanheading@gmail.com>
|
||||
Date: Sun, 30 Aug 2015 22:26:39 +0100
|
||||
Subject: [PATCH 1/1] fix compilation under musl
|
||||
|
||||
This patch removes conditional compilation elements that are designed to
|
||||
support glibc versions earlier than 2.0, which were causing the build
|
||||
to fail under musl.
|
||||
|
||||
Based on the patch found here :
|
||||
|
||||
http://git.alpinelinux.org/cgit/aports/plain/main/lm_sensors/musl-fix-includes.patch?id=fece1d19448dbd3a56fd8ac70443116187141848
|
||||
|
||||
This patch has been accepted for integration upstream and should be
|
||||
present in the next release. See :
|
||||
|
||||
http://www.lm-sensors.org/changeset/6314
|
||||
|
||||
Signed-off-by: Brendan Heading <brendanheading@gmail.com>
|
||||
Upstream-Status: pending
|
||||
---
|
||||
prog/dump/isadump.c | 6 ------
|
||||
prog/dump/isaset.c | 6 ------
|
||||
prog/dump/superio.c | 5 -----
|
||||
prog/dump/util.c | 5 -----
|
||||
4 files changed, 22 deletions(-)
|
||||
|
||||
diff --git a/prog/dump/isadump.c b/prog/dump/isadump.c
|
||||
index e031e47..88e4c3b 100644
|
||||
--- a/prog/dump/isadump.c
|
||||
+++ b/prog/dump/isadump.c
|
||||
@@ -36,13 +36,7 @@
|
||||
#include "util.h"
|
||||
#include "superio.h"
|
||||
|
||||
-
|
||||
-/* To keep glibc2 happy */
|
||||
-#if defined(__GLIBC__) && __GLIBC__ == 2 && __GLIBC_MINOR__ >= 0
|
||||
#include <sys/io.h>
|
||||
-#else
|
||||
-#include <asm/io.h>
|
||||
-#endif
|
||||
|
||||
#ifdef __powerpc__
|
||||
unsigned long isa_io_base = 0; /* XXX for now */
|
||||
diff --git a/prog/dump/isaset.c b/prog/dump/isaset.c
|
||||
index 1d1bdad..a084c8a 100644
|
||||
--- a/prog/dump/isaset.c
|
||||
+++ b/prog/dump/isaset.c
|
||||
@@ -32,13 +32,7 @@
|
||||
#include <string.h>
|
||||
#include "util.h"
|
||||
|
||||
-
|
||||
-/* To keep glibc2 happy */
|
||||
-#if defined(__GLIBC__) && __GLIBC__ == 2 && __GLIBC_MINOR__ >= 0
|
||||
#include <sys/io.h>
|
||||
-#else
|
||||
-#include <asm/io.h>
|
||||
-#endif
|
||||
|
||||
#ifdef __powerpc__
|
||||
unsigned long isa_io_base = 0; /* XXX for now */
|
||||
diff --git a/prog/dump/superio.c b/prog/dump/superio.c
|
||||
index 1af7358..31e0d78 100644
|
||||
--- a/prog/dump/superio.c
|
||||
+++ b/prog/dump/superio.c
|
||||
@@ -20,12 +20,7 @@
|
||||
*/
|
||||
|
||||
#include <stdlib.h>
|
||||
-
|
||||
-#if defined(__GLIBC__) && __GLIBC__ == 2 && __GLIBC_MINOR__ >= 0
|
||||
#include <sys/io.h>
|
||||
-#else
|
||||
-#include <asm/io.h>
|
||||
-#endif
|
||||
|
||||
#include "superio.h"
|
||||
|
||||
diff --git a/prog/dump/util.c b/prog/dump/util.c
|
||||
index 676c339..d8b0927 100644
|
||||
--- a/prog/dump/util.c
|
||||
+++ b/prog/dump/util.c
|
||||
@@ -11,12 +11,7 @@
|
||||
#include <stdio.h>
|
||||
#include "util.h"
|
||||
|
||||
-/* To keep glibc2 happy */
|
||||
-#if defined(__GLIBC__) && __GLIBC__ == 2 && __GLIBC_MINOR__ >= 0
|
||||
#include <sys/io.h>
|
||||
-#else
|
||||
-#include <asm/io.h>
|
||||
-#endif
|
||||
|
||||
/* Return 1 if we should continue, 0 if we should abort */
|
||||
int user_ack(int def)
|
||||
--
|
||||
2.4.3
|
||||
|
||||
55
deprecated/firmware/buildroot/package/lm-sensors/Config.in
Normal file
55
deprecated/firmware/buildroot/package/lm-sensors/Config.in
Normal file
@@ -0,0 +1,55 @@
|
||||
config BR2_PACKAGE_LM_SENSORS
|
||||
bool "lm-sensors"
|
||||
help
|
||||
Lm-sensors is a hardware health monitoring package for
|
||||
Linux. It allows you to access information from
|
||||
temperature, voltage, and fan speed sensors. It
|
||||
works with most newer systems.
|
||||
|
||||
http://www.lm-sensors.org/
|
||||
|
||||
if BR2_PACKAGE_LM_SENSORS
|
||||
comment "lm-sensors tools"
|
||||
|
||||
config BR2_PACKAGE_LM_SENSORS_SENSORS
|
||||
bool "sensors"
|
||||
default y
|
||||
help
|
||||
Sensors is used to show the current readings of all sensor
|
||||
chips.
|
||||
|
||||
config BR2_PACKAGE_LM_SENSORS_FANCONTROL
|
||||
bool "fancontrol"
|
||||
help
|
||||
Script for temperature driven fan control
|
||||
|
||||
config BR2_PACKAGE_LM_SENSORS_ISADUMP
|
||||
bool "isadump"
|
||||
help
|
||||
Isadump is a small helper program to examine registers
|
||||
visible through the ISA bus.
|
||||
|
||||
config BR2_PACKAGE_LM_SENSORS_ISASET
|
||||
bool "isaset"
|
||||
help
|
||||
Isaset is a small helper program to set register visible
|
||||
through the ISA bus.
|
||||
|
||||
config BR2_PACKAGE_LM_SENSORS_PWMCONFIG
|
||||
bool "pwmconfig"
|
||||
help
|
||||
Pwmconfig searches your sensors for pulse width modulation (PWM)
|
||||
controls, and tests each one to see if it controls a fan on
|
||||
your motherboard.
|
||||
|
||||
config BR2_PACKAGE_LM_SENSORS_SENSORS_DETECT
|
||||
bool "sensors-detect"
|
||||
depends on BR2_PACKAGE_PERL
|
||||
help
|
||||
Sensors-detect is an interactive program for detecting
|
||||
available hardware monitoring chips.
|
||||
|
||||
comment "sensors-detect needs perl"
|
||||
depends on !BR2_PACKAGE_PERL
|
||||
|
||||
endif
|
||||
@@ -0,0 +1,2 @@
|
||||
# Locally calculated
|
||||
sha256 e0579016081a262dd23eafe1d22b41ebde78921e73a1dcef71e05e424340061f lm_sensors-3.4.0.tar.bz2
|
||||
@@ -0,0 +1,54 @@
|
||||
################################################################################
|
||||
#
|
||||
# lm-sensors
|
||||
#
|
||||
################################################################################
|
||||
|
||||
LM_SENSORS_VERSION = 3.4.0
|
||||
LM_SENSORS_SOURCE = lm_sensors-$(LM_SENSORS_VERSION).tar.bz2
|
||||
LM_SENSORS_SITE = ftp://ftp.netroedge.com/pub/lm-sensors
|
||||
LM_SENSORS_INSTALL_STAGING = YES
|
||||
LM_SENSORS_DEPENDENCIES = host-bison host-flex
|
||||
LM_SENSORS_LICENSE = libsensors LGPLv2.1+, programs GPLv2+
|
||||
LM_SENSORS_LICENSE_FILES = COPYING.LGPL COPYING
|
||||
|
||||
LM_SENSORS_BINS_ = bin/sensors-conf-convert
|
||||
LM_SENSORS_BINS_$(BR2_PACKAGE_LM_SENSORS_SENSORS) += bin/sensors
|
||||
LM_SENSORS_BINS_$(BR2_PACKAGE_LM_SENSORS_FANCONTROL) += sbin/fancontrol
|
||||
LM_SENSORS_BINS_$(BR2_PACKAGE_LM_SENSORS_ISADUMP) += sbin/isadump
|
||||
LM_SENSORS_BINS_$(BR2_PACKAGE_LM_SENSORS_ISASET) += sbin/isaset
|
||||
LM_SENSORS_BINS_$(BR2_PACKAGE_LM_SENSORS_PWMCONFIG) += sbin/pwmconfig
|
||||
LM_SENSORS_BINS_$(BR2_PACKAGE_LM_SENSORS_SENSORS_DETECT) += sbin/sensors-detect
|
||||
|
||||
LM_SENSORS_MAKE_OPTS = \
|
||||
BUILD_STATIC_LIB=1 \
|
||||
MACHINE=$(KERNEL_ARCH) \
|
||||
PREFIX=/usr
|
||||
|
||||
ifeq ($(BR2_STATIC_LIBS),y)
|
||||
LM_SENSORS_MAKE_OPTS += BUILD_SHARED_LIB=0
|
||||
else
|
||||
LM_SENSORS_MAKE_OPTS += BUILD_SHARED_LIB=1
|
||||
endif
|
||||
|
||||
ifeq ($(BR2_SHARED_LIBS),y)
|
||||
LM_SENSORS_MAKE_OPTS += BUILD_STATIC_LIB=0
|
||||
else
|
||||
LM_SENSORS_MAKE_OPTS += BUILD_STATIC_LIB=1
|
||||
endif
|
||||
|
||||
define LM_SENSORS_BUILD_CMDS
|
||||
$(MAKE) $(TARGET_CONFIGURE_OPTS) $(LM_SENSORS_MAKE_OPTS) -C $(@D)
|
||||
endef
|
||||
|
||||
define LM_SENSORS_INSTALL_STAGING_CMDS
|
||||
$(MAKE) -C $(@D) $(LM_SENSORS_MAKE_OPTS) DESTDIR=$(STAGING_DIR) install
|
||||
rm -f $(addprefix $(STAGING_DIR)/usr/,$(LM_SENSORS_BINS_) $(LM_SENSORS_BINS_y))
|
||||
endef
|
||||
|
||||
define LM_SENSORS_INSTALL_TARGET_CMDS
|
||||
$(MAKE) -C $(@D) $(LM_SENSORS_MAKE_OPTS) DESTDIR=$(TARGET_DIR) install
|
||||
rm -f $(addprefix $(TARGET_DIR)/usr/,$(LM_SENSORS_BINS_))
|
||||
endef
|
||||
|
||||
$(eval $(generic-package))
|
||||
Reference in New Issue
Block a user