Debian Codegraph @

doc/chap7.html

raw
1 <?xml version="1.0" encoding="UTF-8"?>
2
3 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
4 "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
5
6 <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
7 <head>
8 <title>GAP (ANUPQ) - Chapter 7: Installing the ANUPQ Package</title>
9 <meta http-equiv="content-type" content="text/html; charset=UTF-8" />
10 <meta name="generator" content="GAPDoc2HTML" />
11 <link rel="stylesheet" type="text/css" href="manual.css" />
12 <script src="manual.js" type="text/javascript"></script>
13 <script type="text/javascript">overwriteStyle();</script>
14 </head>
15 <body class="chap7" onload="jscontent()">
16
17
18 <div class="chlinktop"><span class="chlink1">Goto Chapter: </span><a href="chap0.html">Top</a> <a href="chap1.html">1</a> <a href="chap2.html">2</a> <a href="chap3.html">3</a> <a href="chap4.html">4</a> <a href="chap5.html">5</a> <a href="chap6.html">6</a> <a href="chap7.html">7</a> <a href="chapA.html">A</a> <a href="chapBib.html">Bib</a> <a href="chapInd.html">Ind</a> </div>
19
20 <div class="chlinkprevnexttop">&nbsp;<a href="chap0.html">[Top of Book]</a>&nbsp; <a href="chap0.html#contents">[Contents]</a>&nbsp; &nbsp;<a href="chap6.html">[Previous Chapter]</a>&nbsp; &nbsp;<a href="chapA.html">[Next Chapter]</a>&nbsp; </div>
21
22 <p id="mathjaxlink" class="pcenter"><a href="chap7_mj.html">[MathJax on]</a></p>
23 <p><a id="X7FB487238298CF42" name="X7FB487238298CF42"></a></p>
24 <div class="ChapSects"><a href="chap7.html#X7FB487238298CF42">7 <span class="Heading">Installing the ANUPQ Package</span></a>
25 <div class="ContSect"><span class="tocline"><span class="nocss">&nbsp;</span><a href="chap7.html#X854577C8800DC7C2">7.1 <span class="Heading">Testing your ANUPQ installation</span></a>
26 </span>
27 </div>
28 <div class="ContSect"><span class="tocline"><span class="nocss">&nbsp;</span><a href="chap7.html#X82906B5184C61063">7.2 <span class="Heading">Running the pq program as a standalone</span></a>
29 </span>
30 </div>
31 </div>
32
33 <h3>7 <span class="Heading">Installing the ANUPQ Package</span></h3>
34
35 <p>The ANU <code class="code">pq</code> program is written in C and the package can be installed under UNIX and in environments similar to UNIX. In particular it is known to work on Linux and Mac OS X, and also on Windows equipped with cygwin.</p>
36
37 <p>The current version of the <strong class="pkg">ANUPQ</strong> package requires <strong class="pkg">GAP</strong> 4.9, and version 1.2 of the <strong class="pkg">AutPGrp</strong> package. However, we recommend using at least <strong class="pkg">GAP</strong> 4.6 and <strong class="pkg">AutPGrp</strong> 1.5.</p>
38
39 <p>To install the <strong class="pkg">ANUPQ</strong> package, move the file <code class="code">anupq-<var class="Arg">XXX</var>.tar.gz</code> for some version number <var class="Arg">XXX</var> into the <code class="code">pkg</code> directory in which you plan to install <strong class="pkg">ANUPQ</strong>. Usually, this will be the directory <code class="code">pkg</code> in the hierarchy of your version of <strong class="pkg">GAP</strong>; it is however also possible to keep an additional <code class="code">pkg</code> directory in your private directories. The only essential difference with installing <strong class="pkg">ANUPQ</strong> in a <code class="code">pkg</code> directory different to the <strong class="pkg">GAP</strong> home directory is that one must start <strong class="pkg">GAP</strong> with the <code class="code">-l</code> switch (see Section <a href="../../../doc/ref/chap3.html#X782751D5858A6EAF"><span class="RefLink">Reference: Command Line Options</span></a>), e.g. if your private <code class="code">pkg</code> directory is a subdirectory of <code class="code">mygap</code> in your home directory you might type:</p>
40
41
42 <div class="example"><pre>
43 gap -l ";myhomedir/mygap"
44 </pre></div>
45
46 <p>where <var class="Arg">myhomedir</var> is the path to your home directory, which may be replaced by a tilde. The empty path before the semicolon is filled in by the default path of the <strong class="pkg">GAP</strong> home directory.</p>
47
48 <p>Then, in your chosen <code class="code">pkg</code> directory, unpack <code class="code">anupq-<var class="Arg">XXX</var>.tar.gz</code> by</p>
49
50
51 <div class="example"><pre>
52 tar xf anupq-&lt;XXX&gt;.tar.gz
53 </pre></div>
54
55 <p>Change to the newly created <code class="code">anupq</code> directory. Now you need to call <code class="code">configure</code>. If you installed <strong class="pkg">ANUPQ</strong> into the main <code class="code">pkg</code> directory, call</p>
56
57
58 <div class="example"><pre>
59 ./configure
60 </pre></div>
61
62 <p>If you installed ANUPQ in another directory than the usual 'pkg' subdirectory, instead call</p>
63
64
65 <div class="example"><pre>
66 ./configure --with-gaproot=&lt;path&gt;
67 </pre></div>
68
69 <p>where <var class="Arg">path</var> is the path to the <strong class="pkg">GAP</strong> home directory. (You can also call</p>
70
71
72 <div class="example"><pre>
73 ./configure --help
74 </pre></div>
75
76 <p>for further options.)</p>
77
78 <p>What this does is look for a file <code class="code">sysinfo.gap</code> in the root directory of <strong class="pkg">GAP</strong> in order to determine an architecture name for the subdirectory of <code class="code">bin</code> in which to put the compiled <code class="code">pq</code> binary. This only makes sense if <strong class="pkg">GAP</strong> was compiled for the same architecture that <code class="code">pq</code> will be. If you have a shared file system mounted across different architectures, then you should run <code class="code">configure</code> and <code class="code">make</code> for <strong class="pkg">ANUPQ</strong> for each architecture immediately after compiling <strong class="pkg">GAP</strong> on the same architecture.</p>
79
80 <p>If you had to install the package in your own directory but wish to use the system <strong class="pkg">GAP</strong> then you will need to find out what <var class="Arg">path</var> is. To do this, start up <strong class="pkg">GAP</strong> and find out what <strong class="pkg">GAP</strong>'s root path is from finding the value of the variable <code class="code">GAPInfo.RootPaths</code>, e.g.</p>
81
82
83 <div class="example"><pre>
84 <span class="GAPprompt">gap&gt;</span> <span class="GAPinput">GAPInfo.RootPaths;</span>
85 [ "/usr/local/lib/gap4r4/" ]
86 </pre></div>
87
88 <p>would tell you to use <code class="code">/usr/local/lib/gap4r4</code> for <var class="Arg">path</var>.</p>
89
90 <p>The <code class="code">configure</code> command will fetch the architecture type for which <strong class="pkg">GAP</strong> has been compiled last and create a <code class="code">Makefile</code>. You can now simply call</p>
91
92
93 <div class="example"><pre>
94 make
95 </pre></div>
96
97 <p>to compile the binary and to install it in the appropriate place.</p>
98
99 <p>The path of <strong class="pkg">GAP</strong> (see <em>Note</em> below) used by the <code class="code">pq</code> binary (the value <code class="code">GAP</code> is set to in the <code class="code">make</code> command) may be over-ridden by setting the environment variable <code class="code">ANUPQ_GAP_EXEC</code>. These values are only of interest when the <code class="code">pq</code> program is run as a standalone; however, the <code class="code">testPq</code> script assumes you have set one of these correctly (see Section <a href="chap7.html#X854577C8800DC7C2"><span class="RefLink"><span class="Heading">Testing your ANUPQ installation</span></span></a>). When the <code class="code">pq</code> program is started from <strong class="pkg">GAP</strong> communication occurs via an iostream, so that the <code class="code">pq</code> binary does not actually need to know a valid path for <strong class="pkg">GAP</strong> is this case.</p>
100
101 <p><em>Note.</em> By <q>path of <strong class="pkg">GAP</strong></q> we mean the path of the command used to invoke <strong class="pkg">GAP</strong> (which should be a script, e.g. the <code class="code">gap.sh</code> script generated in the <code class="code">bin</code> directory for the version of <strong class="pkg">GAP</strong> when <strong class="pkg">GAP</strong> was compiled). The usual strategy is to copy the <code class="code">gap.sh</code> script to a standard location, e.g. <code class="code">/usr/local/bin/gap</code>. It is a mistake to copy the <strong class="pkg">GAP</strong> executable <code class="code">gap</code> (in a directory with name of form <code class="code">bin/<var class="Arg">compile-platform</var></code>) to the standard location, since direct invocation of the executable results in <strong class="pkg">GAP</strong> starting without being able to find its own library (a fatal error).</p>
102
103 <p><a id="X854577C8800DC7C2" name="X854577C8800DC7C2"></a></p>
104
105 <h4>7.1 <span class="Heading">Testing your ANUPQ installation</span></h4>
106
107 <p>Now it is time to test the installation. After doing <code class="code">configure</code> and <code class="code">make</code> you will have a <code class="code">testPq</code> script. The script assumes that, if the environment variable <code class="code">ANUPQ_GAP_EXEC</code> is set, it is a correct path for <strong class="pkg">GAP</strong>, or otherwise that the <code class="code">make</code> call that compiled the <code class="code">pq</code> program set <code class="code">GAP</code> to a correct path for <strong class="pkg">GAP</strong> (see Section <a href="chap7.html#X82906B5184C61063"><span class="RefLink"><span class="Heading">Running the pq program as a standalone</span></span></a> for more details). To run the tests, just type:</p>
108
109
110 <div class="example"><pre>
111 ./testPq
112 </pre></div>
113
114 <p>Some of the tests the script runs take a while. Please be patient. The script checks that you not only have a correct <strong class="pkg">GAP</strong> (at least version 4.4) installation that includes the <strong class="pkg">AutPGrp</strong> package, but that the <strong class="pkg">ANUPQ</strong> package and its <code class="code">pq</code> binary interact correctly. You should see something like the following output:</p>
115
116
117 <div class="example"><pre>
118 Made dir: /tmp/testPq
119 Testing installation of ANUPQ Package (version 3.1)
120
121 The first two tests check that the pq C program compiled ok.
122 Testing the pq binary ... OK.
123 Testing the pq binary's stack size ... OK.
124 The pq C program compiled ok! We test it's the right one below.
125
126 The next tests check that you have the right version of GAP
127 for the ANUPQ package and that GAP is finding
128 the right versions of the ANUPQ and AutPGrp packages.
129
130 Checking GAP ...
131 pq binary made with GAP set to: /usr/local/bin/gap
132 Starting GAP to determine version and package availability ...
133 GAP version (4.6.5) ... OK.
134 GAP found ANUPQ package (version 3.1) ... good.
135 GAP found pq binary (version 1.9) ... good.
136 GAP found AutPGrp package (version 1.5) ... good.
137 GAP is OK.
138
139 Checking the link between the pq binary and GAP ... OK.
140 Testing the standard presentation part of the pq binary ... OK.
141 Doing p-group generation (final GAP/ANUPQ) test ... OK.
142 Tests complete.
143 Removed dir: /tmp/testPq
144 Enjoy using your functional ANUPQ package!
145 </pre></div>
146
147 <p><a id="X82906B5184C61063" name="X82906B5184C61063"></a></p>
148
149 <h4>7.2 <span class="Heading">Running the pq program as a standalone</span></h4>
150
151 <p>When the <code class="code">pq</code> program is run as a standalone it sometimes needs to call <strong class="pkg">GAP</strong> to compute stabilisers of subgroups; in doing so, it first checks the value of the environment variable <code class="code">ANUPQ_GAP_EXEC</code>, and uses that, if set, or otherwise the value of <code class="code">GAP</code> it was compiled with, as the path for <strong class="pkg">GAP</strong>. If you ran <code class="code">testPq</code> (see Section <a href="chap7.html#X854577C8800DC7C2"><span class="RefLink"><span class="Heading">Testing your ANUPQ installation</span></span></a>) and you got both <strong class="pkg">GAP</strong> is <code class="code">OK</code> and the link between the <code class="code">pq</code> binary and <strong class="pkg">GAP</strong> is <code class="code">OK</code>, you should be fine. Otherwise heed the recommendations of the error messages you get and run the <code class="code">testPq</code> until all tests are passed.</p>
152
153 <p>It is especially important that the <strong class="pkg">GAP</strong>, whose path you gave, should know where to find the <strong class="pkg">ANUPQ</strong> and <strong class="pkg">AutPGrp</strong> packages. To ensure this the path should be to a shell script that invokes <strong class="pkg">GAP</strong>. If you needed to install the needed packages in your own directory (because, say, you are not a system administrator) then you should create your own shell script that runs <strong class="pkg">GAP</strong> with a correct setting of the <code class="code">-l</code> option and set the path used by the <code class="code">pq</code> binary to the path of that script. To create the script that runs <strong class="pkg">GAP</strong> it is easiest to copy the system one and edit it, e.g. start by executing the following UNIX commands (skip the second step if you already have a <code class="code">bin</code> directory; <code class="code">you@unix&gt;</code> is your UNIX prompt):</p>
154
155
156 <div class="example"><pre>
157 you@unix&gt; cd
158 you@unix&gt; mkdir bin
159 you@unix&gt; cd bin
160 you@unix&gt; which gap
161 /usr/local/bin/gap
162 you@unix&gt; cp /usr/local/bin/gap mygap
163 you@unix&gt; chmod +x mygap
164 </pre></div>
165
166 <p>At the second-last step use the path of <strong class="pkg">GAP</strong> returned by <code class="code">which gap</code>. Now hopefully you will have a copy of the script that runs the system <strong class="pkg">GAP</strong> in <code class="code">mygap</code>. Now use your favourite editor to edit the <code class="code">-l</code> part of the last line of <code class="code">mygap</code> which should initially look something like:</p>
167
168
169 <div class="example"><pre>
170 exec $GAP_DIR/bin/$GAP_PRG -m $GAP_MEM -o 970m -l $GAP_DIR $*
171 </pre></div>
172
173 <p>so that it becomes (the tilde is a UNIX abbreviation for your home directory):</p>
174
175
176 <div class="example"><pre>
177 exec $GAP_DIR/bin/$GAP_PRG -m $GAP_MEM -o 970m -l "$GAP_DIR;~/gapstuff" $*
178 </pre></div>
179
180 <p>assuming that your personal <strong class="pkg">GAP</strong> <code class="code">pkg</code> directory is a subdirectory of <code class="code">gapstuff</code> in your home directory. Finally, to let the <code class="code">pq</code> program know where <strong class="pkg">GAP</strong> is and also know where your <code class="code">pkg</code> directory is that contains <strong class="pkg">ANUPQ</strong>, set the environment variable <code class="code">ANUPQ_GAP_EXEC</code> to the complete (i.e. absolute) path of your <code class="code">mygap</code> script (do not use the tilde abbreviation).</p>
181
182
183 <div class="chlinkprevnextbot">&nbsp;<a href="chap0.html">[Top of Book]</a>&nbsp; <a href="chap0.html#contents">[Contents]</a>&nbsp; &nbsp;<a href="chap6.html">[Previous Chapter]</a>&nbsp; &nbsp;<a href="chapA.html">[Next Chapter]</a>&nbsp; </div>
184
185
186 <div class="chlinkbot"><span class="chlink1">Goto Chapter: </span><a href="chap0.html">Top</a> <a href="chap1.html">1</a> <a href="chap2.html">2</a> <a href="chap3.html">3</a> <a href="chap4.html">4</a> <a href="chap5.html">5</a> <a href="chap6.html">6</a> <a href="chap7.html">7</a> <a href="chapA.html">A</a> <a href="chapBib.html">Bib</a> <a href="chapInd.html">Ind</a> </div>
187
188 <hr />
189 <p class="foot">generated by <a href="https://www.math.rwth-aachen.de/~Frank.Luebeck/GAPDoc">GAPDoc2HTML</a></p>
190 </body>
191 </html>