]> sipb.mit.edu Git - ikiwiki.git/blob - doc/install/discussion.mdwn
44152d80ba9620c530a8a0bf06b902f9a07c9e33
[ikiwiki.git] / doc / install / discussion.mdwn
1 No matter what I do, ikiwiki gives me a `Can't locate loadable object for module Locale::gettext in @INC` although I've installed (and reinstalled) the Locale module, and no luck. If I look at the directories in the INC path, I can see the file. The wiki won't compile in spite of this, and I've tried everything I can think of.. -- [[tychoish]]
2
3 > Sounds like the `Locale::gettext` perl module is there, but your perl
4 > installation is broken so that the accompnying so file is not there, or
5 > doesn't work. On my system I have 
6 > `/usr/lib/perl5/Locale/gettext.pm` and
7 > `/usr/lib/perl5/auto/Locale/gettext.so` -- suspect your problem is with
8 > the second one.
9
10 > If you can't fix it, this problem could probably be worked around by
11 > unsetting all environment variables when running ikiwiki (`LANG`,
12 > `LC_ALL`, `LC_MESSAGES`). Then it won't try to load `Locale::gettext` at
13 > all. --[[Joey]]
14
15 ---
16
17 I am trying to install Ikiwiki version 2.1 from the source tarball.
18
19 It has all gone fairly smoothly until I try and run 'make'.
20
21 I.e. I have downloaded and unpacked ikiwiki_2.1.tar.gz and have run
22
23     perl Makefile.PL
24
25 ... which has run OK.
26
27
28 However when I then run 'make' I get:-
29
30     LANG=C perl -I.  -T ikiwiki.out doc html --templatedir=templates \
31                     --underlaydir=basewiki --nousedirs\
32                     --wikiname="ikiwiki" --verbose \
33                     --exclude=/discussion --no-discussion --userdir=users \
34                     --plugin=goodstuff \
35                     --plugin=haiku --plugin=polygen --plugin=fortune
36     Failed to load plugin IkiWiki::Plugin::mdwn: IkiWiki version 2 required--this is only version 1.01 at IkiWiki/Plugin/mdwn.pm line 7.
37     BEGIN failed--compilation aborted at IkiWiki/Plugin/mdwn.pm line 7.
38     Compilation failed in require at (eval 4) line 2.
39     BEGIN failed--compilation aborted at (eval 4) line 2.
40
41     make: *** [extra_build] Error 1
42  
43 How do I fix this?  There may be a bit of old ikiwiki left behind because
44 I did once have an older version installed but I thought I had removed all
45 traces of it.
46
47 > I'm quite sure that you still have some of it floating around, since
48 > ikiwiki seems to be loading an old IkiWiki.pm.
49
50 > I don't understand though why it's not finding ./IkiWiki.pm first. The
51 > `-I` in the command line should make it look for files in the current
52 > directory first. --[[Joey]]
53
54 Well I have searched around and there really is nothing left that I can see.
55
56 I have removed *everything* found by 'find' and 'locate' that contains 'ikiwiki' except the tar file
57 and started from the beginning again and I see exactly the same error.
58
59 Is it that I maybe have a too old version of some of the Perl dependencies?  The only mdwn.pm files
60 that I have are the two I have just extracted from the new tar file.  There is *no* ./IkiWiki.pm file
61
62 > It's interesting that you say you have no ./IkiWiki.pm file, since one is
63 > included in the tarball. What happened to it, I wonder? 
64
65 so what/where is it loading to satisfy the ....... aaaaaaaaaaahhhhhhhhhhhhhh!!!!!!
66
67 I wasn't noticing the case of the filename, I'd missed the upper case W and guess what 'find' shows me:-
68
69     /usr/local/lib/perl5/site_perl/5.8.8/IkiWiki.pm
70
71 Removing the above file has fixed my basic problem, now I'm getting lots of (non-fatal) errors
72 about "Can't locate Locale/gettext.pm", presumably that's a missing Perl module, I can probably
73 sort that out.
74
75
76 ## Errors when running 'make test'
77
78 OK, I've now got it to compile and install and presumably it's basically working.  However there
79 are a few errors when I run 'make test'.  Several errors have disappeared by installing more Perl
80 stuff (specifically XML::SAX) 
81
82 > XML::SAX is a requirement of XML::Simple, which is a documented build
83 > requirement. (Only really needed if you'll be using subversion actually).
84
85 and one error disappeared when I did a 'make install', i.e. the 'make
86 test' has a test which requires IkiWiki to be installed first.
87
88 > Yes, that bug is already fixed in subversion for the next release
89 > --[[Joey]]
90
91 However I'm still getting the following error in 'make test':-
92
93         t/pagename.................ok                                                
94         t/pagespec_match...........ok 1/52Modification of a read-only value attempted at /home/chris/webdev/ikiwiki/blib/lib/IkiWiki.pm line 1023.
95         # Looks like you planned 52 tests but only ran 23.
96         # Looks like your test died just after 23.
97         t/pagespec_match...........dubious                                           
98                 Test returned status 255 (wstat 65280, 0xff00)
99         DIED. FAILED tests 24-52
100                 Failed 29/52 tests, 44.23% okay
101         t/pagespec_merge...........ok                                                
102
103 > What version of perl are you using? It seems to have some problem with
104 > operator overloading.
105 > --[[Joey]]
106
107 home$ perl -v
108
109 This is perl, v5.8.8 built for i486-linux
110
111 ## Installation in a non-root enviroment
112 I had a pretty hellacious time installing Ikiwiki (largely due to problems
113 in Perl) and documented them in [[tips/Dreamhost]].  I'd like to get feedback on the doc and also know if I should file a few bugs to make the installation process a little friendlier to non-root folks.  Thanks for the great app!
114
115
116 ## Typing error?
117
118 [..] Mail::Sendmail, TimeDate, RPC::XML, [..]: should be DateTime? --[[vibrog]]
119
120 > No, TimeDate and DateTime are two different CPAN modules. Ikiwiki uses
121 > TimeDate. --[[Joey]]
122
123 ah, i still don't fully get it, though (the following is slightly shortened):
124
125     $ perl -MCPAN -e shell
126     cpan> install DateTime
127     DateTime is up to date.
128     cpan> install TimeDate
129     Warning: Cannot install TimeDate, don't know what it is.
130     Try the command
131         i /TimeDate/
132     to find objects with matching identifiers.
133
134 I'm trying to build IkiWiki on a fresh OpenSuse 10.3 box. I start out with
135
136     $ perl -MCPAN -e 'install Text::Markdown URI HTML::Parser HTML::Template HTML::Scrubber'
137     $ git clone git://git.ikiwiki.info/ ikiwiki && cd ikiwiki
138     $ perl Makefile.PL && make
139
140 Are there other prerequisites?
141 I also installed all optional Perl modules, except TimeDate.
142
143 > TimeDate is also, confusingly, known as Date::Parse. Perhaps CPAN would
144 > do better with that name. --[[Joey]]
145
146 good. Date::Parse was already installed. --[[vibrog]]
147
148 `make` exits with `make: *** [extra_build] Aborted`, `make test` complains `cannot stat 'ikiwiki.man'` --[[vibrog]]
149
150 > If you show me the actual error message, and not just the last line make
151 > outputs, I might be able to help. --[[Joey]]
152
153     ..
154     rendering todo/calendar_--_archive_browsing_via_a_calendar_frontend.mdwn
155     make: *** [extra_build] Segmentation fault
156
157 > So, perl on your system is segfaulting when running ikiwiki. What version
158 > of perl is this, and what version of what distribution? --[[Joey]]
159
160     $ perl -V
161     Summary of my perl5 (revision 5 version 8 subversion 8) configuration:
162     osname=linux, osvers=2.6.22, archname=i586-linux-thread-multi
163     uname='linux ravel 2.6.22 #1 smp 20070921 22:29:00 utc i686 i686 i386 gnulinux '
164     config_args='-ds -e -Dprefix=/usr -Dvendorprefix=/usr -Dinstallusrbinperl -Dusethreads -Di_db -Di_dbm -Di_ndbm -Di_gdbm -Duseshrplib=true -Doptimize=-O2 -march=i586 -mtune=i686 -fmessage-length=0 -Wall -D_FORTIFY_SOURCE=2 -fstack-protector -g -Wall -pipe'
165     hint=recommended, useposix=true, d_sigaction=define
166     usethreads=define use5005threads=undef useithreads=define usemultiplicity=define
167     useperlio=define d_sfio=undef uselargefiles=define usesocks=undef
168     use64bitint=undef use64bitall=undef uselongdouble=undef
169     usemymalloc=n, bincompat5005=undef
170
171 Not sure how to provide proper version information for you.--[[vibrog]]
172
173 ---
174
175 I've tried a couple of times and my cpan has never recognised Bundle::IkiWiki. Is that section of the page still accurate? -- [[users/Jon]]
176
177 > Are you running perl with the environemnt settings specified on the page?
178 > Can you show how it fails to find the bundle? --[[Joey]]
179
180 >> I was not. Next time I build I will have to try that (I'll need to tweak it as I already override PERL5LIB; also I need to specify http proxies). Thanks for your help! -- [[users/Jon]]
181
182 ---
183
184 ##Further problems with Bundle::IkiWiki
185 I'm also having trouble with finding Bundle::IkiWiki.  I've tried it with the environment settings and without them, and also using the interactive 
186 form of the cpan command.  I've also gone to cpan.org and searched -- eg
187
188     http://search.cpan.org/search?query=ikiwiki&mode=all
189
190 and no Bundle for IkiWiki comes up at all.
191
192 The error I get from the various cpan attempts is basically always the same:
193
194     Warning: Cannot install Bundle::IkiWiki, don't know what it is.
195     Try the command
196
197         i /Bundle::IkiWiki/
198
199     to find objects with matching identifiers.
200
201 When I try that command, BTW, it basically seems to find the same stuff I get when searching on the cpan web site.
202
203 This happens both on Ubuntu 8.04 and CentOS 5.1
204
205 Any help would be greatly appreciated... --kent
206
207 > Bundle::IkiWiki is included in ikiwiki itself, so of course cpan.org
208 > does not know about it.
209
210 > If you can show me exactly what command you ran (the tested, working
211 > commands on the parent page?) and how it failed, I can try to debug
212 > your problem.
213
214 Just today I noticed the "Bundle" subdirectory.  What a moron I am! :-)  Also, I misunderstood the PERL5LIB=`pwd` part -- 
215 I glibly thought it indicated the sink for the installation of the modules, rather than the source, and I was running 
216 the cpan command from another window in a different directory, and just spiraled down into error...
217
218 > The real question in my mind is why you'd want to do this at all when
219 > using Ubuntu, which incldues packages of ikiwiki and all its
220 > dependencies. --[[Joey]]
221
222 For ubuntu 8.04: 
223
224     $ ikiwiki --version
225     ikiwiki version 2.32.3ubuntu2.1
226     $
227
228 I was just trying to get the latest version.
229
230 In any case, thanks for the help, and thanks for the superb software.  I really like it a lot.
231
232 ---
233
234 ## Prerequisite modules not found for non-root user
235 Hi, I'm a non-root user trying to use IkiWiki on an academic webserver with Perl 5.8.8 but several missing modules, so I grab them from CPAN (edited):
236
237     cd ~; PERL5LIB=`pwd`/ikiwiki:`pwd`/ikiwiki/cpan:`pwd`/lib/perl5 PERL_MM_USE_DEFAULT=1 perl -MCPAN -e 'CPAN::Shell->install("Bundle::IkiWiki")'
238
239 That puts a lot of files in ~/.cpan. Then when I go into the directory where I untarred IkiWiki and try to run the Perl makefile:
240
241     cd ~/ikiwiki; perl Makefile.PL PREFIX=$HOME/ikiwiki
242
243 I get warnings that all the modules needed were not found:
244
245 Warning: prerequisite CGI::FormBuilder  not found.
246 Warning: prerequisite CGI::Session 0 not found.
247 Warning: prerequisite Date::Parse 0 not found.
248 Warning: prerequisite HTML::Scrubber 0 not found.
249 Warning: prerequisite HTML::Template 0 not found.
250 Warning: prerequisite Mail::Sendmail 0 not found.
251 Warning: prerequisite Text::Markdown 0 not found.
252
253 CORRECTION 1: I played around with CPAN and got the installation to the point of succeeding with >99% of tests in "make test".
254
255 > What was the magic CPAN rune that worked for you? --[[Joey]] 
256
257 An attempt of "make install" failed while trying to put files in /etc/IkiWiki but per the output's instructions, I reran "make install" and that seemed to work, until this error, which doesn't seem to be satisfiable:
258
259     Warning: You do not have permissions to install into /usr/lib/perl5/site_perl/5.8.8/i386-linux-thread-multi at /usr/lib/perl5/5.8.8/ExtUtils/Install.pm line 114.
260     Installing /usr/lib/perl5/site_perl/5.8.8/IkiWiki.pm
261     mkdir /usr/lib/perl5/site_perl/5.8.8/IkiWiki: Permission denied at /usr/lib/perl5/5.8.8/ExtUtils/Install.pm line 176
262
263 Any suggestions? Whew!
264
265 > When you build ikiwiki, try doing it like this to make it
266 > install to your home directory. Then you can run `~/bin/ikiwiki`
267 > --[[Joey]] 
268
269         perl Makefile.PL INSTALL_BASE=$HOME PREFIX=
270         make
271         make install
272
273 ---
274
275 03 September 2010, Report on successful manual install in Debian 5 (Lenny) AMD64:
276
277 note: Maybe much more easy using backports, but using this tools you get a plain user cpan  :)
278
279 This where my steps:
280
281 As root (#):
282
283     # aptitude install build-essential curl libexpat1-dev
284
285 As plain user ($):
286
287     I use to install user perl modules using local::lib:
288
289         http://github.com/poisonbit/sandbox/blob/master/bin/myperl.sh
290
291     After that and relogin, you can install cpanm  :)
292
293         mkdir -p "$HOME/downloads"
294         cd "$HOME/downloads/"
295         curl -L http://cpanmin.us | perl - App::cpanminus
296         source "/home/$USER/.bashrc"
297         wget http://ftp.de.debian.org/debian/pool/main/i/ikiwiki/ikiwiki_3.20100831.tar.gz
298         cpanm Text::Markdown
299         cpanm URI
300         cpanm HTML::Parser
301         cpanm HTML::Template
302         cpanm HTML::Scrubber
303         cpanm CGI::FormBuilder
304         cpanm CGI::Session
305         tar -zxf ikiwiki_3.20100831.tar.gz
306         cd ikiwiki/
307         perl Makefile.PL PREFIX=/home/$USER/.perl5 INSTALL_BASE=
308         make
309         make install
310         make install INSTALL_BASE=/home/$USER/.perl5
311
312 Using cpan or cpanm with local::lib, you can install any other needed dependency, as plain user in your home (XS modules may need -dev packages)
313
314 After all, here it's:
315
316         ikiwiki --version
317         ikiwiki version 3.20100831
318
319 Hope this could be useful for someone some day.
320 IƱigo