annotate README.Linux @ 3326:c19f4b9484af

[project @ 1999-10-29 21:52:12 by jwe]
author jwe
date Fri, 29 Oct 1999 21:52:30 +0000
parents 8901c1183179
children 0ae310231c46
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
2602
9cbbbcf5b6f5 [project @ 1997-01-07 06:18:23 by jwe]
jwe
parents: 2601
diff changeset
1 Since July 1996, most work on Octave has been done using a Linux
9cbbbcf5b6f5 [project @ 1997-01-07 06:18:23 by jwe]
jwe
parents: 2601
diff changeset
2 system, and a number of people who regularly test Octave snapshot
3142
b06bffc95051 [project @ 1998-02-03 08:38:41 by jwe]
jwe
parents: 2993
diff changeset
3 releases also primarily use Linux systems. Because of this, I believe
b06bffc95051 [project @ 1998-02-03 08:38:41 by jwe]
jwe
parents: 2993
diff changeset
4 Octave should run reasonably well on most current Linux systems.
b06bffc95051 [project @ 1998-02-03 08:38:41 by jwe]
jwe
parents: 2993
diff changeset
5 However, there have been some problems in the past, usually the result
b06bffc95051 [project @ 1998-02-03 08:38:41 by jwe]
jwe
parents: 2993
diff changeset
6 of improper installation of compilers or libraries. Sometimes the
b06bffc95051 [project @ 1998-02-03 08:38:41 by jwe]
jwe
parents: 2993
diff changeset
7 problems have happened because of a botched upgrade or even a buggy
b06bffc95051 [project @ 1998-02-03 08:38:41 by jwe]
jwe
parents: 2993
diff changeset
8 Linux distribution.
2593
3190d595d0da [project @ 1996-12-14 15:45:39 by jwe]
jwe
parents:
diff changeset
9
3142
b06bffc95051 [project @ 1998-02-03 08:38:41 by jwe]
jwe
parents: 2993
diff changeset
10 If you can, you should probably install Octave from one of the binary
b06bffc95051 [project @ 1998-02-03 08:38:41 by jwe]
jwe
parents: 2993
diff changeset
11 distributions available from ftp.che.wisc.edu, or using one of the
b06bffc95051 [project @ 1998-02-03 08:38:41 by jwe]
jwe
parents: 2993
diff changeset
12 Debian or RPM packages that are available at other sites. For
3143
dbf073585f68 [project @ 1998-02-04 07:43:52 by jwe]
jwe
parents: 3142
diff changeset
13 example, Dirk Eddelbuettel <edd@debian.org> maintains the Debian
dbf073585f68 [project @ 1998-02-04 07:43:52 by jwe]
jwe
parents: 3142
diff changeset
14 Octave package and usually has them ready within a day or so of new
dbf073585f68 [project @ 1998-02-04 07:43:52 by jwe]
jwe
parents: 3142
diff changeset
15 Octave releases. They are available via the WWW at
3151
8901c1183179 [project @ 1998-02-07 17:26:06 by jwe]
jwe
parents: 3143
diff changeset
16 http://www.debian.org/packages.html.
3142
b06bffc95051 [project @ 1998-02-03 08:38:41 by jwe]
jwe
parents: 2993
diff changeset
17
b06bffc95051 [project @ 1998-02-03 08:38:41 by jwe]
jwe
parents: 2993
diff changeset
18 If for some reason you can't (or choose not to) install Octave from
b06bffc95051 [project @ 1998-02-03 08:38:41 by jwe]
jwe
parents: 2993
diff changeset
19 one of the binary distributions or by using one of the Debian or RPM
b06bffc95051 [project @ 1998-02-03 08:38:41 by jwe]
jwe
parents: 2993
diff changeset
20 packages and something goes wrong, please check the following list to
b06bffc95051 [project @ 1998-02-03 08:38:41 by jwe]
jwe
parents: 2993
diff changeset
21 see if your problem is already well known before reporting a bug.
2593
3190d595d0da [project @ 1996-12-14 15:45:39 by jwe]
jwe
parents:
diff changeset
22
2596
7020b79afd9c [project @ 1996-12-14 19:12:11 by jwe]
jwe
parents: 2593
diff changeset
23 Octave compiles, but it won't run
7020b79afd9c [project @ 1996-12-14 19:12:11 by jwe]
jwe
parents: 2593
diff changeset
24 ---------------------------------
7020b79afd9c [project @ 1996-12-14 19:12:11 by jwe]
jwe
parents: 2593
diff changeset
25
7020b79afd9c [project @ 1996-12-14 19:12:11 by jwe]
jwe
parents: 2593
diff changeset
26 If you can compile Octave, but it crashes with a segmentation fault
7020b79afd9c [project @ 1996-12-14 19:12:11 by jwe]
jwe
parents: 2593
diff changeset
27 right away, you probably have incompatible versions of libc and libg++
7020b79afd9c [project @ 1996-12-14 19:12:11 by jwe]
jwe
parents: 2593
diff changeset
28 installed, or you have a version of the dynamic loader, ld.so, that is
7020b79afd9c [project @ 1996-12-14 19:12:11 by jwe]
jwe
parents: 2593
diff changeset
29 incompatible with your versions of the libraries, or both.
2593
3190d595d0da [project @ 1996-12-14 15:45:39 by jwe]
jwe
parents:
diff changeset
30
2596
7020b79afd9c [project @ 1996-12-14 19:12:11 by jwe]
jwe
parents: 2593
diff changeset
31 Octave won't even compile
7020b79afd9c [project @ 1996-12-14 19:12:11 by jwe]
jwe
parents: 2593
diff changeset
32 -------------------------
2593
3190d595d0da [project @ 1996-12-14 15:45:39 by jwe]
jwe
parents:
diff changeset
33
3190d595d0da [project @ 1996-12-14 15:45:39 by jwe]
jwe
parents:
diff changeset
34 If you can't compile Octave, you should first check to see that your
3190d595d0da [project @ 1996-12-14 15:45:39 by jwe]
jwe
parents:
diff changeset
35 compiler and header files are properly installed. Do you have
3190d595d0da [project @ 1996-12-14 15:45:39 by jwe]
jwe
parents:
diff changeset
36 multiple versions of the g++ include files on your system? Are you
2596
7020b79afd9c [project @ 1996-12-14 19:12:11 by jwe]
jwe
parents: 2593
diff changeset
37 sure that your copy of g++ is finding the right set? You can find out
7020b79afd9c [project @ 1996-12-14 19:12:11 by jwe]
jwe
parents: 2593
diff changeset
38 by compiling a simple C++ program with -v:
7020b79afd9c [project @ 1996-12-14 19:12:11 by jwe]
jwe
parents: 2593
diff changeset
39
7020b79afd9c [project @ 1996-12-14 19:12:11 by jwe]
jwe
parents: 2593
diff changeset
40 bash$ cat foo.cc
7020b79afd9c [project @ 1996-12-14 19:12:11 by jwe]
jwe
parents: 2593
diff changeset
41 #include <iostream.h>
2663
00b2eff19bf5 [project @ 1997-02-08 21:58:49 by jwe]
jwe
parents: 2647
diff changeset
42 int main (void) { cerr << "yo\n"; return 0; }
2596
7020b79afd9c [project @ 1996-12-14 19:12:11 by jwe]
jwe
parents: 2593
diff changeset
43
7020b79afd9c [project @ 1996-12-14 19:12:11 by jwe]
jwe
parents: 2593
diff changeset
44 bash$ g++ -v foo.cc
7020b79afd9c [project @ 1996-12-14 19:12:11 by jwe]
jwe
parents: 2593
diff changeset
45 gcc -v foo.cc -lg++ -lstdc++ -lm
7020b79afd9c [project @ 1996-12-14 19:12:11 by jwe]
jwe
parents: 2593
diff changeset
46 Reading specs from /usr/lib/gcc-lib/i486-linux/2.7.2/specs
7020b79afd9c [project @ 1996-12-14 19:12:11 by jwe]
jwe
parents: 2593
diff changeset
47 gcc version 2.7.2
7020b79afd9c [project @ 1996-12-14 19:12:11 by jwe]
jwe
parents: 2593
diff changeset
48 /usr/lib/gcc-lib/i486-linux/2.7.2/cpp -lang-c++ -v -undef ...
7020b79afd9c [project @ 1996-12-14 19:12:11 by jwe]
jwe
parents: 2593
diff changeset
49 #include "..." search starts here:
7020b79afd9c [project @ 1996-12-14 19:12:11 by jwe]
jwe
parents: 2593
diff changeset
50 #include <...> search starts here:
7020b79afd9c [project @ 1996-12-14 19:12:11 by jwe]
jwe
parents: 2593
diff changeset
51 /usr/lib/g++-include
7020b79afd9c [project @ 1996-12-14 19:12:11 by jwe]
jwe
parents: 2593
diff changeset
52 /usr/local/include
7020b79afd9c [project @ 1996-12-14 19:12:11 by jwe]
jwe
parents: 2593
diff changeset
53 /usr/i486-linux/include
7020b79afd9c [project @ 1996-12-14 19:12:11 by jwe]
jwe
parents: 2593
diff changeset
54 /usr/lib/gcc-lib/i486-linux/2.7.2/include
7020b79afd9c [project @ 1996-12-14 19:12:11 by jwe]
jwe
parents: 2593
diff changeset
55 /usr/include
7020b79afd9c [project @ 1996-12-14 19:12:11 by jwe]
jwe
parents: 2593
diff changeset
56 End of search list.
7020b79afd9c [project @ 1996-12-14 19:12:11 by jwe]
jwe
parents: 2593
diff changeset
57 ...
7020b79afd9c [project @ 1996-12-14 19:12:11 by jwe]
jwe
parents: 2593
diff changeset
58
2597
106ae3df29f5 [project @ 1996-12-17 17:48:01 by jwe]
jwe
parents: 2596
diff changeset
59 If the location of the correct set of include files is not listed in
106ae3df29f5 [project @ 1996-12-17 17:48:01 by jwe]
jwe
parents: 2596
diff changeset
60 the search path, then you might be able to fix that with a symbolic
106ae3df29f5 [project @ 1996-12-17 17:48:01 by jwe]
jwe
parents: 2596
diff changeset
61 link. However, if your version of libg++ was not compiled with your
106ae3df29f5 [project @ 1996-12-17 17:48:01 by jwe]
jwe
parents: 2596
diff changeset
62 current version of gcc, you are likely to run into more trouble.
2596
7020b79afd9c [project @ 1996-12-14 19:12:11 by jwe]
jwe
parents: 2593
diff changeset
63
2598
36a4daa9e3c7 [project @ 1996-12-19 02:27:21 by jwe]
jwe
parents: 2597
diff changeset
64 The linker can't find -lieee
36a4daa9e3c7 [project @ 1996-12-19 02:27:21 by jwe]
jwe
parents: 2597
diff changeset
65 ----------------------------
36a4daa9e3c7 [project @ 1996-12-19 02:27:21 by jwe]
jwe
parents: 2597
diff changeset
66
36a4daa9e3c7 [project @ 1996-12-19 02:27:21 by jwe]
jwe
parents: 2597
diff changeset
67 This can happen because your libraries don't match your version of
36a4daa9e3c7 [project @ 1996-12-19 02:27:21 by jwe]
jwe
parents: 2597
diff changeset
68 gcc. Some recent Linux distributions don't include a libieee.a file
36a4daa9e3c7 [project @ 1996-12-19 02:27:21 by jwe]
jwe
parents: 2597
diff changeset
69 because IEEE support is now the default and the library is no longer
36a4daa9e3c7 [project @ 1996-12-19 02:27:21 by jwe]
jwe
parents: 2597
diff changeset
70 needed, but the gcc specs file still adds -lieee to the linker command
36a4daa9e3c7 [project @ 1996-12-19 02:27:21 by jwe]
jwe
parents: 2597
diff changeset
71 if gcc is invoked with the -mieeefp flag. I believe that you should
36a4daa9e3c7 [project @ 1996-12-19 02:27:21 by jwe]
jwe
parents: 2597
diff changeset
72 be able to fix this by editing the gcc specs file. In it, you should
36a4daa9e3c7 [project @ 1996-12-19 02:27:21 by jwe]
jwe
parents: 2597
diff changeset
73 find something like this:
36a4daa9e3c7 [project @ 1996-12-19 02:27:21 by jwe]
jwe
parents: 2597
diff changeset
74
36a4daa9e3c7 [project @ 1996-12-19 02:27:21 by jwe]
jwe
parents: 2597
diff changeset
75 %{!shared: %{mieee-fp:-lieee} %{p:-lgmon} %{pg:-lgmon} \
36a4daa9e3c7 [project @ 1996-12-19 02:27:21 by jwe]
jwe
parents: 2597
diff changeset
76 %{!ggdb:-lc} %{ggdb:-lg}}
36a4daa9e3c7 [project @ 1996-12-19 02:27:21 by jwe]
jwe
parents: 2597
diff changeset
77
36a4daa9e3c7 [project @ 1996-12-19 02:27:21 by jwe]
jwe
parents: 2597
diff changeset
78 changing it to
36a4daa9e3c7 [project @ 1996-12-19 02:27:21 by jwe]
jwe
parents: 2597
diff changeset
79
36a4daa9e3c7 [project @ 1996-12-19 02:27:21 by jwe]
jwe
parents: 2597
diff changeset
80 %{!shared: %{p:-lgmon} %{pg:-lgmon} %{!ggdb:-lc} %{ggdb:-lg}}
36a4daa9e3c7 [project @ 1996-12-19 02:27:21 by jwe]
jwe
parents: 2597
diff changeset
81
36a4daa9e3c7 [project @ 1996-12-19 02:27:21 by jwe]
jwe
parents: 2597
diff changeset
82 should keep gcc from adding -lieee to the link command. You can find
36a4daa9e3c7 [project @ 1996-12-19 02:27:21 by jwe]
jwe
parents: 2597
diff changeset
83 the location of the specs file by running the command gcc -v.
36a4daa9e3c7 [project @ 1996-12-19 02:27:21 by jwe]
jwe
parents: 2597
diff changeset
84
2601
3723512a827a [project @ 1997-01-06 05:43:16 by jwe]
jwe
parents: 2600
diff changeset
85 If you can't edit the gcc specs file for some reason, another solution
3723512a827a [project @ 1997-01-06 05:43:16 by jwe]
jwe
parents: 2600
diff changeset
86 that should work is to create an empty libieee.a file in the Octave
3723512a827a [project @ 1997-01-06 05:43:16 by jwe]
jwe
parents: 2600
diff changeset
87 src directory using the command:
3723512a827a [project @ 1997-01-06 05:43:16 by jwe]
jwe
parents: 2600
diff changeset
88
3723512a827a [project @ 1997-01-06 05:43:16 by jwe]
jwe
parents: 2600
diff changeset
89 ar cq libieee.a
3723512a827a [project @ 1997-01-06 05:43:16 by jwe]
jwe
parents: 2600
diff changeset
90
2608
bac14003d9bb [project @ 1997-01-18 00:11:48 by jwe]
jwe
parents: 2602
diff changeset
91 NOTE: you should fix this problem (either by editing the specs file or
bac14003d9bb [project @ 1997-01-18 00:11:48 by jwe]
jwe
parents: 2602
diff changeset
92 by creating the library) *before* running configure and compiling
bac14003d9bb [project @ 1997-01-18 00:11:48 by jwe]
jwe
parents: 2602
diff changeset
93 Octave. Otherwise, configure may incorrectly determine that your
bac14003d9bb [project @ 1997-01-18 00:11:48 by jwe]
jwe
parents: 2602
diff changeset
94 system doesn't have support for some IEEE math functions.
bac14003d9bb [project @ 1997-01-18 00:11:48 by jwe]
jwe
parents: 2602
diff changeset
95
2598
36a4daa9e3c7 [project @ 1996-12-19 02:27:21 by jwe]
jwe
parents: 2597
diff changeset
96 My system doesn't have g77
36a4daa9e3c7 [project @ 1996-12-19 02:27:21 by jwe]
jwe
parents: 2597
diff changeset
97 --------------------------
36a4daa9e3c7 [project @ 1996-12-19 02:27:21 by jwe]
jwe
parents: 2597
diff changeset
98
36a4daa9e3c7 [project @ 1996-12-19 02:27:21 by jwe]
jwe
parents: 2597
diff changeset
99 A binary release of g77 that should work with gcc 2.7.2 is available
36a4daa9e3c7 [project @ 1996-12-19 02:27:21 by jwe]
jwe
parents: 2597
diff changeset
100 from sunsite.unc.edu in the directory /pub/Linux/devel/lang/fortran.
3142
b06bffc95051 [project @ 1998-02-03 08:38:41 by jwe]
jwe
parents: 2993
diff changeset
101 There is also a Debian package for g77. Also, g77 is now included as
b06bffc95051 [project @ 1998-02-03 08:38:41 by jwe]
jwe
parents: 2993
diff changeset
102 part of egcs (http://www.cygnus.com/egcs).
2598
36a4daa9e3c7 [project @ 1996-12-19 02:27:21 by jwe]
jwe
parents: 2597
diff changeset
103
2600
c454cd888ada [project @ 1996-12-19 22:35:54 by jwe]
jwe
parents: 2598
diff changeset
104 Problems with g77 on Debian 1.2 systems (and possibly others)
c454cd888ada [project @ 1996-12-19 22:35:54 by jwe]
jwe
parents: 2598
diff changeset
105 -------------------------------------------------------------
c454cd888ada [project @ 1996-12-19 22:35:54 by jwe]
jwe
parents: 2598
diff changeset
106
3143
dbf073585f68 [project @ 1998-02-04 07:43:52 by jwe]
jwe
parents: 3142
diff changeset
107 Your best bet is to upgrade to Debian 1.3 (or some newer version).
dbf073585f68 [project @ 1998-02-04 07:43:52 by jwe]
jwe
parents: 3142
diff changeset
108 If you choose not to do that, here are some old tips for working
dbf073585f68 [project @ 1998-02-04 07:43:52 by jwe]
jwe
parents: 3142
diff changeset
109 around the problem.
dbf073585f68 [project @ 1998-02-04 07:43:52 by jwe]
jwe
parents: 3142
diff changeset
110
dbf073585f68 [project @ 1998-02-04 07:43:52 by jwe]
jwe
parents: 3142
diff changeset
111 The location of the compiler binaries changed, so the g77 0.5.18
2600
c454cd888ada [project @ 1996-12-19 22:35:54 by jwe]
jwe
parents: 2598
diff changeset
112 package can not be used without modification. The problem is that the
c454cd888ada [project @ 1996-12-19 22:35:54 by jwe]
jwe
parents: 2598
diff changeset
113 Debian package was built for gcc 2.7.2 and not 2.7.2.1 and the f771
c454cd888ada [project @ 1996-12-19 22:35:54 by jwe]
jwe
parents: 2598
diff changeset
114 backend is installed in the wrong directory.
c454cd888ada [project @ 1996-12-19 22:35:54 by jwe]
jwe
parents: 2598
diff changeset
115
c454cd888ada [project @ 1996-12-19 22:35:54 by jwe]
jwe
parents: 2598
diff changeset
116 Version 0.5.19 of g77 has just been released. A fixed Debian package
c454cd888ada [project @ 1996-12-19 22:35:54 by jwe]
jwe
parents: 2598
diff changeset
117 may be made available soon. Until then, you can make things work by
c454cd888ada [project @ 1996-12-19 22:35:54 by jwe]
jwe
parents: 2598
diff changeset
118 copying f771 and libf2c.a from /usr/lib/gcc-lib/i486-linux/2.7.2 to
c454cd888ada [project @ 1996-12-19 22:35:54 by jwe]
jwe
parents: 2598
diff changeset
119 /usr/lib/gcc-lib/i486-linux/2.7.2.1.
c454cd888ada [project @ 1996-12-19 22:35:54 by jwe]
jwe
parents: 2598
diff changeset
120
2596
7020b79afd9c [project @ 1996-12-14 19:12:11 by jwe]
jwe
parents: 2593
diff changeset
121 Upgrading your compiler and libraries
7020b79afd9c [project @ 1996-12-14 19:12:11 by jwe]
jwe
parents: 2593
diff changeset
122 -------------------------------------
7020b79afd9c [project @ 1996-12-14 19:12:11 by jwe]
jwe
parents: 2593
diff changeset
123
2598
36a4daa9e3c7 [project @ 1996-12-19 02:27:21 by jwe]
jwe
parents: 2597
diff changeset
124 Installing libg++ on a Linux system is not as simple as it should be,
36a4daa9e3c7 [project @ 1996-12-19 02:27:21 by jwe]
jwe
parents: 2597
diff changeset
125 because libg++ shares some basic I/O code with the Linux C library,
36a4daa9e3c7 [project @ 1996-12-19 02:27:21 by jwe]
jwe
parents: 2597
diff changeset
126 and they must be compatible. You should get and read the release
36a4daa9e3c7 [project @ 1996-12-19 02:27:21 by jwe]
jwe
parents: 2597
diff changeset
127 notes for the compiler and libraries.
36a4daa9e3c7 [project @ 1996-12-19 02:27:21 by jwe]
jwe
parents: 2597
diff changeset
128
2601
3723512a827a [project @ 1997-01-06 05:43:16 by jwe]
jwe
parents: 2600
diff changeset
129 If you decide to install versions of the libraries that are older (or
3723512a827a [project @ 1997-01-06 05:43:16 by jwe]
jwe
parents: 2600
diff changeset
130 newer) than the ones you already have, you should follow the
3142
b06bffc95051 [project @ 1998-02-03 08:38:41 by jwe]
jwe
parents: 2993
diff changeset
131 directions in the release notes carefully.
2601
3723512a827a [project @ 1997-01-06 05:43:16 by jwe]
jwe
parents: 2600
diff changeset
132
2993
91589ab98e37 [project @ 1997-05-21 21:44:54 by jwe]
jwe
parents: 2663
diff changeset
133 I/O in dynamically loaded .oct files doesn't work
91589ab98e37 [project @ 1997-05-21 21:44:54 by jwe]
jwe
parents: 2663
diff changeset
134 -------------------------------------------------
91589ab98e37 [project @ 1997-05-21 21:44:54 by jwe]
jwe
parents: 2663
diff changeset
135
91589ab98e37 [project @ 1997-05-21 21:44:54 by jwe]
jwe
parents: 2663
diff changeset
136 If Octave prints things like `%.-1e' instead of numbers when you use a
91589ab98e37 [project @ 1997-05-21 21:44:54 by jwe]
jwe
parents: 2663
diff changeset
137 dynamically linked .oct file, you probably need to create shared
91589ab98e37 [project @ 1997-05-21 21:44:54 by jwe]
jwe
parents: 2663
diff changeset
138 versions of the Octave libraries. To do that, configure Octave with
3142
b06bffc95051 [project @ 1998-02-03 08:38:41 by jwe]
jwe
parents: 2993
diff changeset
139 --enable-shared, recompile, and reinstall.
2993
91589ab98e37 [project @ 1997-05-21 21:44:54 by jwe]
jwe
parents: 2663
diff changeset
140
2601
3723512a827a [project @ 1997-01-06 05:43:16 by jwe]
jwe
parents: 2600
diff changeset
141
2598
36a4daa9e3c7 [project @ 1996-12-19 02:27:21 by jwe]
jwe
parents: 2597
diff changeset
142 If you have comments or suggestions for this document, please contact
36a4daa9e3c7 [project @ 1996-12-19 02:27:21 by jwe]
jwe
parents: 2597
diff changeset
143 bug-octave@bevo.che.wisc.edu.
2593
3190d595d0da [project @ 1996-12-14 15:45:39 by jwe]
jwe
parents:
diff changeset
144
3190d595d0da [project @ 1996-12-14 15:45:39 by jwe]
jwe
parents:
diff changeset
145 John W. Eaton
3190d595d0da [project @ 1996-12-14 15:45:39 by jwe]
jwe
parents:
diff changeset
146 jwe@bevo.che.wisc.edu
3190d595d0da [project @ 1996-12-14 15:45:39 by jwe]
jwe
parents:
diff changeset
147 University of Wisconsin-Madison
3190d595d0da [project @ 1996-12-14 15:45:39 by jwe]
jwe
parents:
diff changeset
148 Department of Chemical Engineering
3190d595d0da [project @ 1996-12-14 15:45:39 by jwe]
jwe
parents:
diff changeset
149
3143
dbf073585f68 [project @ 1998-02-04 07:43:52 by jwe]
jwe
parents: 3142
diff changeset
150 Tue Feb 3 13:08:02 1998