Bug 67905 - scilab-3.0 does not finish emerge with USE="-tcltk" + broken dependencies
Bug#: 67905 Product:  Gentoo Linux Version: unspecified Platform: x86
OS/Version: Linux Status: RESOLVED Severity: normal Priority: P2
Resolution: FIXED Assigned To: sci@gentoo.org Reported By: xanderhsia@comcast.net
Component: Ebuilds
URL: 
Summary: scilab-3.0 does not finish emerge with USE="-tcltk" + broken dependencies
Keywords:  
Status Whiteboard: 
Opened: 2004-10-17 10:16 0000
Description:   Opened: 2004-10-17 10:16 0000
USE="-tcltk" emerge scilab results in scilab being executed and prompting for
input during the compilation 
-------------- Snippet--------------
Type "make tests" in examples directory
  to test link and addinter features
make[1]: Leaving directory
`/var/tmp/portage/scilab-3.0/work/scilab-3.0/examples'
making all in tests...
make[1]: Entering directory `/var/tmp/portage/scilab-3.0/work/scilab-3.0/tests'
Type "make tests" in tests directory
  to test the  distribution
 SEE THE README FILE (IMPORTANT)
make[1]: Leaving directory `/var/tmp/portage/scilab-3.0/work/scilab-3.0/tests'
making man in man...
make[1]: Entering directory `/var/tmp/portage/scilab-3.0/work/scilab-3.0/man'
make[2]: Entering directory
`/var/tmp/portage/scilab-3.0/work/scilab-3.0/man/eng'
Creating html help files
/var/tmp/portage/scilab-3.0/work/scilab-3.0/bin/scilab -l eng  \
-nwni -e "xmltohtml([],[],'html-rev.xsl');quit"
        -------------------------------------------
                         Scilab-3.0

                  Copyright (c) 1989-2004
              Consortium Scilab (INRIA, ENPC)
        -------------------------------------------


Startup execution:
  loading initial environment
if with_tk()& ~with_gtk()
                          !--error    44
first argument is incorrect
at line     119 of exec file called by :
exec('SCI/scilab.star',-1);;quit


-->quit
Creating whatis.htm in programming
Creating whatis.htm in graphics
----------- End Snippet ------------

I manually typed in quit at the prompt to make it continue. It would do a few
more operations and would end up presenting me with a prompt again. After a few
of these I killed the emerge.

Reproducible: Always
Steps to Reproduce:
1. USE="-tcltk" emerge scilab
2.
3.

Actual Results:  
During compilation continuously get input prompts

Expected Results:  
Install without user intervention


emerge info:
Portage 2.0.51_rc9 (default-x86-2004.0, gcc-3.4.2, glibc-2.3.4.20041006-r0,
2.6.8-gentoo-r8 i686)
=================================================================
System uname: 2.6.8-gentoo-r8 i686 AMD Athlon(tm) processor
Gentoo Base System version 1.5.3
distcc 2.18 i686-pc-linux-gnu (protocols 1 and 2) (default port 3632)
[disabled]
ccache version 2.3 [enabled]
Autoconf: sys-devel/autoconf-2.59-r5
Automake: sys-devel/automake-1.8.5-r1
Binutils: sys-devel/binutils-2.15.92.0.2-r1
Headers:  sys-kernel/linux26-headers-2.6.8.1-r1
Libtools: sys-devel/libtool-1.5.2-r5
ACCEPT_KEYWORDS="x86 ~x86"
AUTOCLEAN="yes"
CFLAGS="-march=athlon -O3"
CHOST="i686-pc-linux-gnu"
COMPILER=""
CONFIG_PROTECT="/etc /usr/X11R6/lib/X11/xkb /usr/kde/2/share/config
/usr/kde/3.2/share/config /usr/kde/3.3/env /usr/kde/3.3/share/config
/usr/kde/3.3/shutdown /usr/kde/3/share/config /usr/lib/mozilla/defaults/pref
/usr/share/config /usr/share/texmf/dvipdfm/config/
/usr/share/texmf/dvips/config/ /usr/share/texmf/tex/generic/config/
/usr/share/texmf/tex/platex/config/ /usr/share/texmf/xdvi/ /var/qmail/control"
CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d"
CXXFLAGS="-march=athlon -O3"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoaddcvs ccache distlocks sandbox"
GENTOO_MIRRORS="ftp:///ftp-stud.fht-esslingen.de/pub/Mirrors/gentoo/
http://mirror.tucdemonic.org/gentoo/ http://mirror.datapipe.net/gentoo
http://open-systems.ufl.edu/mirrors/gentoo http://mirror.datapipe.net/gentoo"
MAKEOPTS="-j2"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/local/portage"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="3dnow 3dnowex X acl acpi acpi4linux aim alsa apm atlas avi berkdb
bitmap-fonts blas bonobo cairo cddb cdparanoia cdr cdrom chroot clisp crypt
cscope cups dio directfb divx4linux djbfft dnd dts dv dvd dvdr dvdread eds
encode erandom evms2 evo exif f77 faac faad fam fastcgi fbcon ffmpeg fftw flac
foomaticdb freetype ftp gb gd gdbm gif gimp gimpprint ginac gnome gnomedb
gnuplot gphoto2 gpm gsl gstreamer gtk gtk2 gtkhtml guile hal hbci hdf5 icq
ieee1394 imagemagick imap imlib ipv6 irda jabber jack jack-tmpfs java
javascript
jikes joystick jpeg kde lcms libwww lirc lufsusermount mad maildir matroska
mcal
mikmod mime mmap mmx mmx2 motif mozilla mozsvg mp3 mpeg mpeg4 mpi mplayer mysql
ncurses nls nptl nvidia odbc ofx oggvorbis openal opengl opie oss pam pcre pda
pdf pdflib perl pic plotutils png posix postgres ppds python qt quicktime
quotes
readline rtc samba scanner sdl slang sndfile snortsam spamassassin spell sse
ssl
stroke svg svga tcpd tetex theora tiff transcode truetype usb v4l v4l2 vnc wmf
x86 xfs xine xinerama xml xml2 xmms xosd xprint xrandr xsl xv xvid xvmc zlib"

------- Comment #1 From Gregorio Guidi (RETIRED) 2004-11-04 10:22:32 0000 -------
Created an attachment (id=43294) [details]
scilab-initialization.patch

Could you try the attached patch? It seems to work here.

While you're at it, could you clean up a bit the dependencies?
I did some tests: to compile against gtk-2, only gtk+-2, libgtkhtml-2
and libzvt are needed. glib-2 can be removed, and gnome-libs-1 should
probably be moved to the gtk-1 only case.
virtual/x11 is also redundant.

Moreover, here scilab does not compile with --without-tk if gtk is not 
installed. So, if someone has -tcltk -gtk, the ebuild should force a default
between them.

In the end, if the default is gtk, RDEPEND should look something like:
RDEPEND="sys-libs/ncurses
	atlas? ( dev-libs/atlas )
	gtk? (
		media-libs/jpeg
		media-libs/libpng
		sys-libs/zlib
		gtk2? ( =x11-libs/gtk+-2*
			=gnome-extra/libgtkhtml-2*
			x11-libs/libzvt
			=gnome-extra/libgtkhtml-2*
		)
		!gtk2? ( =x11-libs/gtk+-1.2*
			 >=gnome-base/gnome-libs-1.4.2
		)
	)
	!gtk? ( >=dev-lang/tk-8.4
		>=dev-lang/tcl-8.4 )
	Xaw3d? ( x11-libs/Xaw3d )"
(or the other way around if tk is default, or maybe print an error and die
in the -gtk -tcltk case?)

grepping through the sources, it seems that libxslt is not needed
(sablotron is used to convert xml to html) so it can be removed from DEPEND.

------- Comment #2 From Gregorio Guidi (RETIRED) 2005-01-26 10:56:15 0000 -------
sci team: can I commit a revision with the cleanup suggested above?

------- Comment #3 From Gregorio Guidi (RETIRED) 2005-03-02 09:24:32 0000 -------
Committed as scilab-3.0-r1.