summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorErik Kundiman <erik@megapahit.org>2023-08-01 09:57:25 +0800
committerErik Kundiman <erik@megapahit.org>2023-08-01 09:57:25 +0800
commit8204b0f052da31f6ba9d6165f1e1cc9b27c6909f (patch)
tree01c4c9662f210d29ed282e4478a6c12fe9371943
parent02090f361e631a014a3e2d35cb25229ad0f0b843 (diff)
Instructions on how to build on some platforms
plus the ignored build directory if following the instructions.
-rwxr-xr-x.gitignore1
-rw-r--r--README.md44
-rw-r--r--doc/freebsd.jpgbin0 -> 631790 bytes
3 files changed, 42 insertions, 3 deletions
diff --git a/.gitignore b/.gitignore
index 80eca667df..afee974c89 100755
--- a/.gitignore
+++ b/.gitignore
@@ -11,6 +11,7 @@
# Specific paths and/or names
LICENSES
+build/
build-darwin-*
build-linux-*
debian/files
diff --git a/README.md b/README.md
index c57140af9c..dfdae0ed72 100644
--- a/README.md
+++ b/README.md
@@ -5,7 +5,7 @@
</picture>
**[Second Life][] is a free 3D virtual world where users can create, connect and chat with others from around the
-world.** This repository contains the source code for the official client.
+world.** This repository contains a fork of the source code for the official client.
## Open Source
@@ -28,9 +28,47 @@ Third party maintained forks, which include Linux compatible builds, are indexed
[Windows](https://wiki.secondlife.com/wiki/Build_the_Viewer_on_Windows)
-[Mac](https://wiki.secondlife.com/wiki/Build_the_Viewer_on_macOS)
+### macOS
-[Linux](https://wiki.secondlife.com/wiki/Build_the_Viewer_on_Linux)
+```
+# port install git cmake pkgconfig apr-util boost collada-dom freealut hunspell jsoncpp libsdl uriparser VLC
+$ export LL_BUILD="-DLL_DARWIN=1 -DPIC -fPIC -gdwarf-2 -stdlib=libc++ -iwithsysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk -DLL_RELEASE=1 -DLL_RELEASE_FOR_DOWNLOAD=1"
+```
+
+### GNU/Linux
+
+```
+# apt install git cmake pkg-config libalut-dev libaprutil-dev libboost-fiber-dev libboost-program-options-dev libboost-regex-dev libcollada-dom-dev libcurl4-openssl-dev libexpat1-dev libglu1-mesa-dev libgtk2.0-dev libhunspell-dev libjsoncpp-dev libmeshoptimizer-dev libnghttp2-dev libopenjp2-dev libsdl1.2-dev liburiparser-dev libvlc-dev libvlccore-dev libvorbis-dev libxmlrpc-epi-dev libxxhash-dev
+$ export LL_BUILD="-DLL_LINUX=1 -fPIC"
+```
+
+### FreeBSD
+
+```
+# portmaster devel/git devel/cmake devel/pkgconf devel/apr1 devel/collada-dom devel/sdl12 devel/xxhash audio/freealut audio/libvorbis graphics/openjpeg misc/meshoptimizer multimedia/vlc net/uriparser net/xmlrpc-epi textproc/hunspell x11-toolkits/gtk20
+$ setenv LL_BUILD "-DLL_FREEBSD=1 -fPIC"
+```
+
+### Common
+
+```
+$ cd viewer
+$ git remote add megapahit https://megapahit.org/viewer.git
+$ git fetch megapahit
+$ git checkout megapahit/main
+$ mkdir -p build
+$ cd build
+$ cmake -DCMAKE_BUILD_TYPE:STRING=Release -DADDRESS_SIZE:INTERNAL=64 -DUSESYSTEMLIBS:BOOL=ON -DUSE_OPENAL:BOOL=ON -DLL_TESTS:BOOL=OFF -DNDOF:BOOL=OFF -DVIEWER_CHANNEL:STRING=Megapahit -DVIEWER_BINARY_NAME:STRING=megapahit -DBUILD_SHARED_LIBS:BOOL=ON -DPACKAGE:BOOL=OFF -DINSTALL:BOOL=ON -DOpenGL_GL_PREFERENCE:STRING=LEGACY ../indra
+$ make -j12
+$ sudo make install
+$ megapahit
+```
+
+## Example
+
+![FreeBSD][doc/freebsd.jpg]
+
+Running natively on FreeBSD (not with Linux binary compatibility).
## Contribute
diff --git a/doc/freebsd.jpg b/doc/freebsd.jpg
new file mode 100644
index 0000000000..23c2c53925
--- /dev/null
+++ b/doc/freebsd.jpg
Binary files differ