Debian Codegraph @

doc/chap7_mj.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 <script type="text/javascript"
9 src="https://cdn.jsdelivr.net/npm/mathjax@2/MathJax.js?config=TeX-AMS-MML_HTMLorMML">
10 </script>
11 <title>GAP (ANUPQ) - Chapter 7: Installing the ANUPQ Package</title>
12 <meta http-equiv="content-type" content="text/html; charset=UTF-8" />
13 <meta name="generator" content="GAPDoc2HTML" />
14 <link rel="stylesheet" type="text/css" href="manual.css" />
15 <script src="manual.js" type="text/javascript"></script>
16 <script type="text/javascript">overwriteStyle();</script>
17 </head>
18 <body class="chap7" onload="jscontent()">
19
20
21 <div class="chlinktop"><span class="chlink1">Goto Chapter: </span><a href="chap0_mj.html">Top</a> <a href="chap1_mj.html">1</a> <a href="chap2_mj.html">2</a> <a href="chap3_mj.html">3</a> <a href="chap4_mj.html">4</a> <a href="chap5_mj.html">5</a> <a href="chap6_mj.html">6</a> <a href="chap7_mj.html">7</a> <a href="chapA_mj.html">A</a> <a href="chapBib_mj.html">Bib</a> <a href="chapInd_mj.html">Ind</a> </div>
22
23 <div class="chlinkprevnexttop">&nbsp;<a href="chap0_mj.html">[Top of Book]</a>&nbsp; <a href="chap0_mj.html#contents">[Contents]</a>&nbsp; &nbsp;<a href="chap6_mj.html">[Previous Chapter]</a>&nbsp; &nbsp;<a href="chapA_mj.html">[Next Chapter]</a>&nbsp; </div>
24
25 <p id="mathjaxlink" class="pcenter"><a href="chap7.html">[MathJax off]</a></p>
26 <p><a id="X7FB487238298CF42" name="X7FB487238298CF42"></a></p>
27 <div class="ChapSects"><a href="chap7_mj.html#X7FB487238298CF42">7 <span class="Heading">Installing the ANUPQ Package</span></a>
28 <div class="ContSect"><span class="tocline"><span class="nocss">&nbsp;</span><a href="chap7_mj.html#X854577C8800DC7C2">7.1 <span class="Heading">Testing your ANUPQ installation</span></a>
29 </span>
30 </div>
31 <div class="ContSect"><span class="tocline"><span class="nocss">&nbsp;</span><a href="chap7_mj.html#X82906B5184C61063">7.2 <span class="Heading">Running the pq program as a standalone</span></a>
32 </span>
33 </div>
34 </div>
35
36 <h3>7 <span class="Heading">Installing the ANUPQ Package</span></h3>
37
38 <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>
39
40 <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>
41
42 <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_mj.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>
43
44
45 <div class="example"><pre>
46 gap -l ";myhomedir/mygap"
47 </pre></div>
48
49 <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>
50
51 <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>
52
53
54 <div class="example"><pre>
55 tar xf anupq-&lt;XXX&gt;.tar.gz
56 </pre></div>
57
58 <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>
59
60
61 <div class="example"><pre>
62 ./configure
63 </pre></div>
64
65 <p>If you installed ANUPQ in another directory than the usual 'pkg' subdirectory, instead call</p>
66
67
68 <div class="example"><pre>
69 ./configure --with-gaproot=&lt;path&gt;
70 </pre></div>
71
72 <p>where <var class="Arg">path</var> is the path to the <strong class="pkg">GAP</strong> home directory. (You can also call</p>
73
74
75 <div class="example"><pre>
76 ./configure --help
77 </pre></div>
78
79 <p>for further options.)</p>
80
81 <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>
82
83 <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>
84
85
86 <div class="example"><pre>
87 <span class="GAPprompt">gap&gt;</span> <span class="GAPinput">GAPInfo.RootPaths;</span>
88 [ "/usr/local/lib/gap4r4/" ]
89 </pre></div>
90
91 <p>would tell you to use <code class="code">/usr/local/lib/gap4r4</code> for <var class="Arg">path</var>.</p>
92
93 <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>
94
95
96 <div class="example"><pre>
97 make
98 </pre></div>
99
100 <p>to compile the binary and to install it in the appropriate place.</p>
101
102 <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_mj.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>
103
104 <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>
105
106 <p><a id="X854577C8800DC7C2" name="X854577C8800DC7C2"></a></p>
107
108 <h4>7.1 <span class="Heading">Testing your ANUPQ installation</span></h4>
109
110 <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_mj.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>
111
112
113 <div class="example"><pre>
114 ./testPq
115 </pre></div>
116
117 <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>
118
119
120 <div class="example"><pre>
121 Made dir: /tmp/testPq
122 Testing installation of ANUPQ Package (version 3.1)
123
124 The first two tests check that the pq C program compiled ok.
125 Testing the pq binary ... OK.
126 Testing the pq binary's stack size ... OK.
127 The pq C program compiled ok! We test it's the right one below.
128
129 The next tests check that you have the right version of GAP
130 for the ANUPQ package and that GAP is finding
131 the right versions of the ANUPQ and AutPGrp packages.
132
133 Checking GAP ...
134 pq binary made with GAP set to: /usr/local/bin/gap
135 Starting GAP to determine version and package availability ...
136 GAP version (4.6.5) ... OK.
137 GAP found ANUPQ package (version 3.1) ... good.
138 GAP found pq binary (version 1.9) ... good.
139 GAP found AutPGrp package (version 1.5) ... good.
140 GAP is OK.
141
142 Checking the link between the pq binary and GAP ... OK.
143 Testing the standard presentation part of the pq binary ... OK.
144 Doing p-group generation (final GAP/ANUPQ) test ... OK.
145 Tests complete.
146 Removed dir: /tmp/testPq
147 Enjoy using your functional ANUPQ package!
148 </pre></div>
149
150 <p><a id="X82906B5184C61063" name="X82906B5184C61063"></a></p>
151
152 <h4>7.2 <span class="Heading">Running the pq program as a standalone</span></h4>
153
154 <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_mj.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>
155
156 <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>
157
158
159 <div class="example"><pre>
160 you@unix&gt; cd
161 you@unix&gt; mkdir bin
162 you@unix&gt; cd bin
163 you@unix&gt; which gap
164 /usr/local/bin/gap
165 you@unix&gt; cp /usr/local/bin/gap mygap
166 you@unix&gt; chmod +x mygap
167 </pre></div>
168
169 <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>
170
171
172 <div class="example"><pre>
173 exec $GAP_DIR/bin/$GAP_PRG -m $GAP_MEM -o 970m -l $GAP_DIR $*
174 </pre></div>
175
176 <p>so that it becomes (the tilde is a UNIX abbreviation for your home directory):</p>
177
178
179 <div class="example"><pre>
180 exec $GAP_DIR/bin/$GAP_PRG -m $GAP_MEM -o 970m -l "$GAP_DIR;~/gapstuff" $*
181 </pre></div>
182
183 <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>
184
185
186 <div class="chlinkprevnextbot">&nbsp;<a href="chap0_mj.html">[Top of Book]</a>&nbsp; <a href="chap0_mj.html#contents">[Contents]</a>&nbsp; &nbsp;<a href="chap6_mj.html">[Previous Chapter]</a>&nbsp; &nbsp;<a href="chapA_mj.html">[Next Chapter]</a>&nbsp; </div>
187
188
189 <div class="chlinkbot"><span class="chlink1">Goto Chapter: </span><a href="chap0_mj.html">Top</a> <a href="chap1_mj.html">1</a> <a href="chap2_mj.html">2</a> <a href="chap3_mj.html">3</a> <a href="chap4_mj.html">4</a> <a href="chap5_mj.html">5</a> <a href="chap6_mj.html">6</a> <a href="chap7_mj.html">7</a> <a href="chapA_mj.html">A</a> <a href="chapBib_mj.html">Bib</a> <a href="chapInd_mj.html">Ind</a> </div>
190
191 <hr />
192 <p class="foot">generated by <a href="https://www.math.rwth-aachen.de/~Frank.Luebeck/GAPDoc">GAPDoc2HTML</a></p>
193 </body>
194 </html>