From Bugzilla Helper: User-Agent: Mozilla/5.0 (X11; U; Linux i586; en-US; rv:1.4.2) Gecko/20040308 Description of problem: The current rawhide version of util-linux does not compile when built from srpm. Additionally, WITH_SELINUX is not handled correctly. Version-Release number of selected component (if applicable): util-linux-2.12a-6 How reproducible: Always Steps to Reproduce: 1. rpmbuild -bb util-linux.spec Actual Results: /usr/lib/gcc-lib/i686-pc-linux-gnu/3.3.3/../../../libslang.so: undefined reference to `tgetnum' /usr/lib/gcc-lib/i686-pc-linux-gnu/3.3.3/../../../libslang.so: undefined reference to `tgetflag' /usr/lib/gcc-lib/i686-pc-linux-gnu/3.3.3/../../../libslang.so: undefined reference to `tgetent' /usr/lib/gcc-lib/i686-pc-linux-gnu/3.3.3/../../../libslang.so: undefined reference to `tgetstr' collect2: ld returned 1 exit status make[1]: *** [cfdisk] Error 1 Expected Results: A message saying where the rpm was written. Additional info: I will attach 2 patches that fix this problem.
Created attachment 103463 [details] This fixes the linking problem
Created attachment 103464 [details] This fixes the spec file. Please apply these patches.
Why should this not be fixed in slang then?
Slang is a library. You only run into this problem when you link to it. AFAIK, you cannot solve external dependencies within the library. You have to add the proper linkage to the CC or LD command of an application - such as cfdisk. I would venture to say other programs that use slang include the correct linkage. If there is a better way to fix it, please go ahead. I'm just showing you what fixed it for me. I'll test whatever gets released.
Sure, you can link slang against its dependent lib.
this doesn't seem to be a problem with redhat environments. perhaps you're using you're own ncurses that's built with termcap? there's no tgetnum in our libslang. it compiles correctly for our distros. closing.