2011-06-24 23:35:14 +02:00
[[!toc]]
2013-09-14 23:15:24 +02:00
# pkgsrc
The easiest way of installing an up-to-date ikiwiki on any version of Mac OS X is via
[pkgsrc](http://www.pkgsrc.org/).
2014-03-20 00:03:19 +01:00
## From source:
2013-09-14 23:15:24 +02:00
7. [Bootstrap pkgsrc](http://www.netbsd.org/docs/pkgsrc/platforms.html#bootstrapping-pkgsrc)
7. Run `cd .../pkgsrc/www/ikiwiki && make install clean`
2014-03-20 00:03:19 +01:00
## From binary packages:
7. [install binary packages (OSX)](http://www.pkgsrc.org/#index1h1)
2014-03-20 00:00:27 +01:00
{OK} As of 2014/03/19, the [version of ikiwiki in pkgsrc](http://pkgsrc.se/www/ikiwiki) is 3.20140227.
2013-09-14 23:15:24 +02:00
-----
2011-06-24 23:35:14 +02:00
# MacPorts
2013-09-14 23:15:24 +02:00
Another way to install ikiwiki on Mac OS X [Snow] Leopard and Tiger is via MacPorts: <http://www.macports.org/>
2011-06-24 23:35:14 +02:00
2013-09-14 23:05:19 +02:00
This project ports Open Source software into Mac OS X platform.
It's very easy to install ikiwiki via MacPorts:
2011-06-24 23:35:14 +02:00
1.- Donwnload and install MacPorts port manager from: <http://www.macports.org/install.php> .
2013-09-14 23:05:19 +02:00
Port manager installs via Mac OS X installer. Prerequisite: XCode.
2011-06-24 23:35:14 +02:00
Se above URL for details
2.- Run
$ sudo port install ikiwiki
This installs ikiwiki and all of its dependencies
enjoy
Enrique Castilla
2014-03-20 00:00:27 +01:00
[!] As of 2014/03/19, the [version of ikiwiki in MacPorts](http://www.macports.org/ports.php?by=name&substr=Ikiwiki) is 3.20110608.
2013-09-14 23:05:19 +02:00
2011-06-24 23:35:14 +02:00
-----
# Manual install
2010-10-12 07:53:32 +02:00
These are some notes on installing ikiwiki on Mac OS X Snow Leopard. I have a three year old machine with a lot of stuff on it so it took quite a while, YMMV.
The best part of installing ikiwiki was learning how to use git. I never used source control before but its pretty slick.
2010-10-12 07:55:32 +02:00
2010-10-12 07:53:32 +02:00
## installing git:
2010-10-14 22:24:43 +02:00
cd /opt/ikiwiki/install
2010-10-12 07:53:32 +02:00
curl http://kernel.org/pub/software/scm/git/git-(latest version).tar.gz -O
2010-10-12 07:55:32 +02:00
2010-10-12 07:53:32 +02:00
tar xzvf git-(latest version).tar.gz
2010-10-12 07:55:32 +02:00
2010-10-12 07:53:32 +02:00
cd git-(latest version)
2010-10-12 07:55:32 +02:00
2010-10-14 22:24:43 +02:00
./configure --prefix=/usr/local
2010-10-12 07:55:32 +02:00
2010-10-14 22:24:43 +02:00
make prefix=/usr/local all
2010-10-12 07:55:32 +02:00
2010-10-12 07:53:32 +02:00
sudo make install
2010-10-12 07:55:32 +02:00
2010-10-12 07:53:32 +02:00
git config --global user.name "firstname lastname"
2010-10-12 07:55:32 +02:00
2010-10-12 07:53:32 +02:00
git config --global user.email "email here"
2010-10-12 07:55:32 +02:00
2010-10-12 07:53:32 +02:00
git config --global color.ui "auto"
2010-10-12 07:55:32 +02:00
2010-10-14 22:24:43 +02:00
curl http://www.kernel.org/pub/software/scm/git/git-manpages-1.7.3.1.tar.gz | sudo tar -xzC /usr/local/share/man/
2010-10-12 07:53:32 +02:00
## installing ikiwiki:
I had terrible trouble installing ikiwiki. It turned out I had accidentally installed Perl through ports. Uninstalling that made everything install nicely.
2010-10-14 22:24:43 +02:00
I got an error on msgfmt. Turns out this is a program in gettext. I installed that and it fixed the error.
2010-10-12 07:55:32 +02:00
2010-10-18 17:05:02 +02:00
cd ..
2010-10-14 22:24:43 +02:00
git clone git://git.ikiwiki.info/
2010-10-12 07:55:32 +02:00
2010-10-18 17:05:02 +02:00
cd git.ikiwiki.info/
2010-10-12 07:53:32 +02:00
perl Makefile.PL LIB=/Library/Perl/5.10.0
2010-10-12 07:55:32 +02:00
2010-10-12 07:53:32 +02:00
make
2010-10-12 07:55:32 +02:00
2010-10-14 22:24:43 +02:00
sudo make install
2010-10-12 07:55:32 +02:00
2010-10-12 07:53:32 +02:00
when you make ikiwiki it gives you a .git folder with the ikiwiki files. Stay out of this folder. You want to learn how to create a clone and make all your changes in the clone. When you push the changes ikiwiki will update. I moved a file in this folder by accident because I named my working file the same and I couldn't get into the setup page. I had apparently messed up my ikiwiki git repository. I did a pull into my clone, deleted the repository and webserver/ cgi folders and ran a new setup. Then I did a git clone and dragged all my old files into the new clone. Did the git dance and did git push. Then the angels sang.
2010-10-12 07:55:32 +02:00
2010-10-12 07:53:32 +02:00
## using git from inside a git folder:
2010-10-12 07:55:32 +02:00
2010-10-12 07:53:32 +02:00
start with git clone, then learn to do the git dance like this.
2010-10-12 07:55:32 +02:00
2010-10-12 07:53:32 +02:00
git pull
2010-10-12 07:55:32 +02:00
2010-10-12 07:53:32 +02:00
make your changes to your clone
2010-10-12 07:55:32 +02:00
2010-10-12 07:53:32 +02:00
git commit -a -m "message here"
2010-10-12 07:55:32 +02:00
2010-10-12 07:53:32 +02:00
git push
2010-10-12 07:55:32 +02:00
2010-10-12 07:53:32 +02:00
When you can't get into the setup page or you get strange behavior after a setup update the Utilities > Console app is your friend.
## installing gitweb
2010-10-18 17:38:16 +02:00
cd ../git-1.7.3.1/gitweb
2010-10-12 07:53:32 +02:00
2011-02-25 03:02:43 +01:00
make GITWEB_PROJECTROOT="/opt/ikiwiki/" GITWEB_CSS="/gitweb.css" GITWEB_LOGO="/git-logo.png" GITWEB_FAVICON="/git-favicon.png" GITWEB_JS="/gitweb.js"
2010-10-12 07:55:32 +02:00
2010-10-14 22:24:43 +02:00
cp gitweb.cgi /Library/WebServer/CGI-Executables/
2010-10-14 23:23:08 +02:00
cp /usr/local/share/gitweb/static/git-favicon.png /Library/WebServer/Documents/
cp /usr/local/share/gitweb/static/git-logo.png /Library/WebServer/Documents/
cp /usr/local/share/gitweb/static/gitweb.css /Library/WebServer/Documents/
cp /usr/local/share/gitweb/static/gitweb.js /Library/WebServer/Documents/
2010-10-12 07:53:32 +02:00
2010-10-14 22:24:43 +02:00
sudo chmod 2755 /Library/WebServer/CGI-Executables/gitweb.cgi
2010-10-14 23:23:08 +02:00
sudo chmod 2755 /Library/WebServer/Documents/git-favicon.png
sudo chmod 2755 /Library/WebServer/Documents/git-logo.png
sudo chmod 2755 /Library/WebServer/Documents/gitweb.css
sudo chmod 2755 /Library/WebServer/Documents/gitweb.js
2010-10-12 07:55:32 +02:00
2010-10-12 07:53:32 +02:00
## installing xapian:
2010-10-12 07:55:32 +02:00
2010-10-12 07:53:32 +02:00
download xapian and omega
2010-10-12 07:55:32 +02:00
2010-10-12 07:53:32 +02:00
I needed pcre: sudo ports install pcre
./configure
2010-10-12 07:55:32 +02:00
2010-10-12 07:53:32 +02:00
make
2010-10-12 07:55:32 +02:00
2010-10-12 07:53:32 +02:00
sudo make install
2010-10-12 07:55:32 +02:00
2010-10-12 07:53:32 +02:00
## installing omega:
2010-10-12 07:55:32 +02:00
2010-10-12 07:53:32 +02:00
I had a build error do to libiconv undefined symbols. sudo port deactivate libiconv took care of it. After install I had trouble with ikiwiki so I did a sudo port install libiconv and ikiwiki came back.
2010-10-12 07:55:32 +02:00
2010-10-12 07:53:32 +02:00
./configure
2010-10-12 07:55:32 +02:00
2010-10-12 07:53:32 +02:00
make
2010-10-12 07:55:32 +02:00
2010-10-12 07:53:32 +02:00
sudo make install
2010-10-12 07:55:32 +02:00
2010-10-12 07:53:32 +02:00
## installing Search::Xapian from CPAN
2010-10-12 07:55:32 +02:00
2010-10-12 07:53:32 +02:00
for some reason this wouldn't install using CPAN console so I went to CPAN online and downloaded the source.
2010-10-12 07:55:32 +02:00
2010-10-12 07:53:32 +02:00
perl Makefile.PL
2010-10-12 07:55:32 +02:00
2010-10-12 07:53:32 +02:00
make
2010-10-12 07:55:32 +02:00
2010-10-12 07:53:32 +02:00
make test
2010-10-12 07:55:32 +02:00
2010-10-12 07:53:32 +02:00
sudo make install
2010-10-12 07:55:32 +02:00
2010-10-12 07:53:32 +02:00
it installed without issue so I'm baffled why it didn't install from command line.
2010-10-14 23:19:19 +02:00
## setup file
_!/usr/bin/perl
_ Ikiwiki setup automator.
_ This setup file causes ikiwiki to create a wiki, check it into revision
_ control, generate a setup file for the new wiki, and set everything up.
_ Just run: ikiwiki -setup /etc/ikiwiki/auto.setup
_By default, it asks a few questions, and confines itself to the user's home
_directory. You can edit it to change what it asks questions about, or to
_modify the values to use site-specific settings.
require IkiWiki::Setup::Automator;
our $wikiname="your wiki";
our $wikiname_short="yourwiki";
our $rcs="git";
our $admin="your name";
use Net::Domain q{hostfqdn};
our $domain="your.domain";
IkiWiki::Setup::Automator->import(
wikiname => $wikiname,
adminuser => [$admin],
rcs => $rcs,
srcdir => "/opt/ikiwiki/$wikiname_short",
destdir => "/Library/WebServer/Documents/$wikiname_short",
repository => "/opt/ikiwiki/$wikiname_short.".($rcs eq "monotone" ? "mtn" : $rcs),
dumpsetup => "/opt/ikiwiki/$wikiname_short.setup",
url => "http://$domain/$wikiname_short",
cgiurl => "http://$domain/cgi-bin/$wikiname_short/ikiwiki.cgi",
cgi_wrapper => "/Library/WebServer/CGI-Executables/$wikiname_short/ikiwiki.cgi",
adminemail => "your\@email.com",
add_plugins => [qw{goodstuff websetup}],
disable_plugins => [qw{}],
libdir => "/opt/ikiwiki/.ikiwiki",
rss => 1,
atom => 1,
syslog => 1,
)
2010-10-14 22:42:23 +02:00
2010-10-12 07:53:32 +02:00
## turning on search plugin:
2010-10-12 07:55:32 +02:00
2010-10-14 23:45:48 +02:00
I turned on the plugin from the setup page in ikiwiki but it gave an error when I went to search. Error "Error: /usr/lib/cgi-bin/omega/omega failed: No such file or directory".
I did a "find / -name "omega" -print" and found the omega program in "/usr/local/lib/xapian-omega/bin/omega".
2010-10-12 07:55:32 +02:00
2010-10-14 23:45:48 +02:00
Then I went into the 2wiki.setup file and replaced the bad path, updated and badda-boom badda-bing.