Posted by Diego "Flameeyes" Pettenò
Thu, 31 Jul 2008 14:29:00 GMT
As I wrote I’ll be trying to write more documentation about what I do, rather than doing stuff. This is because I’m simply too tired, and I should rest and relax rather than stress myself.
So after playing some Lego Star Wars I’ve decided to take a look to what I need to document for PAM. There was an easy bug to fix so I decided to tackle that down; tackling that down I decided to look if I was missing anything and I noticed that sys-libs/pam could use a debug USE flag. Unfotunately, not only it does not build with debug USE flag enabled, but it also fails with it disabled because the configure file was written by someone who yet again fail at using AC_ARG_ENABLE.
But this was just one of the two things I noticed today and I wished to fix if I didn’t have to rest, so I decided to write here a small checklist I follow when I have to check or fix packages:
- If the package is using autotools, I make sure they can be rebuilt with a simple
autoreconf -i. Usually this fails when macros are present in the m4 directory (or something like that), or if it misses the gettext version specification for autopoint.
- If the package supports out-of-sourcetree builds, I create an “enterprise” directory and build from there (usually it involves a
../configure). A lot of packages fail at this step because they assume that source directory and build directory are one and the same.
- If the package uses
assert() I make sure it works with it disabled (-DNDEBUG); this is usually nice to link to the debug USE flag to remove debugging code.
- I check the resulting object files with
cowstats (check Introducing cowstats for more information about this), and see if I can improve the situation with some trivial changes.
- I check the resulting object files with
missingstatic (another script in ruby-elf).
- If the package uses automake I make sure the
_LDFLAGS variables don’t contain libraries to link to (would break --as-needed).
- I check for possible bundled libraries we don’t want to use.
- I check for possible automagic dependencies that we don’t want in the ebuild.
- I run a build with all the useful warnings enabled, and see if there is something that needs to be fixed.
Such a checklist, if done from start to end, may generate a fair amount of patches that have to be sent upstream. It usually requires to check them on their development repositories too so that the patches are not obsoleted already.
As you can guess by now, it’s not exactly the quickest of the tasks, and it depends a lot on the power of the development box I’m working on. Unfortunately using a faster remote box does not always help because, even if Emacs’s tramp is quite neat, it does not make it easy to access the sources for editing. And having the sources locally and mounting them remotely doesn’t resolve either, as the build would then stall on getting the sources.
My plans were to get either the YDL PowerStation or a dual quad-core Opteron system (yes I know it’s overkill, but I don’t want to have to upgrade system every three years). It wouldn’t have been that bad, I just needed to take a couple of jobs during summer and early fall, and I could afford them. Right now, though, the situation looks pretty bad. I’m not sure whether I can get a new job done before fall, and even though medical care in Italy is paid for by the government, there are a few expenses I had to make (like for instance an over-quota for my Internet connection to download the software to view my CAT scans while I was in the hospital—long story, I’ll write about that another day), and the visit next Tuesday is in private practice (so I’ll have to pay for it).
If you care about a package, try to apply these checks on it, and see if upstream can pick up some improvements :) Every little drop is an advantage!
Posted in Gentoo, Technical, Personal, English | Tags autotools, Checklist, checks, cowstats, Ebuilds, ELF, Maintainership, missingstatic | no comments
Posted by Diego "Flameeyes" Pettenò
Thu, 31 Jul 2008 09:49:00 GMT
No I’m not working on C# again, although I admit i have Mono installed. Actually to be honest I’m not working on anything at the moment.
I have scheduled a visit in Verona next Tuesday, then they’ll probably tell me when I’ll have surgery, and which kind of surgery. Up to then I’m not sure how to organise myself with jobs and other things so I’ll probably keep a very low profile.
So, to make sure I don’t end up leaving packages unmaintained and bugs unseen, I’m trying now to delegate as much as I can of my responsibilities to other developers. Hopefully this way there won’t be anything left untouched while I’m convalescent.
The only things I’ll be working on this week, and even those only briefly, are short documentation updates, and maybe, but just maybe, version bumps. I already updated the --as-needed fixing guide trying to make it a bit more clear what to do with some errors, and how to properly filter the flag, and when to actually filter it. I’ll probably write something more about that, and then start seeing if I can write something about autotools update problems.
I’m doing this because multiple people (both devs and non) contacted me while I was in the hospital asking how to fix stuff, for --as-needed, new libtool, new autoconf, and so on. As I cannot really answer them while I’m in the hospital, I’d rather see to write a proper guide before I enter again, and then leave that to them as a reference.
I really can’t afford another pancreatitis, so I’ll have to reduce my stress levels a lot. Help with stuff I’ve been working on is very very welcome. So if you wish to spare some time and help me with, for instance, identifying packages that need to be fixed to work with OpenPAM, so that Seraphim’s work could be actually made good use of after it’s done.
Now I’ll cut this entry short, as I want to take care of other things today, like being able to play a bit (I haven’t played seriously in weeks!), plus I have to download from the camera some more photos I made this morning.
Again, donations to me, gifts, but even more importantly, day after day, to the research on pancreatic diseases are welcome.
Posted in Gentoo, Personal, English | Tags AsNeeded, Delegating, Documentation, Health, Maintainership, Packages, Pancreas, Stress | 1 comment
Posted by Diego "Flameeyes" Pettenò
Tue, 29 Jul 2008 11:12:00 GMT
Hey everybody! I’m finally back home, although just for a few days.
I already feel better, I had a shower, now I’m eating some pasta (I have to follow a very-low fats diet), and then I’ll have to call the doctor to take an appointment for the other hospital.
In the mean time I won’t be doing any Gentoo work, I’m afraid, as I need to rest and prepare myself for the journey to Verona.
All in all, I think I’ll have to take some more human schedules until I get the surgery, and for a bit afterward, possibly good for the timezone I live on rather than the one that suits my needs best.
For that reason I suppose a gift that would be very appreciated (although not available on Amazon UK :|) would be a good alarm clock, possibly not digital, those are too easy to disengage without waking up ;)
I’ll have some hospital memories that I’d like to share in the next days but I should not overexert myself, so I don’t know whether I’ll be able to write them or not.
Thanks again to everybody who left a comment, in private and in public!
Posted in Personal, English | Tags Health, Hospital, Status, Surgery | 3 comments
Posted by Diego "Flameeyes" Pettenò
Mon, 28 Jul 2008 11:52:00 GMT
The good news first: if all goes well I’ll be home by the end of the week. The bad news is that I’ll probably have to go to another hospital in Verona next week.
They let me eat today to see how I react, I have to make sure to keep a regular diet while I’m at home, and I’ll probably not work on Gentoo or anything else for the time. I think I’ll pass most of my days in bed even at home, playing with C&C3 or something else (I could play with the PS3 but my arms are still hurting from the IV needles - which I don’t have on at the moment - and they’d probably stress me more physically than an RTS).
I will probably be tempted to write something or to fix lights or some other electrical work. I’ll see to avoid that. I should probably read more, as this year I haven’t read just as much as I should have. If you feel like doing something, my wishlist is still at the same place ;)
The only things I will probably try to write about are the shortcomings of the hospital I’m in. I didn’t say this before, but I’m not in the same one I was last year, because in the mean time the new hospital was open and the old one closed. Not everything is good when it’s new, for sure. The staff, is, possibly luckily, the same as before.
I think I’ll see to nap a bit right now probably, as last night I wasn’t able to sleep too much because of some other patients in this unit.
Note to self: get Scrubs season 4 DVDs before I come out of Verona’s Hospital. (Those you won’t find on the wishlist because I usually buy them in Italian.)
Posted in Personal, English | Tags Health, Hospital, Pancreatitis, Status, Surgery | 1 comment
Posted by Diego "Flameeyes" Pettenò
Sat, 26 Jul 2008 22:06:00 GMT
Before people start to feel like I’m in my dying bed already, I want to give everybody a status update on my current pancreatitis.
It seems like it’s just a new acute pancreatitis not entirely related to the first episode from last year. The good news is that I have more pancreas than the doctors expected, as they didn’t expect a new pancreatitis at all. The bad news is that the primary cause is still there.
I don’t have a fever today, I don’t have many tubes till going in and out of my body, certainly not as many as last year. I still have an IV needle in my left arm (with no IV on it), and my right arm, from which they removed the needle about an hour ago, is still hurting. Nonetheless I’m quite fine. I can walk around just fine, without pain or dizzy spells, which again is in contrast to last year, as even before entering the ICU I was unable to walk around alone because of the pain.
All in all it seems like my pancreatitis subsided and it’s now on its way out, the reason why I’m hospitalized is finding and removing the primary source. At the end of the day it seems like the primary cause was and still is gallstones, which, to be solved, would require to get my gallbladder removed. Nothing too serious, and something lots of people cope with, it’s just going to be a bit messier for me than the standard, for what the doctors of this hospital said.
The problem is that the laparoscopy that is used for most gallbladder removals might not work on me because of the results of last year’s pancreatitis, and thus they might have to give me a laparotomy which means cutting me open to remove the gallbladder.
At any rate, next week I’ll be in contact with some doctors from another hospital (Verona) which will also check me out and decide who will be my surgeon, and where.
For what concerns my involvements within Gentoo, I’m to be considered temporarily offline, even though I do read mail and I could (notice could) enter IRC for meetings and everything. I’ll see to find a temporary proxy for me anyway so that he/she will be able to take up for me what I was meaning to do. I think I’ll have to reconsider a possible nomination next year though, as I don’t want my health to take hits because of the stress coming from Gentoo Council.
I hope I’ll be able to stick around to help with easy problem solving, but please don’t count too much on me. I’ll try to have my status updated from time to time so that I don’t get people too worried. I have my UMTS phone with me, which is very useful, using the same flatrate I used last year. I would have loved having one of the HSDPA USB modems but all the UMTS providers in Italy seems to require a minimum contract of 24 months which is a bit too much for something that I used intensively, in the last twelve months, for just two.
Posted in Personal, English | Tags Gentoo, Health, Hospital, Pancreatitis, Status | no comments
Posted by Diego "Flameeyes" Pettenò
Fri, 25 Jul 2008 05:44:00 GMT
Quick and dirty post just to inform you all that I’m again at the hospital. Again pancreatitis.
I hope it won’t be like last year and that I’ll be back soonish. But in the mean time I’m offline.
Tags Health, Hospital, Pancreatitis | 12 comments
Posted by Diego "Flameeyes" Pettenò
Tue, 22 Jul 2008 17:45:00 GMT
After my previous post about preserved-libs feature, I was asked by many users if I was against this feature because it incremented the usability of Gentoo. I sincerely think I shown before that I don’t want Gentoo to remain for elitists, and thus I won’t be going to say nay to anything to make stuff easier to the users.
On the other hand, I want to make sure that users, excited about being able to upgrade stuff without breaking their system, won’t break it even further. For this reason I want to warn again users against trying the unstable Portage version (2.2) on their stable systems just yet.
Thanks to Zac and Marius, the problem I’m going to talk about is already being taken care of, so it won’t appear once 2.2 final will arrive. So why am I writing about this anyway? Well the reason is actually quite simple: future memory.
On the topic of linking, loaders, ELF files and all the things related, there isn’t a lot of documentation that is available to newcomers. Most of it is very technical and requires good knowledge of many concepts to be useful. I only know of a book that goes in deep of this, Rob Levine’s Linkers and Loaders is probably the most interesting reading on the subject ,as far as I can see. Unfortunately I haven’t tried converting the downloadable version in LRF to load it on the EBook Reader and I haven’t got the printed copy. I should probably get that too, as a reference, I’m just afraid that all the hardcopies I have here will remain at my parents’ house once I move out.
Okay, let’s return back on topic now. What is the problem I found today with preserved-libs? Well as I updated to Xorg 1.5 pre-releases to check if my RandR problems were fixed (by the way, they are), there was a libGL update. I also took the time to switch back to gcc 4.2 for a short time as I wanted to rebuild VirtualBox without ALSA support (whenever I can I’m using PulseAudio), and I could also rebuild xmlrpc-c (the reason why I couldn’t build this with GCC 4.3 is good for a different entry one day). After these builds, Portage told me this:
!!! existing preserved libs:
>>> package: media-libs/mesa-7.1_rc3
* - /usr/lib64/libGLU.so.1.3
* - /usr/lib64/libGLU.so.1.3.070003
>>> package: dev-libs/xmlrpc-c-1.06.27
* - /usr/lib64/libxmlrpc.so.3.6.4
I was surprised because I know libGLU rarely changes interface, and I didn’t think xmlrpc-c would have either. And indeed a quick scanelf run over the files confirmed my ideas:
flame@enterprise ~ % scanelf -S /usr/lib64/libGLU.so*
TYPE SONAME FILE
ET_DYN libGLU.so.1 /usr/lib64/libGLU.so
ET_DYN libGLU.so.1 /usr/lib64/libGLU.so.1
ET_DYN libGLU.so.1 /usr/lib64/libGLU.so.1.3
ET_DYN libGLU.so.1 /usr/lib64/libGLU.so.1.3.070003
ET_DYN libGLU.so.1 /usr/lib64/libGLU.so.1.3.070100
flame@enterprise ~ % scanelf -S /usr/lib64/libxmlrpc.so*
TYPE SONAME FILE
ET_DYN libxmlrpc.so.3 /usr/lib64/libxmlrpc.so
ET_DYN libxmlrpc.so.3 /usr/lib64/libxmlrpc.so.3
ET_DYN libxmlrpc.so.3 /usr/lib64/libxmlrpc.so.3.6.15
ET_DYN libxmlrpc.so.3 /usr/lib64/libxmlrpc.so.3.6.4
As you can see the soname for both the versions of libGLU and both the versions of libxmlrpc is the same. So there is no ABI break, and no good reason for the file to disappear, right?
Indeed if we focus solely on the xmlrpc-c case, the result of preserved-libs actions is that there is now an orphaned unused and unusable shared object:
flame@enterprise ~ % ls -l /usr/lib64/libxmlrpc.so*
lrwxrwxrwx 1 root root 19 2008-07-22 18:04 /usr/lib64/libxmlrpc.so -> libxmlrpc.so.3.6.15
lrwxrwxrwx 1 root root 19 2008-07-22 18:04 /usr/lib64/libxmlrpc.so.3 -> libxmlrpc.so.3.6.15
-rwxr-xr-x 1 root root 56864 2008-07-22 18:04 /usr/lib64/libxmlrpc.so.3.6.15
-rwxr-xr-x 1 root root 56368 2008-02-23 13:36 /usr/lib64/libxmlrpc.so.3.6.4
Let’s see, ld.so (the runtime linker) will look for a library with, as filename, the soname listed in a program’s NEEDED entry in the dynamic seciton of the ELF file. In this case, the soname of libxmlrpc is libxmlrpc.so.3 so that’s what the linker will look for. On my system, that filename is linked to the 3.6.15 version, so the runtime linker will always load the new version of libxmlrpc. The build-time linker (ld) looks instead for the filename with the simple .so prefix (or .a for static libraries). That one is also pointing to 3.6.15.
So who is using the 3.6.4 version that Portage preserved? Well, the only way to use it is to dlopen() it directly and accessing it that way. Which, if anything would be doing that, would be craziness, to the point that I’d rather not see such a software in my system at all. The other option is for an ELF file to have a tweaked NEEDED entry that points explicitly to the full version, but I can tell you I have none of those.
So for now I’ll simply remove the two files, and get rid of the problem. But as you can see, it’s too soon to expect preserve-libs to work out of the box in a perfect manner.
Anyway, Marius, Zac, please keep up with the good work, it’s really needed :) Thanks guys!
Posted in Gentoo, Technical, English | Tags ABI, ELF, Linking, portage, PreserveLibs | 5 comments
Posted by Diego "Flameeyes" Pettenò
Tue, 22 Jul 2008 14:24:00 GMT
For those of you who’d like to follow Google Summer of Code progress (I’d very much like to have the blogs of the student available on Universe by the way), today (or rather yesterday) can be counted in as a very important date :)
Seraphim prepared a patch for shadow (the package containing all the basic utilities for users management in Linux) to work with OpenPAM, rather than depending strictly on Linux-PAM. I committed it in tree now for 4.1.2.1 and upstream applied it to trunk already, so now it can be built even when using OpenPAM rather than Linux-PAM. Cool, eh?
This patch (and the related bug) are important not only because they fix a very important part of the functionality of a Linux system with OpenPAM, but also because it will act as a base reference to fix other software to use OpenPAM too.
Indeed, one of the most obnoxious problems with OpenPAM is that a lot of packages instead of writing their own conversation functions rely on misc_conv. Seraphim prepared a patch that can be applied to almost any other package relying on that to make it OpenPAM-compatible. It’s very good.
Unfortunately, as Seraphim also blogged there is one catch with being able to provide OpenPAM support, especially for the future. The problem is that although mostly API compatible, OpenPAM and Linux-PAM are not ABI compatible. Although in a very subtle way, because, as Seraphim learnt, you can have a system built against Linux-PAM run against OpenPAM just fine, up to a point.
The problem is that ABI does not only refer to the name of the functions, or the type of their parameters, but also to the meaning of flag values. In this case, Linux-PAM and OpenPAM give different flags different meanings, so modules built against OpenPAM will not work properly with software built against Linux-PAM.
This is going to be tricky, especially once we’ll allow users to switch from one to the other and vice-versa, because it means all the software will have to be rebuilt to continue functioning as it’s supposed to. And no preserved-rebuild will help us there.
Oh well, there’s time to think of that!
Posted in Gentoo, Technical, English | Tags Debian, GSoC, LinuxPAM, OpenPAM, PAM, patches, Shadow, SummerOfCode | 1 comment
Posted by Diego "Flameeyes" Pettenò
Mon, 21 Jul 2008 16:00:00 GMT
With my move to Gnome I decided to try out again the graphical login. I used to use standard console login before because KDM lacked too many features, and while for some time I kept using GDM, it just didn’t feel right. Unless I was going to just do some system administration, or testing PAM, the only command I was going to type was startx, followed by sudo shutdown -h once I was done.
To do so, I had to give up keychain, at least for inserting the private key’s passphrase. Instead of using that, I decided to change my PAM setup to use pam_ssh (and this is also what brought me to plan removal of pam_ssh_agent .. I just remembered I forgot to add that to the Gentoo Calendar!—done!), so that instead of typing my password and my SSH key passphrase, I just have to type in my passphrase at login and I’m done. The nice thing is that the standard Unix password is also accepted, so I can use that to take me out of the lock screen that Gnome applies when I walk away from the system, which is much shorter.
Again, I will probably put up a request for an electronic ID card next september and consider using a smartcard reader (I I wonder if I can use old, invalid, credit cards as smartcards too, once they are formatted).
So okay, I’ll write at another time about pam_ssh, it’s not what I’d like to write about right now.
With GDM I’m having one problem: my current setup is a dualhead, with a 16:10 monitor (and a 4:3) and using XRandR 1.2 (radeon driver). I have the screen disposition set up in my xorg.conf, but I’m not able to set the proper mode for the 16:10 monitor in the configuration file. If I set PreferredMode in xorg.conf, X11 refuses to start, without any apparent error either.
So for now I’m running at the session manager level two xrandr commands to set up properly the screens, but there is one problem: synergys does not seem to be expecting the geometry of the screens to change, so it still wraps my pointer out on the coordinates where it should have wrapped before the xrandr fixes.
I should probably see to try the latest masked version of xorg, and check if it works there. Although I think Synergy should have considered the case of changing screen layout. Maybe one day it will be rewritten using XCB and it will consider that problem too ;)
Oh yeah I should be writing about XCB too…
Posted in Gentoo, Technical, English | Tags GDM, GNOME, Synergy, Xorg, XRandR | 2 comments
Posted by Diego "Flameeyes" Pettenò
Sun, 20 Jul 2008 15:57:00 GMT
As it turns out, I start to dislike the way the KDE project is proceeding, and I don’t refer to the Gentoo KDE project, but to the whole of KDE project.
I dislike the way KDE 4 is being developed, with a focus on eyecandy rather than on features. This is easily shown by the Oxygen style; not only it is taking up a amount of screen real estate for widgets that remind me of Keramik (and if you remember, one thing that made happy a huge amount of users was the switch from Keramik to Plastik as default style in KDE 3.3), but it’s also tremendously slow. And I’m sure of this, it’s not just an impression: as soon as I switch Qt to use Oxygen, it takes five seconds for Quassel to draw the list of buffers; once I use QtCurve, it takes just one second. I don’t know if this is because Enterprise is using XAA and not EXA, but it certainly doesn’t look like something that the default theme should do.
And no, I’m not expected to use a computer that has less than an year, with a hyper-strength gaming videocard to be able to use KDE.
But this is just one of the issues I have with KDE recently. There are some policies I really, really, dislike in KDE. The first is one I already mentioned quite often and it’s the move to CMake. The only “good” reason to move to CMake is to be able to build under Windows using Microsoft’s Visual C++ compiler; yet instead of just saying “we needed cmake because it’s necessary to build for Windows” I see so many devs saying “cmake is just better than everything else out there”. Bullshit.
The other policy that I dislike regards the way KDE is developed and released as a single, huge, monolithic thing. One of the things that made KDE difficult to package in Gentoo (and other source-based distributions) was the fact that by default the source has to be built in those huge amorphous packages. And if the autotools-based build system of KDE sucked so much, it was also because of that.
But even if we leave alone the way the releases are made, it’s just not possible for everything to fall into a single release cycle kind of thing. There are projects that are more mature and projects that are less. Forcing all of them in a single release cycle makes it difficult to provide timely bugfixes for the mature projects, and makes it impossible for the not-so-mature projects to be tested incrementally. The last straw I could bear to see because of this stupid way of releasing, was knowing that Konversation in KDE 4 will probably lose the IRC-over-SSL support because KSSL was removed from the base libraries.
And now KDE 4.1 is on the verge of release, and Kopete still segfaults once you connect to Jabber. Yet when I tried (multiple times) to gather information about the possible cause in #kopete (so I could at least try to debug it myself), I had no feedback at all; maybe it’s because I run Gentoo, although the same happens on (K)Ubuntu. Yeah not the kind of people I like to deal with.
I’m not saying that I think Gnome is perfect for policies and other things. I dislike the fact that it’s always more Linux-/Solaris-centric than cross-platform centric; but I think KDE4 was a set back for that too, for what I read. And their release method does look a lot more sane.
I started using Linux with KDE 2. I moved to Gnome once KDE 3 was being taken care of. I came back to KDE just a bit before 3.3 release. Now I’m going to try Gnome for a while, and if I like it, I’ll think more than twice before going back to KDE. Yeah sure I liked KDE 3 better than I liked Gnome before that, but it’s just not feasible that I have to switch DE every time they want to make a new release.
Besides, since I last used it, Gnome seems much more mature and nicer to deal with.
Posted in Gentoo, Technical, English | Tags CMake, GNOME, KDE, Oxygen, Policies, Problems, Release | 29 comments