Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 123226

Summary: bug in x11-libs/motif-config-0.9 causing other bugs
Product: Gentoo Linux Reporter: Drake Wyrm <lilwyrm>
Component: [OLD] LibraryAssignee: Heinrich Wendel (RETIRED) <lanius>
Status: VERIFIED FIXED    
Severity: normal CC: jdmason
Priority: High    
Version: 2005.0   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---
Attachments: patch to allow motif-config to return an appropriate exit value

Description Drake Wyrm 2006-02-17 20:45:32 UTC
Some time ago, I ran across a problem in compiling sci-astronomy/xephem-3.7, which seemed to be a problem with the motif libraries. Today, when updating openmotif, I noticed the source of that error. It seems that the motif profile is not updated correctly. There are three directories in /usr/include which are not handled correctly by motif-config. During emerge, and also when running motif-config directly, the following errors are displayed:

rm: cannot remove `/usr/include/Mrm': Is a directory
rm: cannot remove `/usr/include/Xm': Is a directory
rm: cannot remove `/usr/include/uil': Is a directory
rm: cannot remove `/usr/include/Mrm': Is a directory
ln: `/usr/include/Mrm/Mrm': File exists
rm: cannot remove `/usr/include/Xm': Is a directory
ln: `/usr/include/Xm/Xm': File exists
rm: cannot remove `/usr/include/uil': Is a directory
ln: `/usr/include/uil/uil': File exists
 * /usr/bin/motif-config: New default Profile is: openmotif-2.2

Unfortunately, even though these errors are encountered, the tool exits successfully. I propose that one or more of the following changes be made to motif-config:

0) Allow motif-config to return an appropriate value when errors occur. This can be accomplished by keeping a return value and updating it after each action. Patch to follow.

1) Allow motif-config to die when errors occur. Let me know if this would be preferable to (0), and I'll try to write up a patch.

2) Fix the problem by removing the directories. This can be accomplished by changing each "rm -f" to "rm -rf".

	sed -i -e 's/\<rm -f\>/rm -rf/' motif-config
Comment 1 Drake Wyrm 2006-02-17 20:47:31 UTC
Created attachment 80057 [details, diff]
patch to allow motif-config to return an appropriate exit value
Comment 2 Heinrich Wendel (RETIRED) gentoo-dev 2006-02-20 02:22:32 UTC
thx, commited as 0.10
Comment 3 Jon Mason 2006-02-20 06:12:05 UTC
I can confirm this problem (which prevents xpdf from being installed), and that the current fix commited corrects the issue.