|
InstallationHowto
Installation Hints
PrerequisitesDo NOT attempt to build from a checkout from the source code repository: that is for wizards only. Instead, grab one of the released source tarballs from the downloads tab.
InstallingThe project uses automake[1]. The default prefix is /usr; if you don't like that, use the --prefix option to configure. % ./configure && make && make check Running make check is strongly suggested. The project is distributed as a set of patches. At build time it tries to find your current version of mnesia and patch it. If this is successful, then it will end up creating a version of mnesia with a version equal to the version you have installed plus ".N" where N is the version of the extensions. For instance, right now, version 6 of the extensions has been released, so on a system running mnesia-4.3.5, a successful build and install will install as mnesia-4.3.5.6. Tested Platforms
Footnotes1More precisely, downloadable source tarballs use automake to build. A source code checkout of the repository uses framewerk to build, and if you don't know what that is, you probably want to stick with the tarballs. |
Sign in to add a comment
If you have your default compile flags set to compile in parallel (ex: -j9) then you'll have to explicitly do "make -j1" when compiling.
It also works well with Mnesia 4.4.5 provided that you make a small change to mnesia_loader.erl.patch
Hi, I tried to compile mnesia-4.3.5ext2.tar.gz on MacOS X 10.4.11, but it failed when patching mnesia_loader.erl. I think that the patch file is broken. Is that right?
Error log is: patching file mnesia_loader.erl Hunk #5 succeeded at 602 (offset 3 lines). Hunk #6 FAILED at 614. Hunk #7 succeeded at 643 (offset 5 lines). 1 out of 7 hunks FAILED -- saving rejects to file mnesia_loader.erl.rej make2?: mnesia_loader.erl? Error 1 make1?: all-recursive? Error 1 make: all-recursive? Error 1
mnesia_loader.erl.rej is: 586,592
- mnesia_lib:cleanup_tmp_files(Tab?) --- 614,622 ---- + mnesia_lib:cleanup_tmp_files(Tab?); + { external_copies, Mod } -> + catch Mod:delete_table(Tab)I'm having the same issue as ytakanoster seems to be, which sounds like the same issue that krzysztof.klis mentions. Does anyone know what needs to be changed in mnesia_loader.erl to make the patch apply?
Hello! I have the same problem as you guys. I guess that mnesia_loader.erl in mnesia have been updated since the release of mnesiaex 4.3.5 so the patch file try to match a line that is not there.
Would be nice if anyone could upload or share the necessary changes to mnesia_loader.erl.patch (even though it is a 'simple' change)
cheers
I use mnesia 4.4.3 and I patched mnesia_loader.erl manually according to the content of mnesia_loader.erl.patch.
Then I deleted all lines in mnesia_loader.erl.patch except for the first 8 lines because an empty patch-file is treated as a corrupt one and will crash the install.
But a small change in mnesia_loader.erl.patch could perhaps be faster:
from
@@ -583,7 +611,9 @@ disc_copies -> catch ?ets_delete_table(Tab); disc_only_copies -> - mnesia_lib:cleanup_tmp_files([Tab]) + mnesia_lib:cleanup_tmp_files([Tab]); + { external_copies, Mod } -> + catch Mod:delete_table(Tab)to (wrong line numbers but should work anyway)
@@ -583,7 +611,9 @@ disc_copies -> catch ?ets_delete_table(Tab); disc_only_copies -> TmpFile = mnesia_lib:tab2tmp(Tab), mnesia_lib:dets_sync_close(Tab), - file:delete(TmpFile) + file:delete(TmpFile); + { external_copies, Mod } -> + catch Mod:delete_table(Tab)Hope this could save some minutes for my fellow erlangers