[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Terminal in Octave GUI should work again
From: |
Ben Abbott |
Subject: |
Re: Terminal in Octave GUI should work again |
Date: |
Sun, 29 Jan 2012 23:29:58 -0500 |
On Jan 29, 2012, at 9:00 PM, Jacob Dawid wrote:
> Hello,
>
> today I pushed a fix for the Linux terminal in Octave GUI. Octave now doesn't
> run in embedded mode anymore and thinks it runs in a terminal. This _only_
> works for Linux as of now. Please understand that I don't have/use a Mac, so
> I can't provide bugfixes for MacOS. If anyone using a Mac could try to make
> it compile for MacOS and send me a patch, this would be great.
>
> In order to test it you will need to pull the latest sources for qterminal.
> Every bug report helps bringing that terminal into a usable state.
>
> Michael: What about getting the Console2 approach in? Does it already work on
> Windows?
>
> Jacob
Jacob,
I'm happy to try to help on MacOS X.
I've set up a second archive to play with.
hg clone ./octave ./gui
hg update gui
cd gui/gui
I don't have qmake-qt4. It is just qmake for me. So I could do ...
sed -i '' -e 's/qmake-qt4/qmake/'compile.sh
sed -i '' -e 's/qmake-qt4/qmake/'get-qirc.sh
sed -i '' -e 's/qmake-qt4/qmake/'get-qterminal.sh
... or, maybe the better solution is what I did below ...
sudo ln -s /opt/local/bin/qmake /usr/local/bin/qmake-qt4
I also modified octave-gui.pro.in and octave-gui.pro.in to replace
'-L/opt/local-native/lib' with '-L/opt/local/lib'.
Then I tried ...
./compile.sh
Which ended with ...
/Developer/usr/bin/llvm-g++-4.2 -headerpad_max_install_names -o bin/octave-gui
object-files/lexeroctavegui.o object-files/MainWindow.o
object-files/WorkspaceView.o object-files/HistoryDockWidget.o
object-files/FilesDockWidget.o object-files/FileEditorMdiSubWindow.o
object-files/BrowserWidget.o object-files/ImageViewerMdiSubWindow.o
object-files/SettingsDialog.o object-files/OctaveGUI.o
object-files/ResourceManager.o object-files/CommandLineParser.o
object-files/OctaveCallbackThread.o object-files/OctaveLink.o
object-files/OctaveMainThread.o object-files/ReadlineAdapter.o
object-files/WelcomeWizard.o object-files/moc_lexeroctavegui.o
object-files/moc_MainWindow.o object-files/moc_WorkspaceView.o
object-files/moc_HistoryDockWidget.o object-files/moc_FilesDockWidget.o
object-files/moc_FileEditorMdiSubWindow.o object-files/moc_BrowserWidget.o
object-files/moc_SettingsDialog.o object-files/moc_OctaveCallbackThread.o
object-files/moc_OctaveLink.o object-files/moc_OctaveMainThread.o
object-files/moc_ReadlineAdapter.o object-files/moc_WelcomeWizard.o
-L/opt/local/lib/octave/3.6.0-rc1 -lqscintilla2 -Lqirc/libqirc -lqirc -lm
-loctinterp -loctave -lcruft -lutil -Lqterminal/libqterminal -lqterminal
-L/opt/local/lib -lQtWebKit_debug -lQtGui_debug -lQtNetwork_debug
-lQtCore_debug
ld: library not found for -lqterminal
So I did the naively obvious thing ...
cd qterminal/
make
cd libqterminal/ && make -f Makefile
/Developer/usr/bin/llvm-g++-4.2 -c -pipe -g -gdwarf-2 -fPIC -Wall -W
-DHAVE_POSIX_OPENPT -DQT_GUI_LIB -DQT_CORE_LIB -DQT_SHARED
-I/opt/local/share/qt4/mkspecs/macx-g++ -I. -I. -I/opt/local/include/QtGui
-I/opt/local/include/QtCore -I/opt/local/include -o kpty.o kpty.cpp
kpty.cpp: In member function ‘void KPty::login(const char*, const char*)’:
kpty.cpp:448: warning: ‘utmp’ is deprecated (declared at /usr/include/utmp.h:96)
kpty.cpp:505: error: ‘utmpname’ was not declared in this scope
kpty.cpp:506: error: ‘setutent’ was not declared in this scope
kpty.cpp:507: error: ‘pututline’ was not declared in this scope
kpty.cpp:508: error: ‘endutent’ was not declared in this scope
kpty.cpp:509: error: ‘updwtmp’ was not declared in this scope
kpty.cpp: In member function ‘void KPty::logout()’:
kpty.cpp:544: warning: ‘utmp’ is deprecated (declared at /usr/include/utmp.h:96)
kpty.cpp:544: warning: ‘utmp’ is deprecated (declared at /usr/include/utmp.h:96)
kpty.cpp:555: error: ‘utmpname’ was not declared in this scope
kpty.cpp:556: error: ‘setutent’ was not declared in this scope
kpty.cpp:557: error: ‘getutline’ was not declared in this scope
kpty.cpp:574: error: ‘pututline’ was not declared in this scope
kpty.cpp:576: error: ‘endutent’ was not declared in this scope
make[1]: *** [kpty.o] Error 1
make: *** [sub-libqterminal-make_default] Error 2
The include file /usr/include/utmp.h is from Apple.
http://www.opensource.apple.com/source/Libc/Libc-763.12/include/utmp.h
I don't know how to proceed from here, any suggestions ?
Ben