]> sipb.mit.edu Git - ikiwiki.git/blob - doc/patchqueue/pm_filter-priority.mdwn
web commit by http://id.inelegant.org/
[ikiwiki.git] / doc / patchqueue / pm_filter-priority.mdwn
1 Thanks to [r2677](http://ikiwiki.info/cgi-bin/viewvc.cgi/trunk/pm_filter?revision=2677&root=ikiwiki&view=markup), we're closer to getting clean installs on shared hosts. 
2
3 The main problem is that `pm_filter` runs after `./ikiwiki.in`, so the build still fails. If it runs before, we're fine.
4
5 <pre>
6 Index: Makefile.PL
7 ===================================================================
8 --- Makefile.PL (revision 2682)
9 +++ Makefile.PL (working copy)
10 @@ -23,8 +23,10 @@
11         fi \\
12  )
13  
14 -extra_build:
15 -       LANG=C ./ikiwiki.in doc html --templatedir=templates \
16 +extra_build:
17 +       ./pm_filter $(PREFIX) $(VER) $(PROBABLE_INST_LIB) < ikiwiki.in > ikiwiki.out
18 +       chmod +x ikiwiki.out
19 +       LANG=C ./ikiwiki.out doc html --templatedir=templates \
20                 --underlaydir=basewiki \
21                 --wikiname="ikiwiki" --verbose --no-rcs \
22                 --exclude=/discussion --no-discussion --userdir=users \
23 @@ -32,7 +34,6 @@
24                 --plugin=haiku --plugin=polygen --plugin=fortune
25         ./mdwn2man ikiwiki 1 doc/usage.mdwn > ikiwiki.man
26         ./mdwn2man ikiwiki-mass-rebuild 8 doc/ikiwiki-mass-rebuild.mdwn > ikiwiki-mass-rebuild.man
27 -       ./pm_filter $(PREFIX) $(VER) $(PROBABLE_INST_LIB) < ikiwiki.in > ikiwiki.out
28         $(MAKE) -C po
29  
30  extra_clean:
31 </pre>
32
33 (Is there any reason to create `ikiwiki.out`? Couldn't we just do an in-place replace on `ikiwiki.in`?)
34
35 So, to install from the trunk I can say:
36
37     svn co svn://ikiwiki.kitenet.net/ikiwiki/trunk ikiwiki 
38     cd ikiwiki
39     patch -p0 <../patches/pm_filter_priority.patch #IOW, apply this patch
40     perl Makefile.PL PREFIX=~ LIB=~/lib
41     make
42     NOTAINT=1 make install
43     perl -p -i.bak -e 's{^(use IkiWiki;)}{use lib "$ENV{HOME}/lib";\n$1}' ~/bin/ikiwiki
44
45 The last line is necessary for the CGI, because, as with most shared hosts, the user's environment is ignored by the server . It's ugly, but ATM I can't think of a clean way to get rid of it.
46