cannot build exmap module in intrepid ibex

Bug #284863 reported by dfszb
40
This bug affects 4 people
Affects Status Importance Assigned to Milestone
exmap (Debian)
Fix Released
Unknown
exmap (Ubuntu)
Fix Released
Wishlist
Unassigned

Bug Description

The make output is:
 sudo make
make -C /lib/modules/2.6.27-7-generic/build M=/usr/src/modules/exmap modules
make[1]: Entering directory `/usr/src/linux-headers-2.6.27-7-generic'
  CC [M] /usr/src/modules/exmap/exmap.o
/usr/src/modules/exmap/exmap.c: In function 'setup_from_pid':
/usr/src/modules/exmap/exmap.c:395: error: implicit declaration of function 'find_task_by_pid'
/usr/src/modules/exmap/exmap.c:395: warning: assignment makes pointer from integer without a cast
/usr/src/modules/exmap/exmap.c: In function 'init_module':
/usr/src/modules/exmap/exmap.c:510: error: 'proc_root' undeclared (first use in this function)
/usr/src/modules/exmap/exmap.c:510: error: (Each undeclared identifier is reported only once
/usr/src/modules/exmap/exmap.c:510: error: for each function it appears in.)
/usr/src/modules/exmap/exmap.c: In function 'cleanup_module':
/usr/src/modules/exmap/exmap.c:535: error: 'proc_root' undeclared (first use in this function)
make[2]: *** [/usr/src/modules/exmap/exmap.o] Error 1
make[1]: *** [_module_/usr/src/modules/exmap] Error 2
make[1]: Leaving directory `/usr/src/linux-headers-2.6.27-7-generic'
make: *** [kernel_modules] Error 2

Related branches

Revision history for this message
David García (dav.garcia) wrote :

Hi,

I'm also getting exactly the same error in Ubuntu 8.10 after upgrading to kernel 2.6.27-9.

Steps to reproduce:

sudo apt-get install exmap exmap-modules-source
cd /usr/src
sudo tar xvzf exmap.tar.gz
cd modules/exmap
sudo make

make -C /lib/modules/2.6.27-9-generic/build M=/usr/src/modules/exmap modules
make[1]: Entering directory `/usr/src/linux-headers-2.6.27-9-generic'
  CC [M] /usr/src/modules/exmap/exmap.o
/usr/src/modules/exmap/exmap.c: In function ‘setup_from_pid’:
/usr/src/modules/exmap/exmap.c:395: error: implicit declaration of function ‘find_task_by_pid’
/usr/src/modules/exmap/exmap.c:395: warning: assignment makes pointer from integer without a cast
/usr/src/modules/exmap/exmap.c: In function ‘init_module’:
/usr/src/modules/exmap/exmap.c:510: error: ‘proc_root’ undeclared (first use in this function)
/usr/src/modules/exmap/exmap.c:510: error: (Each undeclared identifier is reported only once
/usr/src/modules/exmap/exmap.c:510: error: for each function it appears in.)
/usr/src/modules/exmap/exmap.c: In function ‘cleanup_module’:
/usr/src/modules/exmap/exmap.c:535: error: ‘proc_root’ undeclared (first use in this function)
make[2]: *** [/usr/src/modules/exmap/exmap.o] Error 1
make[1]: *** [_module_/usr/src/modules/exmap] Error 2
make[1]: Leaving directory `/usr/src/linux-headers-2.6.27-9-generic'
make: *** [kernel_modules] Error 2

Revision history for this message
Paul Fleischer (paul-xpg) wrote :

Hi,

I have also run into this problem. The solution, it seems, is quite straight forward. I have applied a patch for exmap.c which fixes the problem.

With regards to the usage of the 'find_task_by_vpid'-function, I'm not sure that it works in all situations.

Revision history for this message
Radoslaw (radraw) wrote :

The patch doesn't work, at least with x86_64 ubuntu 8.10. Exmap displays zero for all values of memory usage of processes after applying it.

Revision history for this message
Paul Fleischer (paul-xpg) wrote :

Exmap + my patch above, does indeed not work properly on x86_64.
I will try to look into the issue, but don't hold your breath for a solution :-(

Revision history for this message
rnat (rnatella) wrote :

Hi,
you can find attached to this comment a patch for compiling exmap kernel module on Ubuntu 8.10.
Roberto

Revision history for this message
rnat (rnatella) wrote :

The abovementioned patch.

Revision history for this message
Dave Gilbert (ubuntu-treblig) wrote :

also broken in Jaunty (64)

Changed in exmap (Ubuntu):
status: New → Confirmed
Revision history for this message
Motin (motin) wrote :

The patch listed two comments above also enables build, installation and functionality on Jaunty. Thanks all who contributed to the solution!

All this bug seems to need to be fixed is packaging, it seems. Please consider patching the version included in the repositories!

Revision history for this message
Barrakketh (barrakketh) wrote :

rnat's patch enabled me to build the kernel module on Jaunty/x86.

Revision history for this message
Alex Salt (holy.cheater) wrote :

I've encountered the same bug. Fix works for me too.
Attaching a debdiff, hope it will get into repositories.

Revision history for this message
Alex Salt (holy.cheater) wrote :

Subscribing ubuntu-universe-sponsors

Revision history for this message
Chuck Short (zulcss) wrote :

Hi,

It would be great if you could rediff this for karmic, since it has the same issues.

Thanks
chuck

Changed in exmap (Ubuntu):
assignee: nobody → fabrice_sp (fabricesp)
status: Confirmed → In Progress
Changed in exmap (Debian):
status: Unknown → New
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package exmap - 0.10-2.1ubuntu1

---------------
exmap (0.10-2.1ubuntu1) karmic; urgency=low

  * debian/patches/buildfix.dpatch: patch by rnat to fixes kernel module build
    errors with kernel >= 2.6.26 (LP: #284863)

 -- Alexander Saltykov <email address hidden> Wed, 22 Jul 2009 05:32:01 +0600

Changed in exmap (Ubuntu):
status: In Progress → Fix Released
Revision history for this message
Fabrice Coutadeur (fabricesp) wrote :

Uploaded. Thanks for your contribution!

I've just updated a bit the changelog entry, to make it clearer, and I have added the correct maintainer in debian/control.

Thanks,
Fabrice

Changed in exmap (Ubuntu):
assignee: fabrice_sp (fabricesp) → nobody
status: Fix Released → Fix Committed
Revision history for this message
Fabrice Coutadeur (fabricesp) wrote :

Manually closing the bug, as it has been uploaded and build now (should have been closes automatically).

Changed in exmap (Ubuntu):
importance: Undecided → Wishlist
status: Fix Committed → Fix Released
Changed in exmap (Debian):
status: New → Fix Released
Revision history for this message
Bill (hudacek) wrote :

I'm not sure why, but I'm only seeing version "Version: 0.10-2.1", not "Version: 0.10-2.1-ubuntu1" in the universe repo.

Here are my configured repositories:

deb http://us.archive.ubuntu.com/ubuntu/ jaunty-updates main restricted multiverse universe #updates (M/R/Mu/U)
deb-src http://us.archive.ubuntu.com/ubuntu/ jaunty-updates main restricted multiverse universe #updates (M/R/Mu/U) (src)

And apt-cache policy exmap shows:

exmap:
  Installed: 0.10-2.1
  Candidate: 0.10-2.1
  Version table:
 *** 0.10-2.1 0
        500 http://us.archive.ubuntu.com jaunty/universe Packages
        100 /var/lib/dpkg/status

Can anyone tell me why, after so much time, I cannot see the working version?

Thanks!

Revision history for this message
Bill (hudacek) wrote :

Oops - might help if I included the module package info.....

Package: exmap-modules-source
Versions:
0.10-2.1 (/var/lib/apt/lists/us.archive.ubuntu.com_ubuntu_dists_jaunty_universe_binary-i386_Packages) (/var/lib/dpkg/status)
 Description Language:
                 File: /var/lib/apt/lists/us.archive.ubuntu.com_ubuntu_dists_jaunty_universe_binary-i386_Packages
                  MD5: e8f74efcf19410e47bf109157d58e44c

Reverse Depends:
  exmap,exmap-modules-source
Dependencies:
0.10-2.1 - cdbs (0 (null)) debhelper (2 5.0.0) module-assistant (0 (null)) linux-headers-2.6 (16 (null)) linux-source-2.6 (0 (null))
Provides:
0.10-2.1 -

Thanks!

Revision history for this message
Alex Salt (holy.cheater) wrote :

@Bill: The patch was not uploaded to jaunty or intrepid.

Also, this patch doesn't work for karmic. I'm attaching the working debdiff for karmic.

Revision history for this message
Alexander Sashnov (sashnov) wrote :

Thank you, Alexander!

Your patch helps me to build working exmap-modules-source (but build of exmap.deb is failed).
With buildfix-karmic.debdiff I install exmap-modules-source on karmic i386, gexmap is working now for me.

Revision history for this message
Amber (amberved) wrote :

OK, I dont know much about all the various versions and dist etc....

I solved this problem for myself by replacing the call for
"find_task_by_pid_type(PIDTYPE_PID, pid)" to pid_task(find_pid_ns(pid, &init_pid_ns), PIDTYPE_PID)

Actually checking the "linux/sched.h" file, i found that find_task_by_pid_type (etc are defined here) I see that they are defined "static" which tells me that things might have changed between kernel versions and hence all the issues....

But I might be totally off the charts here

-Amber

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.