diff --git a/libsensors-visibility.patch b/libsensors-visibility.patch new file mode 100644 index 0000000..609db3a --- /dev/null +++ b/libsensors-visibility.patch @@ -0,0 +1,34 @@ +--- /dev/null ++++ lib/libsensors.map +@@ -0,0 +1,20 @@ ++{ ++global: ++ libsensors_version; ++ sensors_cleanup; ++ sensors_do_chip_sets; ++ sensors_free_chip_name; ++ sensors_get_adapter_name; ++ sensors_get_all_subfeatures; ++ sensors_get_detected_chips; ++ sensors_get_features; ++ sensors_get_label; ++ sensors_get_subfeature; ++ sensors_get_value; ++ sensors_init; ++ sensors_parse_chip_name; ++ sensors_set_value; ++ sensors_snprintf_chip_name; ++ sensors_strerror; ++local: *; ++ }; +--- lib/Module.mk.orig ++++ lib/Module.mk +@@ -63,7 +63,7 @@ LIBHEADERFILES := $(MODULE_DIR)/error.h + + # How to create the shared library + $(MODULE_DIR)/$(LIBSHLIBNAME): $(LIBSHOBJECTS) +- $(CC) -shared $(LDFLAGS) -Wl,-soname,$(LIBSHSONAME) -o $@ $^ -lc -lm ++ $(CC) -shared $(LDFLAGS) -Wl,--version-script=$(LIB_DIR)/libsensors.map -Wl,-soname,$(LIBSHSONAME) -o $@ $^ -lc -lm + + $(MODULE_DIR)/$(LIBSHSONAME): $(MODULE_DIR)/$(LIBSHLIBNAME) + $(RM) $@ diff --git a/sensors.changes b/sensors.changes index 90f6fb7..94c6e5c 100644 --- a/sensors.changes +++ b/sensors.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Mon Nov 29 20:47:06 UTC 2010 - cristian.rodriguez@opensuse.org + +- libsensors: export only public symbols + ------------------------------------------------------------------- Sun Oct 31 12:37:02 UTC 2010 - jengelh@medozas.de diff --git a/sensors.spec b/sensors.spec index 78ce47a..7b2219d 100644 --- a/sensors.spec +++ b/sensors.spec @@ -36,6 +36,7 @@ Patch2: lm_sensors-3.0.0-sensord-separate.patch Patch3: lm_sensors-3.0.0-sysconfig_metadata.patch Patch4: lm_sensors-3.0.3-hint-at-kernel-extra-package.patch Patch5: lm_sensors-3.1.1-no-ipmisensors-driver.patch +Patch6: libsensors-visibility.patch BuildRoot: %{_tmppath}/%{name}-%{version}-build ExcludeArch: s390 s390x @@ -138,7 +139,7 @@ Authors: %patch3 -p1 %patch4 -p1 %patch5 -p1 - +%patch6 %build RPM_OPT_FLAGS="$RPM_OPT_FLAGS" make %{?_smp_mflags} PROG_EXTRA:=sensord BUILD_STATIC_LIB:=0 PREFIX=%{_prefix} MANDIR=%{_mandir} LIBDIR=%{_libdir} @@ -159,7 +160,6 @@ make %{?_smp_mflags} PROG_EXTRA:=sensord BUILD_STATIC_LIB:=0 PREFIX=%{_prefix} M mkdir -p $RPM_BUILD_ROOT/etc/init.d install -m 0755 %{S:1} $RPM_BUILD_ROOT/etc/init.d/lm_sensors ln -sf /etc/init.d/lm_sensors $RPM_BUILD_ROOT/usr/sbin/rclm_sensors - %clean rm -rf $RPM_BUILD_ROOT