commit 51e190039d0b1872f1eecb2ef9901915894d56ca Author: Sam Hocevar Date: Mon Sep 5 16:37:25 2016 +0200 roflmao: Lol Engine sample project diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..af61d31 --- /dev/null +++ b/.gitattributes @@ -0,0 +1,17 @@ +# Visual Studio wants crlf, but if we do so, git will +# normalise files and git-svn will push LF files to SVN, +# so we revert back to binary. +*.sln -text +*.csproj -text +*.vcxproj -text + +# Vim doesn't like CRLF, even on Windows +*.vim eol=lf + +# Source files should be normalised in the repository +*.c eol=lf +*.cpp eol=lf +*.cc eol=lf +*.h eol=lf +*.hh eol=lf +*.lolfx eol=lf diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..616a921 --- /dev/null +++ b/.gitignore @@ -0,0 +1,63 @@ +# Autotools cruft +*.o +*.lo +*.a +*.la +*.exe +*.so +*.elf +*.self +*.nexe +*.userprefs +*.usertasks +*.pidb +.auto +.libs +.deps +.dirstamp +.*.androiddir +.*.androidstamp +Makefile +Makefile.in +aclocal.m4 +autom4te.cache +config.h.in +config.h +config.log +config.status +configure +libtool +stamp-* +*-stamp +test-suite.log +# Personal stuff +patch-*.diff +# Debugging cruft +core +!core/ +core.* +vgcore.* +callgrind.out.* +perf.data* +*.gcda +*.gcno +# Editor cruft +.*.swp +*~ +.ycm_extra_conf.pyc +# Visual Studio cruft +*.vcxproj.user +*.csproj.user +binaries/*Debug +binaries/*Release +build/.vs +build/*.VC.VC.opendb +build/*.VC.db +build/*.sdf +build/*.suo +build/*.opensdf +build/visualstudio/ipch +build/visualstudio/*.log +build/visualstudio/*.XGD +# ReSharper cruft +_ReSharper.* diff --git a/.gitmodules b/.gitmodules new file mode 100644 index 0000000..5dcfd56 --- /dev/null +++ b/.gitmodules @@ -0,0 +1,3 @@ +[submodule "lol"] + path = lol + url = ../../lolengine/lol.git diff --git a/Makefile.am b/Makefile.am new file mode 100644 index 0000000..40e118e --- /dev/null +++ b/Makefile.am @@ -0,0 +1,7 @@ + +include $(top_srcdir)/lol/build/autotools/common.am + +ACLOCAL_AMFLAGS = -I lol/build/autotools/m4 + +SUBDIRS = lol roflmao + diff --git a/README.md b/README.md new file mode 100644 index 0000000..419467a --- /dev/null +++ b/README.md @@ -0,0 +1,36 @@ +## roflmao + +`roflmao` is a simple project using Lol Engine. If you want to get +started with Lol Engine, you should fork this project. + +# Setup + +Make sure Lol Engine and its submodules are properly initialised: + + git submodules update --init --recursive + +# Configure + +The default application is called `roflmao` and lies in its own subdirectory. +You should rename it to whatever your application will be called. Make sure +to modify the following files: + + - `configure.ac` + - `Makefile.am` + - `roflmao/Makefile.am` + - `roflmao/roflmao.cpp` + +# Build + +Then bootstrap the project and configure it: + + ./bootstrap + ./configure + +Finally, build the project: + + make + +# Develop + +The sample application is in `roflmao` diff --git a/bootstrap b/bootstrap new file mode 100755 index 0000000..de08f74 --- /dev/null +++ b/bootstrap @@ -0,0 +1,8 @@ +#!/bin/sh + +# Bootstrap Lol Engine first +(cd lol && ./bootstrap) + +# Then bootstrap this project, using the same script +./lol/bootstrap + diff --git a/configure.ac b/configure.ac new file mode 100644 index 0000000..b1d5276 --- /dev/null +++ b/configure.ac @@ -0,0 +1,47 @@ +dnl +dnl Configure script for a Lol Engine project +dnl + +AC_INIT(roflmao, 0.0) + +dnl +dnl Standard autoconf setup and tools requirements +dnl + +AC_PREREQ(2.50) +AC_CONFIG_AUX_DIR(.auto) +AC_CANONICAL_SYSTEM +AM_INIT_AUTOMAKE([subdir-objects no-define tar-ustar silent-rules]) +AM_DEFAULT_VERBOSITY=0 + +AC_PROG_CXX +AM_PROG_LIBTOOL +AC_LIBTOOL_CXX + +dnl +dnl Build and configure Lol Engine before our repository +dnl Ensure $lol_srcdir and $lol_builddir are properly set up +dnl + +AC_CONFIG_SUBDIRS([lol]) +AC_SUBST(lol_srcdir, '${top_srcdir}/lol') +AC_SUBST(lol_builddir, '${top_builddir}/lol') + +dnl +dnl Inherit all Lol Engine checks +dnl + +LOL_AC_CHECK() +LOL_AC_SUBST() + +dnl +dnl Export automake variables and write makefiles +dnl + +AC_CONFIG_FILES( + [Makefile + roflmao/Makefile +]) + +AC_OUTPUT + diff --git a/lol b/lol new file mode 160000 index 0000000..b686b9e --- /dev/null +++ b/lol @@ -0,0 +1 @@ +Subproject commit b686b9e965640f4325340fab94089bdebaa3a390 diff --git a/roflmao/.gitignore b/roflmao/.gitignore new file mode 100644 index 0000000..4b8e9f8 --- /dev/null +++ b/roflmao/.gitignore @@ -0,0 +1,2 @@ +roflmao +*.exe diff --git a/roflmao/Makefile.am b/roflmao/Makefile.am new file mode 100644 index 0000000..55d3524 --- /dev/null +++ b/roflmao/Makefile.am @@ -0,0 +1,10 @@ + +include $(top_srcdir)/lol/build/autotools/common.am + +bin_PROGRAMS = roflmao + +roflmao_SOURCES = roflmao.cpp +roflmao_CPPFLAGS = $(AM_CPPFLAGS) +roflmao_DEPENDENCIES = @LOL_DEPS@ +roflmao_LDFLAGS = $(AM_LDFLAGS) + diff --git a/roflmao/roflmao.cpp b/roflmao/roflmao.cpp new file mode 100644 index 0000000..bc76424 --- /dev/null +++ b/roflmao/roflmao.cpp @@ -0,0 +1,16 @@ +// +// Roflmao — Lol Engine Test App +// + +#if HAVE_CONFIG_H +# include "config.h" +#endif + +#include + +int main(int argc, char **argv) +{ + lol::System::Init(argc, argv); + return EXIT_SUCCESS; +} +