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

Bug 187236

Summary: cmake does not find swig
Product: Gentoo Linux Reporter: kavol
Component: Current packagesAssignee: Gentoo Linux bug wranglers <bug-wranglers>
Status: RESOLVED NEEDINFO    
Severity: normal    
Priority: High    
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---

Description kavol 2007-07-31 10:52:39 UTC
Hello,

there is a problem with cmake - it looks for swig in wrong directory. This was reported to cmake bugzilla several times:

http://www.cmake.org/Bug/bug.php?op=show&bugid=3498
http://www.cmake.org/Bug/bug.php?op=show&bugid=3637
http://www.cmake.org/Bug/bug.php?op=show&bugid=4145

however it is still not fixed ...

Since there is easy workaround:

ln -s /usr/share/swig/[actual swig version] /usr/share/swig1.3

I would like to ask you to add this to the swig ebuild - TIA

Reproducible: Always

Steps to Reproduce:
Comment 1 Jakub Moc (RETIRED) gentoo-dev 2007-07-31 11:54:58 UTC
Please, post the emerge output, swig version and emerge --info.
Comment 2 kavol 2007-07-31 12:42:31 UTC
(In reply to comment #1)
> Please, post the emerge output, swig version and emerge --info.

sorry, I did not express clearly - this is not a problem when emerging cmake but rather when trying to compile something depending on swig with cmake, just like:

*** snip ***
>>> Compiling source in /var/tmp/portage/media-sound/canorus-9999/work/canorus-9999 ...
-- Check for working C compiler: /usr/lib/ccache/bin/gcc
-- Check for working C compiler: /usr/lib/ccache/bin/gcc -- works
-- Check size of void*
-- Check size of void* - done
-- Check for working CXX compiler: /usr/lib/ccache/bin/c++
-- Check for working CXX compiler: /usr/lib/ccache/bin/c++ -- works
-- Looking for Q_WS_X11
-- Looking for Q_WS_X11 - found
-- Looking for Q_WS_MAC
-- Looking for Q_WS_MAC - not found.
-- Looking for Q_WS_WIN
-- Looking for Q_WS_WIN - not found.
-- Found Qt-Version 4.3.0
SWIG *not* found, disabling SWIG!
Ruby Library and Development files *not* found. Ruby extensions disabled!
Python Library and Development files found. Python extensions enabled.
CMake Error: Error in cmake code at
/var/tmp/portage/media-sound/canorus-9999/work/canorus-9999/src/CMakeLists.txt:350:
Unknown CMake command "SWIG_ADD_MODULE".
-- Configuring done
*** snip ***


using the suggested workaround:

# ln -s /usr/share/swig/1.3.31/ /usr/share/swig1.3
# emerge -av canorus
*** snip ***
-- Found Qt-Version 4.3.0
SWIG found, using scripting extensions.
Ruby Library and Development files *not* found. Ruby extensions disabled!
Python Library and Development files found. Python extensions enabled.
-- Configuring done
-- Generating done
*** snip ***


# emerge --info
Portage 2.1.2.9 (default-linux/x86/2006.1/desktop, gcc-4.1.2, glibc-2.5-r4, 2.6.21-gentoo-r4 i686)
=================================================================
System uname: 2.6.21-gentoo-r4 i686 AMD Duron(tm) processor
Gentoo Base System release 1.12.9
Timestamp of tree: Mon, 30 Jul 2007 15:20:01 +0000
distcc 2.18.3 i686-pc-linux-gnu (protocols 1 and 2) (default port 3632) [enabled]
ccache version 2.4 [enabled]
dev-java/java-config: 1.3.7, 2.0.33-r1
dev-lang/python:     2.4.4-r4
dev-python/pycrypto: 2.0.1-r6
dev-util/ccache:     2.4-r7
sys-apps/sandbox:    1.2.17
sys-devel/autoconf:  2.13, 2.61
sys-devel/automake:  1.5, 1.6.3, 1.7.9-r1, 1.9.6-r2, 1.10
sys-devel/binutils:  2.17
sys-devel/gcc-config: 1.3.16
sys-devel/libtool:   1.5.23b
virtual/os-headers:  2.6.21
ACCEPT_KEYWORDS="x86"
AUTOCLEAN="yes"
CBUILD="i686-pc-linux-gnu"
CFLAGS="-Os -march=athlon-tbird -pipe -fomit-frame-pointer"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/kde/3.5/env /usr/kde/3.5/share/config /usr/kde/3.5/shutdown /usr/kde/svn/env /usr/kde/svn/share/config /usr/kde/svn/shutdown /usr/share/X11/xkb /usr/share/config"
CONFIG_PROTECT_MASK="/etc/env.d /etc/env.d/java/ /etc/gconf /etc/revdep-rebuild /etc/terminfo"
CXXFLAGS="-Os -march=athlon-tbird -pipe -fomit-frame-pointer"
DISTDIR="/usr/portage/distfiles"
FEATURES="ccache distcc distlocks metadata-transfer sandbox sfperms strict"
GENTOO_MIRRORS="http://gentoo.supp.name/"
LANG="sk_SK.UTF-8"
LC_ALL="sk_SK.UTF-8"
LINGUAS="cs en sk"
MAKEOPTS="-j3"
PKGDIR="/usr/portage/packages"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --delete-after --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages --filter=H_**/files/digest-*"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/portage/local/layman/pro-audio /usr/portage/local/layman/kde /root/portage"
SYNC="rsync://rsync.europe.gentoo.org/gentoo-portage"
USE="3dnow 3dnowext X aac accessibility aiglx alsa amrnb amrwb asf berkdb bitmap-fonts branding bzip2 cddb cdr cli cracklib crypt cups dbus decibel dga dri dvd dvdr dvdread emboss encode exif exiv2 fam ffmpeg flac gdbm gif gpgme gphoto2 hal iconv isdnlog java javascript jikes jingle jpeg jpeg2k kde kdehiddenvisibility lame lcms libg++ logrotate mad midi mikmod mmx mmxext mp3 mp4 mpeg mplayer mudflap ncurses nls nptl nptlonly nsplugin offensive ogg opengl openmp pam pcre pdf perl png ppds pppd python qt3 qt4 quicktime readline real reflection rtc sdl session sound spell spl ssl svg symlink taglib tcpd theora tiff timidity translator truetype truetype-fonts type1-fonts unicode usb v4l v4l2 vcd visualization vorbis win32codecs wma x264 x86 xcomposite xine xml xorg xscreensaver xv xvid xvmc zlib" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1 emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mulaw multi null plug rate route share shm softvol" ELIBC="glibc" INPUT_DEVICES="keyboard mouse evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LINGUAS="cs en sk" USERLAND="GNU" VIDEO_CARDS="radeon"
Unset:  CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LDFLAGS, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS
Comment 3 kavol 2007-07-31 12:45:18 UTC
(In reply to comment #1)
> Please, post the emerge output, swig version and emerge --info.

swig-1.3.31
Comment 4 Jakub Moc (RETIRED) gentoo-dev 2007-07-31 12:48:03 UTC
(In reply to comment #2)
> sorry, I did not express clearly - this is not a problem when emerging cmake
> but rather when trying to compile something depending on swig with cmake

Hmmm. Have you got something to test with that's actually in the official tree?
Comment 5 kavol 2007-07-31 15:25:23 UTC
(In reply to comment #4)
> Hmmm. Have you got something to test with that's actually in the official tree?

just tried grepping it with no luck ...