# Nim [![Build Status](https://dev.azure.com/nim-lang/Nim/_apis/build/status/nim-lang.Nim?branchName=devel)](https://dev.azure.com/nim-lang/Nim/_build/latest?definitionId=1&branchName=devel) This repository contains the Nim compiler, Nim's stdlib, tools and documentation. For more information about Nim, including downloads and documentation for the latest release, check out [Nim's website][nim-site] or [bleeding edge docs](https://nim-lang.github.io/Nim/). ## Community [![Join the IRC chat][badge-nim-irc]][nim-irc] [![Join the Gitter chat][badge-nim-gitter]][nim-gitter] [![Get help][badge-nim-forum-gethelp]][nim-forum] [![View Nim posts on Stack Overflow][badge-nim-stackoverflow]][nim-stackoverflow-newest] [![Follow @nim_lang on Twitter][badge-nim-twitter]][nim-twitter] * The [forum][nim-forum] - the best place to ask questions and to discuss Nim. * [#nim IRC Channel (Freenode)][nim-irc] - a place to discuss Nim in real-time. Also where most development decisions get made. * [Gitter][nim-gitter] - an additional place to discuss Nim in real-time. There is a bridge between Gitter and the IRC channel. * [Telegram][nim-telegram] - an additional place to discuss Nim in real-time. There is the official Telegram channel. * [Stack Overflow][nim-stackoverflow] - a popular Q/A site for programming related topics that includes posts about Nim. * [Github Wiki][nim-wiki] - Misc user-contributed content. ## Compiling The compiler currently officially supports the following platform and architecture combinations: * Windows (Windows XP or greater) - x86 and x86_64 * Linux (most, if not all, distributions) - x86, x86_64, ppc64 and armv6l * Mac OS X (10.04 or greater) - x86, x86_64 and ppc64 More platforms are supported, however they are not tested regularly and they may not be as stable as the above-listed platforms. Compiling the Nim compiler is quite straightforward if you follow these steps: First, the C source of an older version of the Nim compiler is needed to bootstrap the latest version because the Nim compiler itself is written in the Nim programming language. Those C sources are available within the [``nim-lang/csources``][csources-repo] repository. Next, to build from source you will need: * A C compiler such as ``gcc`` 3.x/later or an alternative such as ``clang``, ``Visual C++`` or ``Intel C++``. It is recommended to use ``gcc`` 3.x or later. * Either ``git`` or ``wget`` to download the needed source repositories. * The ``build-essential`` package when using ``gcc`` on Ubuntu (and likely other distros as well). * On Windows MinGW 4.3.0 (GCC 8.10) is the minimum recommended compiler. * Nim hosts a known working MinGW distribution: * [MinGW32.7z](https://nim-lang.org/download/mingw32.7z) * [MinGW64.7z](https://nim-lang.org/download/mingw64.7z) **Windows Note: Cygwin and similar posix runtime environments are not supported.** Then, if you are on a \*nix system or Windows, the following steps should compile Nim from source using ``gcc``, ``git`` and the ``koch`` build tool. **Note: The following commands are for the development version of the compiler.** For most users, installing the latest stable version is enough. Check out the installation instructions on the website to do so: https://nim-lang.org/install.html. For package maintainers: see [packaging guidelines](https://nim-lang.github.io/Nim/packaging.html). First get Nim from github: ``` git clone https://github.com/nim-lang/Nim.git cd Nim ``` Next run the appropriate build shell script for your platform: * `build_all.sh` (Linux, Mac) * `build_all.bat` (Windows) Windows requires a number of other dependencies that you may need to install including PCRE and OpenSSL. Nim hosts a zip package containing known working versions of the required DLLs [here](https://nim-lang.org/download/dlls.zip). Finally, once you have finished the build steps (on Windows, Mac or Linux) you should add the ``bin`` directory to your PATH. See also [rebuilding the compiler](doc/intern.rst#rebuilding-the-compiler). ## Koch ``koch`` is the build tool used to build various parts of Nim and to generate documentation and the website, among other things. The ``koch`` tool can also be used to run the Nim test suite. Assuming that you added Nim's ``bin`` directory to your PATH, you may execute the tests using ``./koch tests``. The tests take a while to run, but you can run a subset of tests by specifying a category (for example ``./koch tests cat async``). For more information on the ``koch`` build tool please see the documentation within the [doc/koch.rst](doc/koch.rst) file. ## Nimble ``nimble`` is Nim's package manager. To learn more about it, see the [``nim-lang/nimble``][nimble-repo] repository. ## Contributors This project exists thanks to all the people who contribute. ## Contributing [![Backers on Open Collective](https://opencollective.com/nim/backers/badge.svg)](#backers) [![Sponsors on Open Collective](https://opencollective.com/nim/sponsors/badge.svg)](#sponsors) [![Setup a bounty via Bountysource][badge-nim-bountysource]][nim-bountysource] [![Donate Bitcoins][badge-nim-bitcoin]][nim-bitcoin] [![Open Source Helpers](https://www.codetriage.com/nim-lang/nim/badges/users.svg)](https://www.codetriage.com/nim-lang/nim) See [detailed contributing guidelines](https://nim-lang.github.io/Nim/contributing.htm
/*
 *
 *           Nim's Runtime Library
 *       (c) Copyright 2017 Emery Hemingway
 *
 *   See the file "copying.txt", included in this
 *   distribution, for details about the copyright.
 *
 */

#ifndef _GENODE_CPP__SYSLOCKS_H_
#define _GENODE_CPP__SYSLOCKS_H_

/* Genode includes */
#include <base/semaphore.h>
#include <base/lock.h>

namespace Nim {
	struct SysLock;
	struct SysCond;
}

struct Nim::SysLock
{