verview
Building the SAGE software on Linux requires various tweaks, depending on the distribution being used. The necessary steps to build SAGE for Ubuntu 9.04 (Jaunty Jackalope) are detailed here.
It is assumed that the software will be installed in a user's home directory. Appropriate changes to the following instructions will be necessary if installing elsewhere.
Compiling SAGE
1. Set up a SAGE environment, in particular a SAGE_DIRECTORY path and associated program execution and library paths. Edit the .bashrc file in the user's home directory. At the end of the .bashrc file, add the following lines:
export SAGE_DIRECTORY=$HOME/sage3.0
export PATH=${SAGE_DIRECTORY}/bin:${PATH}
if [ -z ${LD_LIBRARY_PATH} ]; then
export LD_LIBRARY_PATH=${SAGE_DIRECTORY}/lib
else
export LD_LIBRARY_PATH=${SAGE_DIRECTORY}/lib:${LD_LIBRARY_PATH}
fi
Now exit any shell being used and open a new one. Run the command:
env | grep SAGE
and
env | grep LD_
These commands should return results consistent with the settings made above. There's no point in continuing until this step has been completed successfully.
2. Now unpack the source tarball and make some small changes to the source code to enable correct compilation. In the home directory, unpack the source tarball e.g.
cd
tar zxvf sage3--03-24-09.tgz
which will create the sage3.0 directory (your SAGE_DIRECTORY)
If audio support is desired, edit sage3.0/config.mk. Change the the line:
#AUDIO=1
to
AUDIO=1
Now edit the file sage3.0/app/FileViewer/ImageViewer/imageviewer.cpp - find the lines
#if MagickLibVersion >= 0x645
#define MagickGetImagePixels MagickGetAuthenticPixels
#endif
and insert
#if 0
before the the first of these lines. Add:
#endif
after the last of those lines. The complete sequence should be:
#if 0
#if MagickLibVersion >= 0x645
#define MagickGetImagePixels MagickGetAuthenticPixels
#endif
#endif
Do exactly the same in the file sage3.0/app/FileViewer/ImageViewer/imgToDxt.cpp
Now edit the sage3.0/config.mk file. Change the line:
ARCHITECTURE=$(shell uname -p)
to
ARCHITECTURE=$(shell uname -m)
Then, if running on amd64 architecture, change (at about line 97):
XLIBS=-L/usr/X11R6/lib64 -lGLU -lGL -lXmu -lXi -lXext -lX11
to
XLIBS=-L/usr/lib64 -lGLU -lGL -lXmu -lXi -lXext -lX11
Otherwise, if running a 32bit system, change (at about line 120):
XLIBS=-L/usr/X11R6/lib -lGLU -lGL -lXmu -lXi -lXext -lX11
to
XLIBS=-L/usr/lib -lGLU -lGL -lXmu -lXi -lXext -lX11
3. Install various prerequisite packages with the following apt-get command - some may already be installed but apt-get is smart enough to do the right thing. Run:
sudo apt-get install build-essential libsdl1.2-dev freeglut3-dev libxmu-dev libxi-dev libreadline5-dev libmagickwand-dev portaudio19-dev python-wxgtk2.8 libglew1.5-dev python-numpy
(the last two of these packages are needed later for running the SAGE software, not actually compiling it, but may as well install them all at once)
4. The software can now be built from inside the sage3.0 directory:
cd $SAGE_DIRECTORY
make install
Note:
don't go into the src directory to build; do the build from $SAGE_DIRECTORY
don't do a plain make first; go straight to make install
Running SAGE
Firstly, go to SAGE's bin directory:
cd $SAGE_DIRECTORY/bin
Now check the script named sage. The line in it which reads:
if [ `uname` == "Linux" ]
should be changed to:
if [ `uname` = "Linux" ]
4/10/10
Bài đăng phổ biến
-
1.1.1. THỰC HÀNH 4: THIẾT LẬP FORUM SỬ DỤNG PHP VÀ MYSQL Cài đặt MyBB Gói mã nguồn mở được cung cấp hoàn toàn miễn phí tại tran...
-
filed in Computers , Lattice Boltzmann Method , Personal on Jan.29, 2010 MPI in CodeBlocks Codeblocks is great application devel...
-
1.1.1. CẤU HÌNH FTP SERVER Mô hình và yêu cầu hệ thống Cấu hình cho phép người dùng anonymous và local user upload dữ liệu lên ...
-
1.1.1. THỰC HÀNH 1: CẤU HÌNH APACHE WEB SERVER MÔ HÌNH VÀ YÊU CẦU BÀI TẬP MÔ HÌNH HOẠT ĐỘNG Kiểm tra nội ...
-
verview Building the SAGE software on Linux requires various tweaks, depending on the distribution being used. The necessary steps to bui...
-
1.1. DỊCH VỤ FTP 1.1.1. GIỚI THIỆU FTP FTP được viết tắt từ chuỗi File Transfer Protocol. Giao thức này được xây dựng ...
-
How to Install Canon LBP Printers in Ubuntu MAR 20 TH , 2010 UPDATE 4 : Version 2.4 added support for printer models LBP6000 and LBP6...
-
Phần mềm học anh văn hiệu quả | Longman Dictionary of Contemporary English 5th Edition [Từ điển anh ngữ] Longman Dictionary of Co...
-
Mathworks Matlab R2012a-ISO Mathworks Matlab R2012a-ISO - MATLAB® is a high-level technical computing language and in...
-
5.2. CÂU HỎI ÔN TẬP VỀ DNS 5.2.1. THỰC HÀNH 1: THIẾT LẬP DNS QUẢN LÝ MIỀN CỤC BỘ Trung tâm đào tạo tin học vừa thuê một tên miền “serverli...