Hi,
i read this forum for weeks and found lots of useful information here. I own a H340 and would really like to use the LEDs. unfortunally i have some trouble compile the sources with my Openfiler distribution. Ok but step by step:
I installed everything needed for "make"
conary update gcc
conary update libtool
conary update glib
conary update glib:devel
conary update glibc
conary update glibc:devel
conary update automake
conary update autoconf
conary update pkgconfig
Compiling works - i try to compile Midnight Commander and it works.
1. when i compile "leds-h340-0.2" everything seems to work at least i get a leds-h430.ko at the end.
output:
Code:
[root@mediaserver leds-h340-0.2]# make
make -C /lib/modules/2.6.29.6-0.24.smp.gcc3.4.x86.i686/build SUBDIRS=/opt/mediasmartserver/leds-h340-0.2 modules
make[1]: Entering directory `/lib/modules/2.6.29.6-0.24.smp.gcc3.4.x86.i686/build'
Building modules, stage 2.
MODPOST 1 modules
WARNING: "led_classdev_unregister" [/opt/mediasmartserver/leds-h340-0.2/leds-h340.ko] undefined!
WARNING: "led_classdev_register" [/opt/mediasmartserver/leds-h340-0.2/leds-h340.ko] undefined!
make[1]: Leaving directory `/lib/modules/2.6.29.6-0.24.smp.gcc3.4.x86.i686/build'
[root@mediaserver leds-h340-0.2]#
2. insmod finally don't work for me
Code:
[root@mediaserver leds-h340-0.2]# insmod leds-h340.ko
insmod: error inserting 'leds-h340.ko': -1 Unknown symbol in module
I think my problem is some missing file(s) regarding this led_classdev but I don't know how to fix it. Compiling the source on my ubuntu machine works fine but I need it for Openfiler.
The second driver cannot be compiled in Openfiler:
Code:
[root@mediaserver mediasmartserverd]# make
rm *.o mediasmartserverd core -f
g++ -Wall -O2 -o device_monitor.o -c src/device_monitor.cpp
make: g++: Command not found
make: *** [device_monitor.o] Error 127
after
Code:
conary update gcc-c++
i got:
Quote:
[root@mediaserver mediasmartserverd]# make
rm *.o mediasmartserverd core -f
g++ -Wall -O2 -o device_monitor.o -c src/device_monitor.cpp
In file included from src/device_monitor.h:34,
from src/device_monitor.cpp:32:
src/led_control_base.h:34:22: tr1/memory: No such file or directory
In file included from src/device_monitor.h:34,
from src/device_monitor.cpp:32:
src/led_control_base.h:58: error: `size_t' has not been declared
src/led_control_base.h:58: error: ISO C++ forbids declaration of `led_idx' with no type
src/led_control_base.h:75: error: `std::tr1' has not been declared
src/led_control_base.h:75: error: expected init-declarator before '<' token
src/led_control_base.h:75: error: expected `,' or `;' before '<' token
In file included from src/device_monitor.cpp:32:
src/device_monitor.h:48: error: expected `,' or `...' before '&' token
src/device_monitor.h:48: error: ISO C++ forbids declaration of `LedControlPtr' with no type
src/device_monitor.h:60: error: `LedControlPtr' does not name a type
src/device_monitor.cpp:40:21: libudev.h: No such file or directory
src/device_monitor.cpp: In destructor `DeviceMonitor::~DeviceMonitor()':
src/device_monitor.cpp:53: error: `udev_unref' undeclared (first use this function)
src/device_monitor.cpp:53: error: (Each undeclared identifier is reported only once for each function it appears in.)
src/device_monitor.cpp:54: error: `udev_monitor_unref' undeclared (first use this function)
src/device_monitor.cpp: At global scope:
src/device_monitor.cpp:59: error: expected `,' or `...' before '&' token
src/device_monitor.cpp:59: error: ISO C++ forbids declaration of `LedControlPtr' with no type
src/device_monitor.cpp: In member function `void DeviceMonitor::Init(int)':
src/device_monitor.cpp:60: error: `leds_' undeclared (first use this function)
src/device_monitor.cpp:60: error: `leds' undeclared (first use this function)
src/device_monitor.cpp:63: error: `udev_new' undeclared (first use this function)
src/device_monitor.cpp:67: error: `udev_monitor_new_from_netlink' undeclared (first use this function)
src/device_monitor.cpp:71: error: `udev_monitor_filter_add_match_subsystem_devtype' undeclared (first use this function)
src/device_monitor.cpp:79: error: `udev_monitor_enable_receiving' undeclared (first use this function)
src/device_monitor.cpp: In member function `void DeviceMonitor::Main()':
src/device_monitor.cpp:89: error: `udev_monitor_get_fd' undeclared (first use this function)
src/device_monitor.cpp:109: error: `std::tr1' has not been declared
src/device_monitor.cpp:109: error: `shared_ptr' undeclared (first use this function)
src/device_monitor.cpp:109: error: expected primary-expression before '>' token
src/device_monitor.cpp:109: error: `udev_monitor_receive_device' undeclared (first use this function)
src/device_monitor.cpp:109: error: `udev_device_unref' undeclared (first use this function)
src/device_monitor.cpp:109: error: `device' undeclared (first use this function)
src/device_monitor.cpp:111: error: `udev_device_get_action' undeclared (first use this function)
src/device_monitor.cpp:120: error: `udev_device_get_syspath' undeclared (first use this function)
src/device_monitor.cpp:120: error: `udev_device_get_subsystem' undeclared (first use this function)
src/device_monitor.cpp: In member function `void DeviceMonitor::deviceAdded_(udev_device*)':
src/device_monitor.cpp:130: error: `udev_device_get_syspath' undeclared (first use this function)
src/device_monitor.cpp:130: error: `udev_device_get_subsystem' undeclared (first use this function)
src/device_monitor.cpp: In member function `void DeviceMonitor::deviceRemove_(udev_device*)':
src/device_monitor.cpp:137: error: `udev_device_get_syspath' undeclared (first use this function)
src/device_monitor.cpp:137: error: `udev_device_get_subsystem' undeclared (first use this function)
src/device_monitor.cpp: In member function `void DeviceMonitor::deviceChanged_(udev_device*, bool)':
src/device_monitor.cpp:145: error: `udev_device_get_parent_with_subsystem_devtype' undeclared (first use this function)
src/device_monitor.cpp:148: error: `udev_device_get_syspath' undeclared (first use this function)
src/device_monitor.cpp:148: error: `udev_device_get_subsystem' undeclared (first use this function)
src/device_monitor.cpp:151: error: `udev_device_get_parent' undeclared (first use this function)
src/device_monitor.cpp:158: error: `udev_device_get_sysnum' undeclared (first use this function)
src/device_monitor.cpp:165: error: `leds_' undeclared (first use this function)
src/device_monitor.cpp: In member function `void DeviceMonitor::enumDevices_()':
src/device_monitor.cpp:174: error: `std::tr1' has not been declared
src/device_monitor.cpp:174: error: `shared_ptr' undeclared (first use this function)
src/device_monitor.cpp:174: error: `udev_enumerate' undeclared (first use this function)
src/device_monitor.cpp:174: error: `udev_enumerate_new' undeclared (first use this function)
src/device_monitor.cpp:174: error: `udev_enumerate_unref' undeclared (first use this function)
src/device_monitor.cpp:174: error: `dev_enum' undeclared (first use this function)
src/device_monitor.cpp:177: error: `udev_enumerate_add_match_property' undeclared (first use this function)
src/device_monitor.cpp:178: error: `udev_enumerate_scan_devices' undeclared (first use this function)
src/device_monitor.cpp:181: error: `udev_list_entry' undeclared (first use this function)
src/device_monitor.cpp:181: error: `list_entry' undeclared (first use this function)
src/device_monitor.cpp:181: error: `udev_enumerate_get_list_entry' undeclared (first use this function)
src/device_monitor.cpp:182: error: `udev_list_entry_get_next' undeclared (first use this function)
src/device_monitor.cpp:184: error: `std::tr1' has not been declared
src/device_monitor.cpp:184: error: expected primary-expression before '>' token
src/device_monitor.cpp:186: error: `udev_enumerate_get_udev' undeclared (first use this function)
src/device_monitor.cpp:187: error: `udev_list_entry_get_name' undeclared (first use this function)
src/device_monitor.cpp:188: error: `udev_device_new_from_syspath' undeclared (first use this function)
src/device_monitor.cpp:189: error: `udev_device_unref' undeclared (first use this function)
src/device_monitor.cpp:189: error: `device' undeclared (first use this function)
make: *** [device_monitor.o] Error 1
Does anyone sucessfully compiled the sources in Openfiler or can anyone help me compiling these very useful drivers for my Openfiler.
Thanks for the great work! Hope I get it running.