diff --git a/Makefile.am b/Makefile.am
index 4121d2f..97e3a26 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -3,7 +3,7 @@ include $(top_srcdir)/lol/build/autotools/common.am
ACLOCAL_AMFLAGS = -I lol/build/autotools/m4
-SUBDIRS = lol roflmao
+SUBDIRS = lol neercs
test: check
diff --git a/README.md b/README.md
deleted file mode 100644
index 19d0707..0000000
--- a/README.md
+++ /dev/null
@@ -1,47 +0,0 @@
-# roflmao
-
-[![Build Status (Travis-CI)](https://travis-ci.org/lolengine/lol-roflmao.svg?branch=master)](https://travis-ci.org/lolengine/lol-roflmao)
-[![Build Status (Semaphore-CI)](https://semaphoreci.com/api/v1/samhocevar/lol-roflmao/branches/master/badge.svg)](https://semaphoreci.com/samhocevar/lol-roflmao)
-
-`roflmao` is a simple project using Lol Engine. If you want to get
-started with Lol Engine, you may either:
-
- - fork this project
- - duplicate this project (see [“duplicating a repository”](https://help.github.com/articles/duplicating-a-repository/))
-
-## Setup
-
-Make sure Lol Engine and its submodules are properly initialised:
-
- git submodule update --init --recursive
-
-On Linux, make sure the following packages are installed:
-
- automake autoconf libtool pkg-config
- libglew-dev
- libsdl2-dev libsdl2-image-dev libsdl2-mixer-dev
-
-## 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
-
-You can of course have several projects in the same repository.
-
-## Build
-
-Then bootstrap the project and configure it:
-
- ./bootstrap
- ./configure
-
-Finally, build the project:
-
- make
-
diff --git a/configure.ac b/configure.ac
index f43a1ee..d11ec2b 100644
--- a/configure.ac
+++ b/configure.ac
@@ -2,7 +2,7 @@ dnl
dnl Configure script for a Lol Engine project
dnl
-AC_INIT(roflmao, 0.0)
+AC_INIT(neercs, 0.0)
dnl
dnl Standard autoconf setup and tools requirements
@@ -18,20 +18,43 @@ AC_PROG_CXX
AM_PROG_LIBTOOL
AC_LIBTOOL_CXX
-AC_CONFIG_FILES(
- [Makefile
- roflmao/Makefile
-])
-
dnl
dnl Inherit all Lol Engine checks
dnl
LOL_AC_SUBPROJECT()
+dnl
+dnl Additional checks
+dnl
+
+PKG_CHECK_MODULES(CACA, caca >= 0.99.beta17)
+
+dnl Unix-specific libutil
+AC_CHECK_LIB(util, forkpty,
+ [UTIL_LIBS="${UTIL_LIBS} -lutil"
+ dnl Override future forkpty detection
+ ac_cv_func_forkpty="yes"])
+AC_CHECK_FUNCS(forkpty)
+AC_CHECK_FUNCS(getopt_long)
+
+AC_CHECK_HEADERS(glob.h endian.h getopt.h)
+AC_CHECK_HEADERS(libutil.h util.h pty.h)
+AC_CHECK_HEADERS(linux/kdev_t.h linux/major.h)
+AC_CHECK_HEADERS(security/pam_appl.h security/pam_misc.h)
+AC_CHECK_HEADERS(pam/pam_appl.h pam/pam_misc.h)
+
+AC_SUBST(UTIL_LIBS)
+AC_SUBST(PAM_LIBS)
+
dnl
dnl Perform the actual commands
dnl
+AC_CONFIG_FILES(
+ [Makefile
+ neercs/Makefile
+])
+
AC_OUTPUT
diff --git a/lol b/lol
index 99c8c23..e27698f 160000
--- a/lol
+++ b/lol
@@ -1 +1 @@
-Subproject commit 99c8c2353e082b20cf8d6f2a5501331dfc2a54ca
+Subproject commit e27698f8ec9a606b6a012f9d33392790905f3728
diff --git a/roflmao.sln b/neercs.sln
similarity index 93%
rename from roflmao.sln
rename to neercs.sln
index 989a914..d28217b 100644
--- a/roflmao.sln
+++ b/neercs.sln
@@ -14,9 +14,9 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Engine", "Engine", "{1AFD58
msbuild\config-build.xml = msbuild\config-build.xml
EndProjectSection
EndProject
-Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "roflmao", "roflmao\roflmao.vcxproj", "{3D02B33D-C348-43C8-AB6A-FB6E6F3C0E7C}"
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "neercs", "neercs\neercs.vcxproj", "{3D02B33D-C348-43C8-AB6A-FB6E6F3C0E7C}"
EndProject
-Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Roflmao", "Roflmao", "{03B9D2E1-AFBA-4F66-8DE0-6499C9F9155F}"
+Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Neercs", "Neercs", "{03B9D2E1-AFBA-4F66-8DE0-6499C9F9155F}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
diff --git a/neercs/Makefile.am b/neercs/Makefile.am
index ec71808..ae935c3 100644
--- a/neercs/Makefile.am
+++ b/neercs/Makefile.am
@@ -1,11 +1,7 @@
-include $(top_srcdir)/build/autotools/common.am
+include $(top_srcdir)/lol/build/autotools/common.am
-if !USE_ANDROID
-if BUILD_NEERCS
bin_PROGRAMS = neercs
-endif
-endif
neercs_SOURCES = \
neercs.cpp neercs.h \
diff --git a/neercs/neercs.vcxproj b/neercs/neercs.vcxproj
index 68f719b..e81a2cf 100644
--- a/neercs/neercs.vcxproj
+++ b/neercs/neercs.vcxproj
@@ -1,5 +1,9 @@
+
+ $(SolutionDir)\lol
+ $(SolutionDir)\..
+
Debug
@@ -67,17 +71,6 @@
-
-
- {9e62f2fe-3408-4eae-8238-fd84238ceeda}
-
-
- {83d3b207-c601-4025-8f41-01dedc354661}
-
-
- {d84021ca-b233-4e0f-8a52-071b83bbccc4}
-
-
@@ -92,32 +85,35 @@
+
+
+ {9e62f2fe-3408-4eae-8238-fd84238ceeda}
+
+
+ {83d3b207-c601-4025-8f41-01dedc354661}
+
+
+ {d84021ca-b233-4e0f-8a52-071b83bbccc4}
+
+
- {587FCCE9-1D8D-4398-B8B6-E8F4E9A92233}
+ {3d02b33d-c348-43c8-ab6a-fb6e6f3c0e7c}
Application
Win32Proj
-
+
-
+
-
+
-
-
-
- $(CacaIncludes);%(AdditionalIncludeDirectories)
-
-
- $(CacaDeps);%(AdditionalDependencies)
- $(CacaLibs);%(AdditionalLibraryDirectories)
-
-
+
+
-
+
diff --git a/neercs/old/configuration.c b/neercs/old/configuration.c
index 1bea7c8..67c0d3b 100644
--- a/neercs/old/configuration.c
+++ b/neercs/old/configuration.c
@@ -150,7 +150,7 @@ int parse_conf_line(char *buf, int size, struct screen_list *screen_list)
char *line = NULL;
int l = 0;
int in_quote = 0, end_spaces = 0;
- static struct option *prev = NULL;
+ static struct option_t *prev = NULL;
if (size <= 0)
return -1;
@@ -221,7 +221,7 @@ int parse_conf_line(char *buf, int size, struct screen_list *screen_list)
}
else
{
- struct option *option = malloc(sizeof(struct option));
+ struct option_t *option = malloc(sizeof(struct option_t));
if (!option)
{
fprintf(stderr, "Can't allocate memory at %s:%d\n",
@@ -247,7 +247,7 @@ int parse_conf_line(char *buf, int size, struct screen_list *screen_list)
return s;
}
-int get_key_value(char *line, struct option *option)
+int get_key_value(char *line, struct option_t *option)
{
unsigned int i, o = 0, b = 0, end_spaces = 0;
char *cur = NULL;
@@ -350,7 +350,7 @@ struct config_line *get_config(const char *name)
int fill_config(struct screen_list *screen_list)
{
int i = 0;
- struct option *option = screen_list->config;
+ struct option_t *option = screen_list->config;
while (option)
{
diff --git a/neercs/old/neercs.h b/neercs/old/neercs.h
index 1aa0227..71c7e21 100644
--- a/neercs/old/neercs.h
+++ b/neercs/old/neercs.h
@@ -242,7 +242,7 @@ struct screen_list
long long unsigned int last_switch; /* Cube */
struct screen **screen; /* Windows */
- struct option *config; /* Option parsing and configuration */
+ struct option_t *config; /* Option parsing and configuration */
struct sys sys; /* System stuff */
struct recurrent_list *recurrent_list; /* Recurrents functions */
@@ -256,12 +256,12 @@ struct screen_list
};
/* Configuration */
-struct option
+struct option_t
{
char *key;
char *value;
- struct option *next;
+ struct option_t *next;
};
struct config_line
{
@@ -398,7 +398,7 @@ int remove_recurrent(struct recurrent_list *list, int n);
/* Configuration file */
int read_configuration_file(char *filename, struct screen_list *screen_list);
int parse_conf_line(char *buf, int size, struct screen_list *screen_list);
-int get_key_value(char *line, struct option *option);
+int get_key_value(char *line, struct option_t *option);
int fill_config(struct screen_list *screen_list);
struct config_line *get_config(const char *name);
struct config_line *get_config_option(void);
diff --git a/neercs/old/screen_list.c b/neercs/old/screen_list.c
index 6130a36..9020795 100644
--- a/neercs/old/screen_list.c
+++ b/neercs/old/screen_list.c
@@ -147,7 +147,7 @@ struct screen_list *create_screen_list(void)
void free_screen_list(struct screen_list *screen_list)
{
int i;
- struct option *option;
+ struct option_t *option;
if (screen_list->dp)
caca_free_display(screen_list->dp);
@@ -190,7 +190,7 @@ void free_screen_list(struct screen_list *screen_list)
while (option)
{
- struct option *kromeugnon = option;
+ struct option_t *kromeugnon = option;
option = option->next;
if (kromeugnon->key)
free(kromeugnon->key);
diff --git a/roflmao/.gitignore b/roflmao/.gitignore
deleted file mode 100644
index 4b8e9f8..0000000
--- a/roflmao/.gitignore
+++ /dev/null
@@ -1,2 +0,0 @@
-roflmao
-*.exe
diff --git a/roflmao/Makefile.am b/roflmao/Makefile.am
deleted file mode 100644
index 55d3524..0000000
--- a/roflmao/Makefile.am
+++ /dev/null
@@ -1,10 +0,0 @@
-
-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
deleted file mode 100644
index bc76424..0000000
--- a/roflmao/roflmao.cpp
+++ /dev/null
@@ -1,16 +0,0 @@
-//
-// 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;
-}
-
diff --git a/roflmao/roflmao.vcxproj b/roflmao/roflmao.vcxproj
deleted file mode 100644
index ed35ffb..0000000
--- a/roflmao/roflmao.vcxproj
+++ /dev/null
@@ -1,67 +0,0 @@
-
-
-
- $(SolutionDir)\lol
- $(SolutionDir)\..
-
-
-
- Debug
- ORBIS
-
-
- Debug
- Win32
-
-
- Debug
- x64
-
-
- Release
- ORBIS
-
-
- Release
- Win32
-
-
- Release
- x64
-
-
-
-
-
-
-
- {9e62f2fe-3408-4eae-8238-fd84238ceeda}
-
-
- {83d3b207-c601-4025-8f41-01dedc354661}
-
-
- {d84021ca-b233-4e0f-8a52-071b83bbccc4}
-
-
-
- {3d02b33d-c348-43c8-ab6a-fb6e6f3c0e7c}
- Application
- Win32Proj
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-