@@ -1,10 +1,10 @@
There are three ways you are probably reading this right now:
- * On [ObjFW](https://objfw.nil.im/)'s homepage, via Fossil
+ * On [ObjFW](https://objfw.nil.im/)'s homepage, via Fossil's web interface
* On [GitHub](https://github.com/ObjFW/ObjFW)
- * Via an editor or pager, by opening `README.md` from a checkout or tarball
+ * Via an editor or pager, by opening `README.md` from a clone or tarball
ObjFW is developed using Fossil, so if you are reading this on GitHub or any
other place, you are most likely using a mirror.
@@ -19,12 +19,11 @@
* [Building as a framework](#building-framework)
* [Using the macOS or iOS framework in Xcode](#framework-in-xcode)
* [Broken Xcode versions](#broken-xcode-versions)
* [Windows](#windows)
* [Getting MSYS2](#getting-msys2)
- * [Updating MSYS2](#updating-msys2)
- * [Installing MinGW-w64 using MSYS2](#installing-mingw-w64)
+ * [Setting up MSYS2](#setting-up-msys2)
* [Getting, building and installing ObjFW](#steps-windows)
* [Nintendo DS, Nintendo 3DS and Wii](#nintendo)
* [Nintendo DS](#nintendo-ds)
* [Nintendo 3DS](#nintendo-3ds)
* [Wii](#wii)
@@ -31,10 +30,12 @@
* [Amiga](#amiga)
* [Writing your first application with ObjFW](#first-app)
* [Documentation](#documentation)
* [Bugs and feature requests](#bugs)
* [Support and community](#support)
+ * [Donating](#donating)
+ * [Thanks](#thanks)
* [Commercial use](#commercial-use)
What is ObjFW?
@@ -106,17 +107,16 @@
Fossil
Clone the Fossil repository like this:
- $ fossil clone https://objfw.nil.im objfw.fossil
- $ mkdir objfw && cd objfw
- $ fossil open ../objfw.fossil
+ $ fossil clone https://objfw.nil.im
You can then use Fossil's web interface to browse the timeline, tickets,
wiki pages, etc.:
+ $ cd objfw
$ fossil ui
It's also possible to open the same local repository multiple times, so that
you have multiple working directories all backed by the same local
repository.
@@ -123,10 +123,16 @@
In order to verify the signature of the currently checked out checkin, you
can use:
$ fossil artifact current | gpg --verify
+
+ Please note that not all checkins are signed, as the signing key only resides
+ on trusted systems. This means that checkins I perform on e.g. Windows are
+ unsigned. However, usually it should not take long until there is another
+ signed checkin. Alternatively, you can go back until the last signed checkin
+ and review changes from there on.
Git
To clone the Git repository, use the following:
@@ -139,11 +145,12 @@
To install ObjFW, just run the following commands:
$ ./configure
$ make
- $ make install
+ $ make check
+ $ sudo make install
In case you checked out ObjFW from the Fossil or Git repository, you need to
run the following command first:
$ ./autogen.sh
@@ -151,27 +158,33 @@
macOS and iOS
Building as a framework
When building for macOS or iOS, everything is built as a `.framework` by
- default if `--disable-shared` has not been specified to `configure`.
+ default if `--disable-shared` has not been specified to `./configure`. The
+ frameworks will end up in `$PREFIX/Library/Frameworks`.
- To build for iOS, use something like this:
+ To build for macOS, just follow the
+ regular instructions above.
+
+ To build for iOS, follow the regular instructions, but instead of
+ `./configure` do something like this:
$ clang="clang -isysroot $(xcrun --sdk iphoneos --show-sdk-path)"
$ export OBJC="$clang -arch armv7 -arch arm64"
$ export OBJCPP="$clang -arch armv7 -E"
$ export IPHONEOS_DEPLOYMENT_TARGET="9.0"
$ ./configure --prefix=/usr/local/ios --host=arm64-apple-darwin
- To build for the iOS simulator, use something like this:
+ To build for the iOS simulator, follow the regular instructions, but instead
+ of `./configure` use something like this:
$ clang="clang -isysroot $(xcrun --sdk iphonesimulator --show-sdk-path)"
- $ export OBJC="$clang -arch i386 -arch x86_64"
- $ export OBJCPP="$clang -arch i386 -E"
+ $ export OBJC="$clang -arch arm64 -arch x86_64"
+ $ export OBJCPP="$clang -arch arm64 -E"
$ export IPHONEOS_DEPLOYMENT_TARGET="9.0"
- $ ./configure --prefix=/usr/local/iossim --host=x86_64-apple-darwin
+ $ ./configure --prefix=/usr/local/iossim --host=arm64-apple-darwin
Using the macOS or iOS framework in Xcode
To use the macOS framework in Xcode, you need to add the `.framework`s to
your project and add the following flags to `Other C Flags`:
@@ -209,73 +222,61 @@
Getting MSYS2
The first thing to install is [MSYS2](https://www.msys2.org) to provide a
basic UNIX-like environment for Windows. Unfortunately, the binaries are not
- signed and there is no way to verify their integrity, so only download this
- from a trusted connection. Everything else you will download using MSYS2
- later will be cryptographically signed.
-
-Updating MSYS2
-
- The first thing to do is updating MSYS2. It is important to update things in
- a certain order, as `pacman` (the package manager MSYS2 uses, which comes
- from Arch Linux) does not know about a few things that are special on
- Windows.
-
- First, update the mirror list:
-
- $ pacman -Sy pacman-mirrors
-
- Then proceed to update the `msys2-runtime` itself, `bash` and `pacman`:
-
- $ pacman -S msys2-runtime bash pacman mintty
-
- Now close the current window and restart MSYS2, as the current window is now
- defunct. In a new MSYS2 window, update the rest of MSYS2:
-
- $ pacman -Su
-
- Now you have a fully updated MSYS2. Whenever you want to update MSYS2,
- proceed in this order. Notice that the first `pacman` invocation includes
- `-y` to actually fetch a new list of packages.
-
-Installing MinGW-w64 using MSYS2
-
- Now it's time to install MinGW-w64. If you want to build 32 bit binaries:
-
- $ pacman -S mingw-w64-i686-clang mingw-w64-i686-gcc-objc
-
- For 64 bit binaries:
-
- $ pacman -S mingw-w64-x86_64-clang mingw-w64-x86_64-gcc-objc
-
- There is nothing wrong with installing them both, as MSYS2 has created two
- entries in your start menu: `MinGW-w64 Win32 Shell` and
- `MinGW-w64 Win64 Shell`. So if you want to build for 32 or 64 bit, you just
- start the correct shell.
-
- Finally, install a few more things needed to build ObjFW:
-
- $ pacman -S autoconf automake fossil make
+ signed, so make sure you download it via HTTPS. However, packages you
+ download and install via MSYS2 are cryptographically signed.
+
+Setting up MSYS2
+
+ MSYS2 currently supports 5 different
+ [environments](https://www.msys2.org/docs/environments/). All of them except
+ for the one called just "MSYS" are supported, but which packages you need to
+ install depends on the environment(s) you want to use.
+
+ For MINGW64, use:
+
+ $ pacman -Syu mingw-w64-x86_64-clang mingw-w64-x86_64-fossil
+
+ For UCRT64, use:
+
+ $ pacman -Syu mingw-w64-ucrt-x86_64-clang mingw-w64-ucrt-x86_64-fossil
+
+ For CLANG64, use:
+
+ $ pacman -Syu mingw-w64-clang-x86_64-clang mingw-w64-clang-x86_64-fossil
+
+ For MINGW32, use:
+
+ $ pacman -Syu mingw-w64-i686-clang mingw-w64-i686-fossil
+
+ When using `pacman` to install the packages, `pacman` might tell you to close
+ the window. If it does so, close the window, restart MSYS2 and execute the
+ `pacman` command again.
+
+ There is nothing wrong with installing multiple environments, as MSYS2 has
+ created shortcuts for each of them in your start menu. Just make sure to use
+ the correct shortcut for the environment you want to use.
+
+ Finally, install a few more things that are common between all environments:
+
+ $ pacman -S autoconf automake make
Getting, building and installing ObjFW
- Start the MinGW-w64 Win32 or Win64 Shell (depening on what version you want
- to build - do *not* use the MSYS2 Shell shortcut, but use the MinGW-w64 Win32
- or Win64 Shell shortcut instead!) and check out ObjFW:
-
- $ fossil clone https://objfw.nil.im objfw.fossil
- $ mkdir objfw && cd objfw
- $ fossil open ../objfw.fossil
-
- You can also download a release tarball if you want. Now go to the newly
+ Start the MSYS2 using the shortcut for the environment you want to use and
+ check out ObjFW:
+
+ $ fossil clone https://objfw.nil.im
+
+ You can also download a release tarball if you want. Now `cd` to the newly
checked out repository and build and install it:
$ ./autogen.sh && ./configure && make -j16 install
- If everything was successfully, you can now build projects using ObjFW for
+ If everything was successful, you can now build projects using ObjFW for
Windows using the normal `objfw-compile` and friends.
Nintendo DS, Nintendo 3DS and Wii
Download and install [devkitPro](https://devkitpro.org/wiki/Getting_Started).
@@ -368,12 +369,27 @@
* A [Gitter room](https://gitter.im/ObjFW/ObjFW), bridged to the Matrix room
above
Please don't hesitate to join any or all of those!
+
+Donating
+
+ If you want to donate to ObjFW, you can read about possible ways to do so
+ [here](https://objfw.nil.im/wiki?name=Donating).
+
+
+Thanks
+
+ * Thank you to [Jonathan Neuschäfer](https://github.com/neuschaefer) for
+ reviewing the *entirety* (all 84k LoC at the time) of ObjFW's codebase in
+ 2017!
+ * Thank you to [Hill Ma](https://github.com/mahiuchun) for donating an M1 Mac
+ Mini to the project!
+
Commercial use
If for whatever reason neither the terms of the QPL nor those of the GPL work
for you, a proprietary license for ObjFW including support is available upon
request. Just write a mail to js@nil.im and we can find a reasonable solution
for both parties.