Menu

rkward-0.4.0, gentoo some problems

Help
2006-10-22
2013-01-15
  • Andy (lists)

    Andy (lists) - 2006-10-22

    Hi, when compiling rkward-0.4.0 under Linux gentoo I am getting the following error:

    if x86_64-pc-linux-gnu-g++ -DHAVE_CONFIG_H -I. -I. -I../.. -I/usr/kde/3.5/include -I/usr/qt/3/include -I.   -DQT_THREAD_SUPPORT  -D_REENTRANT -DQT_NO_ASCII_CAST  -Wno-long-long -Wundef -ansi -D_XOPEN_SOURCE=500 -D_BSD_SOURCE -Wcast-align -Wconversion -Wchar-subscripts -Wall -W -Wpointer-arith -O2 -march=k8 -O2 -pipe -Wformat-security -Wmissing-format-attribute -Wno-non-virtual-dtor -fno-exceptions -fno-check-new -fno-common  -MT rkworkplaceview.o -MD -MP -MF ".deps/rkworkplaceview.Tpo" -c -o rkworkplaceview.o rkworkplaceview.cpp; \
    then mv -f ".deps/rkworkplaceview.Tpo" ".deps/rkworkplaceview.Po"; else rm -f ".deps/rkworkplaceview.Tpo"; exit 1; fi
    rkworkplaceview.cpp: In member function ‘RKMDIWindow* RKWorkplaceView::activePage()’:
    rkworkplaceview.cpp:110: error: cast from ‘RKMDIWindow*’ to ‘int’ loses precision
    rkworkplaceview.cpp:110: error: cast from ‘QWidget*’ to ‘int’ loses precision
    rkworkplaceview.cpp: In member function ‘void RKWorkplaceView::setPage(int)’:
    rkworkplaceview.cpp:135: error: cast from ‘RKMDIWindow*’ to ‘int’ loses precision
    make[3]: *** [rkworkplaceview.o] Error 1
    make[3]: Leaving directory `/var/tmp/portage/rkward-0.4.0/work/rkward-0.4.0/rkward/windows'
    make[2]: *** [all-recursive] Error 1
    make[2]: Leaving directory `/var/tmp/portage/rkward-0.4.0/work/rkward-0.4.0/rkward'
    make[1]: *** [all-recursive] Error 1
    make[1]: Leaving directory `/var/tmp/portage/rkward-0.4.0/work/rkward-0.4.0'
    make: *** [all] Error 2

    !!! ERROR: sci-mathematics/rkward-0.4.0 failed.
    Call stack:
      ebuild.sh, line 1546:   Called dyn_compile
      ebuild.sh, line 937:   Called src_compile
      rkward-0.4.0.ebuild, line 34:   Called die

    !!! make failed
    !!! If you need support, post the topmost build error, and the call stack if relevant.

    --------------------------- ACCESS VIOLATION SUMMARY ---------------------------
    LOG FILE = "/var/log/sandbox/sandbox-sci-mathematics_-_rkward-0.4.0-22990.log"

    open_wr:   /usr/qt/3/etc/settings/.qtrc.lock
    open_wr:   /usr/qt/3/etc/settings/.qtrc.lock
    --------------------------------------------------------------------------------
    !!! This ebuild is from an overlay: '/usr/local/sci'

    I am not an expert so please keep that in mind when replying :-)

    The installed dependencies on my system are:
    x11-libs/qt (3.3.6-r1 4.1.4):
    kde-base/kdelibs (3.5.2-r6)
    dev-lang/R (2.2.1)
    dev-lang/php (5.1.6-r6)

    How can I solve this compile issue?

    Thanks
    Ben

     
    • Thomas Friedrichsmeier

      Hi Ben,

      I don't know exactly, how building works on gentoo, so I'm not sure, whether I can give you valid hands on instructions. But I do know what's causing this, and I'll try:

      This is a known compilation bug on 64bit systems. The failure to compile is on two debug statement, which do not serve any "real" purpose, and - as it turns out - were not written carefully enough.

      The most simple solution is to effectively remove those debug statements: In your rkward sources, edit the file rkward/windows/rkworkplaceview.cpp

      In lines 110 and 135, add a "//" at the start of the line, before the "RK_DO...". This will turn those lines into comments. Compilation should work, now.

      Now, the difficult part is, I don't know, where the sources are at in a gentoo build. /var/tmp/portage/rkward-0.4.0/work/rkward-0.4.0/ sounds like a temporary location, but you might want to have a look there.

      Can some gentoo users shed some more light on this?

       
    • Andy (lists)

      Andy (lists) - 2006-10-22

      OK, it worked. I didn't use the gentoo ebuild this time but proceded as normal: ./configure, make, make install. I noticed that --with-qt-includes=/usr/include/qt4 doesn't work. Is it bad? Fortunately my system has qt-3.3.6 installed, too, so the installation went through.

      Two things come up immediately after one lanuches rkward. The man window pops up as a very small one. One needs to resize it to see the menu items in one row. But consecutive launches do not exibit this problem, just the first start.
      Also, Import -> Load Data: where it says Table name one cannot see the actual name because the field is too small to show the characters. There is no way to resize it either.

      I am a total newbe in R so I only make comments on the GUI. I wonder whether I will be able to use rkward to learn a little bit of R? For the beginning I want to do two things:

      load data into R
      plot the data from within R

      Here is my original question on R-sig-finance mailing list:
      https://stat.ethz.ch/pipermail/r-sig-finance/2006q4/001102.html

      thanks for a nice piece of software.
      Andy

       
      • Thomas Friedrichsmeier

        RKWard does not use Qt4 at all, yet. We wait until KDE 4 comes out (may be another while), and after that, we'll probably also need some time to port rkward. The message about KDE4/Qt4 in the ChangeLog merely concerns changes that will make this last step - porting to KDE 4 once released - easier. Qt 3 is correct.

        I've changed the developlment version to start the window maximized on the very first startup.

        About Import->Load Data: This should now be fixed in the development version as well. As temporary workarounds, either
        a) use smaller fonts, this should not happen then
        b) just use the default setting for now (it's "rk.temp.table"). You can change the name later by clicking on "Workspace" on the left->right click the object->Rename
        Sorry about the inconvenience, and thanks for reporting this important issue.

        We do hope RKWard will assist you in finding your way around R, but we must also admit, that RKWard only offers easy dialogs for very little of the high level functionality you are looking for. Particularily, there is no GUI interface to ohlcPlot () in RKWard, yet. So, while we hope to make learning R a bit easier to you, you'll still have to learn some R before you can achieve what you're trying to do.

        Some notes on your task:
        a) load data into R: You already figured out, how to do this
        b) ohlcPlot ():
        1) First (install and) load the package fMultivar. Settings->Configure Packages can help you with that.
        2) Once fMultivar is installed, you can invoke function help by using the "Help search" window, or by right clicking on the function in package fMultivar (in the "Workspace" browser).
        3) ohlcPlot () appears to require a precise format of data. Assuming the table with your data is called my.data:
        # ts <- as.ts (data.frame (Open=my.data$Open, High=my.data$High, Low=my.data$Low, Close=my.data$Close))
        (First create a new temporary table with only the columns Open, High, Low, Close, then convert it into a time-series, then assign it to a new object "ts")
        4) For a first plot, you'll ignore most parameters, and just use:
        ohlcPlot (ts)

        But, in fact, as you have been referred to, "An introduction to R" is definitely recommended reading. If you have R HTML help installed, this is available via Help->Help on R, in RKWard.

        You can watch some of what RKWard is doing in the "Command Log", but RKWard simply does not know how to do advanced things like an ohlcPlot, yet.

         
    • sparky

      sparky - 2006-10-25

      Thanks Thomas,
      Was able to get it to compile on my 64bit SuSE machine again.