LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   What happens to the installed RPM packages? (https://www.linuxquestions.org/questions/linux-newbie-8/what-happens-to-the-installed-rpm-packages-430291/)

halturata 03-31-2006 07:16 AM

What happens to the installed RPM packages?
 
Hi everybody,

My question is as well as simple and newbie - what happens to the installed RPM packages? I mean do they get inserted into the linux kernel like common modules? Or the wait to be referenced untill they are needed? And if so, how can one access the functionality provided by the module?

Well, it is not one question actually. I'm in the following situation:

I have to write a simple programm which accesses VME bus and does some read/write and checks of the boards on the VME bus. But I cannot come up with as to how to reference the VME bus in my programm. There are a lot of packages already installed on the system related to VME (after all the whole filesystem is mounted on a SCSI hard drive which is on the VME bus) but how do I get use of their functionality in a custom program? Here is what I got:

Code:

[root@host root]# rpm -qa | grep vme
kernel-headers-2.4.25-rm01.xxxxXXXX
kernel-prep-2.4.25-rm01.xxxxXXXX
kernel-source-2.4.25-rm01.xxxxXXXX
xxx-vme-devel-1.1-2
xxx-vme-1.0-1

Anybody has an idea how to get use of the installed packages? There must be also libraries with predefined functions for VME bus read/write/interrupt/etc. but I can't locat them either... Please help if you can :confused:

Agrouf 03-31-2006 08:33 AM

Hello, halturata.
Perhaps you should have a look at http://www.linux.com/howtos/VME-HOWTO-3.shtml

About the kernel question, the ksyms and nm commands could help you. try man ksyms and man nm.
Does ksyms -a | grep vme and then nm vme_stuff.o provide useful information?

lurker79 03-31-2006 08:36 AM

When you install an rpm package, it copies files included in the rpm on to your system in the locations specified by the packager writer.
Also information about the package are inserted into a package database, which you can query to find out which versions of packages are installed, which files are owned by which packages and other assorted info.
Once package is installed you can run the application just by typing the command's name.

I am not sure on the specifics of the packages you have mentioned, but once it is installed you can access the documentation/ man pages etc.

halturata 03-31-2006 08:46 AM

Quote:

Perhaps you should have a look at http://www.linux.com/howtos/VME-HOWTO-3.shtml
Well I already had, I also built the package but it doesn't seem to work... The problem is that I don't know how to include such functionality into my own program.

Quote:

copies files included in the rpm on to your system in the locations specified by the packager writer
How can I find out where these locations are? By quring the RPM database?

Thank you guys.

lurker79 03-31-2006 08:52 AM

to find what files were installed by the package run
rpm -ql packagename

halturata 03-31-2006 01:28 PM

When I do the nm, I get the following:
Code:

[root@host misc]# nm vmemod.o
000060ac T DMA_tempe_irqhandler
00003bbc T DMA_uni_irqhandler
0000612c T LERR_tempe_irqhandler
00003bfc T LERR_uni_irqhandler
0000624c T LM_tempe_irqhandler
00003cf4 T LM_uni_irqhandler
0000620c T MB_tempe_irqhandler
00003cb4 T MB_uni_irqhandler
000061a8 T VERR_tempe_irqhandler
00003c58 T VERR_uni_irqhandler
00006284 T VIRQ_tempe_irqhandler
00003d2c T VIRQ_uni_irqhandler
00000000 d Version
U __copy_tofrom_user_Re410a3dd
U __down_interruptible_R9ef0b7cf
U __get_free_pages_R9016dd82
00000000 ? __module_kernel_version
00000074 ? __module_kernel_version
000000ac ? __module_kernel_version
000000e4 ? __module_kernel_version
00000068 ? __module_license
00000050 ? __module_parm_vme_slotnum
00000038 ? __module_parm_vmechip_irq
00000024 ? __module_using_checksums
00000098 ? __module_using_checksums
000000d0 ? __module_using_checksums
00000108 ? __module_using_checksums

and so on...

These are memory locations I guess? Where the values of the variables on the right are stored?

And when I do an rpm -ql mcg-vme-1.0-1, I get the following:
Code:

[root@host vme]# rpm -ql xxx-vme-1.0-1
/dev/vme_ctl
/dev/vme_dma0
/dev/vme_dma1
/dev/vme_lm0
/dev/vme_m0
/dev/vme_m1
/dev/vme_m2
/dev/vme_m3
/dev/vme_m4
/dev/vme_m5
/dev/vme_m6
/dev/vme_m7
/dev/vme_regs
/dev/vme_rmw0
/lib/modules/2.4.25-rm01.xxxxXXXX/misc/vmemod.o
/usr/vme/testapps
/usr/vme/testapps/probeslots
/usr/vme/testapps/testdata
/usr/vme/testapps/testdma
/usr/vme/testapps/testgenirq
/usr/vme/testapps/testirq
/usr/vme/testapps/testlm
/usr/vme/testapps/testlocaldma
/usr/vme/testapps/testout
/usr/vme/testapps/testreg
/usr/vme/testapps/testrmw
/usr/vme/testapps/testslotdata
/usr/vme/testapps/vmeregread
/usr/vme/testapps/vmeregwrite
/usr/vme/testapps/vmesetarbiter
/usr/vme/testapps/vmesetinbound
/usr/vme/testapps/vmesetrequestor

The first ones are the device files for the VME bus communication and control. Then comes the vmemod.o and finaly the test apps which are included into the driver. Well I surely must read more about building and handling modules and libraries...


All times are GMT -5. The time now is 03:13 PM.