Browse Source

Remove autotools build system

Bart van Strien 1 year ago
parent
commit
aa14bacdc9

+ 0 - 24
platform/unix/Makefile.am

@@ -1,24 +0,0 @@
-ACLOCAL_AMFLAGS = -I platform/unix/m4
-SUBDIRS = src
-EXTRA_DIST = changes.txt license.txt readme.md \
-	platform/unix/love.desktop.in
-dist_man1_MANS = platform/unix/love.6
-
-applicationsdir=$(datarootdir)/applications
-mimeinfodir=$(datarootdir)/mime/packages
-pixmapsdir=$(datarootdir)/pixmaps
-mimeiconsdir=$(datarootdir)/icons/hicolor/scalable/mimetypes
-
-applications_DATA = platform/unix/love.desktop
-dist_mimeinfo_DATA = platform/unix/love.xml
-dist_pixmaps_DATA = platform/unix/love.svg
-dist_mimeicons_DATA = platform/unix/application-x-love-game.svg
-
-platform/unix/love.desktop: platform/unix/love.desktop.in
-	$(MKDIR_P) platform/unix
-	rm -f $@ [email protected]
-	$(SED) \
-		-e "s|@CMAKE_INSTALL_FULL_BINDIR[@]|$(bindir)|" \
-		${srcdir}/[email protected] > [email protected]
-	chmod a-w [email protected]
-	mv [email protected] $@

+ 0 - 71
platform/unix/automagic

@@ -1,71 +0,0 @@
-#!/bin/bash
-
-log() {
-	echo "[automagic] " $@
-}
-
-die() {
-	log "Fatal: "$@
-	exit 1
-}
-
-if [[ ! -d platform/unix ]]; then
-	log "Can't find the 'plaform/unix' folder, make sure you run this from the root of the repository."
-	exit 1
-fi
-
-AUTOHEADER=${AUTOHEADER:-$(which autoheader)}
-AUTOCONF=${AUTOCONF:-$(which autoconf)}
-LIBTOOLIZE=${LIBTOOLIZE:-$(which libtoolize)}
-ACLOCAL=${ACLOCAL:-$(which aclocal)}
-AUTOMAKE=${AUTOMAKE:-$(which automake)}
-
-[[ -x ${AUTOHEADER} ]] || die "Could not find autoheader. Install autoconf."
-[[ -x ${AUTOCONF} ]]   || die "Could not find autoconf."
-[[ -x ${LIBTOOLIZE} ]] || die "Could not find libtoolize. Install libtool."
-[[ -x ${ACLOCAL} ]]    || die "Could not find aclocal. Install automake."
-[[ -x ${AUTOMAKE} ]]   || die "Could not find automake."
-
-print_errors() {
-	local output
-	output="$("$@" 2>&1)" && return 0
-	printf "%s\n" "$output"
-	return 1
-}
-
-automagic() {
-	log "Copying files..."
-	cp platform/unix/configure.ac .
-	cp platform/unix/Makefile.am .
-
-	log "Running genmodules..."
-	if ! print_errors bash platform/unix/genmodules "$1"; then
-		echo "You should be doing this from the root directory of the project."
-		exit 1
-	fi
-
-	log "Running autoheader..."
-	print_errors ${AUTOHEADER} || return 1 # Gimmie config.h.in
-
-	log "Running libtoolize..."
-	print_errors ${LIBTOOLIZE} --force || return 1
-
-	log "Running aclocal..."
-	print_errors ${ACLOCAL} || return 1
-
-	log "Running autoconf..."
-	print_errors ${AUTOCONF} || return 1
-
-	log "Running automake..."
-	print_errors ${AUTOMAKE} -a || return 1
-}
-
-automagic "$@"
-
-if [[ $? -eq 1 ]]; then
-	log "Failed, sadface."
-	log "This is generally a configuration error (I'm looking at you aclocal)"
-	exit 1
-else
-	log "Success, carry on configuring."
-fi

+ 0 - 125
platform/unix/configure.ac

@@ -1,125 +0,0 @@
-AC_INIT([love], [12.0])
-AC_CONFIG_HEADERS([config.h])
-AC_CONFIG_AUX_DIR([platform/unix])
-AC_CONFIG_MACRO_DIR([platform/unix/m4])
-AC_CONFIG_SRCDIR([src/love.cpp])
-AM_INIT_AUTOMAKE([foreign -Wall foreign tar-ustar silent-rules])
-AM_SILENT_RULES
-AC_PREFIX_DEFAULT([/usr])
-m4_ifdef([AM_PROG_AR], [AM_PROG_AR])
-LT_INIT([disable-static])
-AC_PROG_CC
-AC_PROG_CXX
-AC_PROG_SED
-AC_PROG_MKDIR_P
-AC_PROG_OBJCXX
-PKG_PROG_PKG_CONFIG
-AC_C_BIGENDIAN
-AC_LANG([C++])
-
-dnl Workaround for old aclocal versions
-m4_include([platform/unix/cpp14.m4])
-m4_include([platform/unix/deps.m4])
-
-includes=
-
-AC_DEFUN([LOVE_MSG_ERROR],
-		 [AC_MSG_ERROR([LÖVE needs "$1"[,] please install "$1" with development files and try again])])
-
-# C++14 support in cpp14.m4
-ACLOVE_CPP14_TEST
-
-# Add -fvisibility=hidden and -fvisibility-inlines-hidden
-CFLAGS="-fvisibility=hidden $CFLAGS"
-CXXFLAGS="-fvisibility=hidden -fvisibility-inlines-hidden $CXXFLAGS"
-
-# --with-lua and --with-luaversion
-AC_ARG_WITH([lua], [AS_HELP_STRING([--with-lua], [Select the lua implementation])],
-	[], [with_lua=luajit])
-AC_ARG_WITH([luaversion], [AS_HELP_STRING([--with-luaversion], [Select the lua version])],
-	[], [with_luaversion=5.1])
-
-with_clean_luaversion=`printf ${with_luaversion} | sed 's/\.//g'`
-
-# Generated sources for enabling/disabling modules
-m4_include([configure-modules-pre.ac])
-
-# Dependencies we always use
-ACLOVE_DEP_LUA
-ACLOVE_DEP_SDL2
-ACLOVE_DEP_LIBM
-ACLOVE_DEP_ZLIB
-ACLOVE_DEP_PTHREAD
-
-# Conditional dependencies
-AS_VAR_IF([enable_module_audio], [yes], [ACLOVE_DEP_OPENAL], [])
-AS_VAR_IF([enable_module_font], [yes], [
-	ACLOVE_DEP_FREETYPE2
-	ACLOVE_DEP_HARFBUZZ
-], [])
-AS_VAR_IF([enable_module_sound], [yes], [
-	ACLOVE_DEP_LIBMODPLUG
-	ACLOVE_DEP_VORBISFILE
-], [])
-AS_VAR_IF([enable_module_video], [yes], [ACLOVE_DEP_THEORA], [])
-
-# Add flags for optional libraries
-AC_ARG_ENABLE([library-enet], [  --disable-library-enet    Turn off library enet], [], [enable_library_enet=yes])
-AC_ARG_ENABLE([library-luasocket], [  --disable-library-luasocket    Turn off library luasocket], [], [enable_library_luasocket=yes])
-AC_ARG_ENABLE([library-lua53], [  --disable-library-lua53    Turn off library lua53 (lua 5.3 backports, required by love.data)], [], [enable_library_lua53=yes])
-AC_ARG_ENABLE([library-luahttps], [  --disable-library-luahttps    Turn off library luahttps], [], [enable_library_luahttps=yes])
-
-# Select the libraries we need to build, based on the selected modules
-AS_VAR_IF([enable_module_filesystem], [yes], [enable_library_physfs=yes], [enable_library_physfs=no])
-AS_VAR_IF([enable_module_physics], [yes], [enable_library_box2d=yes], [enable_library_box2d=no])
-AS_VAR_IF([enable_module_image], [yes], [enable_library_ddsparse=yes], [enable_library_ddsparse=no])
-AS_VAR_IF([enable_module_graphics], [yes], [enable_library_glad=yes], [enable_library_glad=no])
-AS_VAR_IF([enable_module_graphics], [yes], [enable_library_spirv_cross=yes], [enable_library_spirv_cross=no])
-AS_VAR_IF([enable_module_graphics], [yes], [enable_library_glslang=yes], [enable_library_glslang=no])
-AS_VAR_IF([enable_module_image], [yes], [enable_library_lodepng=yes], [enable_library_lodepng=no])
-AS_VAR_IF([enable_module_data], [yes], [enable_library_lua53=yes], [])
-AS_VAR_IF([enable_module_math], [yes], [enable_library_lz4=yes], [enable_library_lz4=no])
-AS_VAR_IF([enable_module_math], [yes], [enable_library_noise1234=yes], [enable_library_noise1234=no])
-AS_VAR_IF([enable_module_image], [yes], [enable_library_stb=yes], [enable_library_stb=no])
-AS_VAR_IF([enable_module_image], [yes], [enable_library_tinyexr=yes], [enable_library_tinyexr=no])
-AS_VAR_IF([enable_module_sound], [yes], [enable_library_Wuff=yes], [enable_library_Wuff=no])
-AS_VAR_IF([enable_module_graphics], [yes], [enable_library_xxHash=yes], [enable_library_xxHash=no])
-
-# Utf8 is required by both graphics and font, so enable if either is enabled
-enable_library_utf8=no
-AS_VAR_IF([enable_module_graphics], [yes], [enable_library_utf8=yes], [])
-AS_VAR_IF([enable_module_font], [yes], [enable_library_utf8=yes], [])
-
-# libenet check for socklen_t
-ACLOVE_SOCKLEN_T
-
-# Generated sources for enabling/disabling modules
-m4_include([configure-modules-post.ac])
-
-# Optionally build the executable (default on)
-AC_ARG_ENABLE([exe],
-			  AC_HELP_STRING([--disable-exe], [Disable building of executable launcher]), [], [enable_exe=yes])
-
-AS_VAR_IF([enable_exe], [no], [], #else
-	  AC_DEFINE([LOVE_BUILD_EXE], [], [Skip building launcher]))
-
-AM_CONDITIONAL([LOVE_BUILD_EXE], [test "x$enable_exe" != xno])
-
-# Automatic script file rebuilding
-AC_CHECK_PROGS([LUA_EXECUTABLE], ["${with_lua}${with_luaversion}" "${with_lua}" "lua"], [:])
-AS_VAR_IF([LUA_EXECUTABLE], [:],
-		  [AC_MSG_WARN([Did not find a lua executable, you may need to update the scripts manually if you change them])], [])
-
-# Set our includes as automake variable
-AC_SUBST([LOVE_INCLUDES], ["$includes"])
-
-AC_CONFIG_FILES([
-	Makefile
-	src/Makefile
-	platform/unix/debian/control
-	platform/unix/debian/changelog
-	platform/unix/debian/rules
-])
-AC_OUTPUT
-
-chmod 755 platform/unix/debian/rules

+ 0 - 68
platform/unix/cpp14.m4

@@ -1,68 +0,0 @@
-AC_DEFUN([ACLOVE_CXX_FLAG_TEST], [ dnl WARNING: NOT REENTRANT
-	aclove_cxx_flag_test_save_cflags="$CXXFLAGS"
-	CXXFLAGS="$1"
-	AC_MSG_CHECKING([whether $CXX supports flag $1])
-	AC_COMPILE_IFELSE([AC_LANG_PROGRAM([])],
-		[AC_MSG_RESULT([yes])]; $2,
-		[AC_MSG_RESULT([no]); $3])
-	CXXFLAGS="$aclove_cxx_flag_test_save_cflags"
-])
-
-AC_DEFUN([ACLOVE_GET_GCC_VERSION], [
-	aclove_gcc_version_found="yes"
-	AC_COMPUTE_INT(aclove_gcc_version_major, __GNUC__,, aclove_gcc_version_found="no")
-	AC_COMPUTE_INT(aclove_gcc_version_minor, __GNUC_MINOR__,, aclove_gcc_version_found="no")
-	AC_COMPUTE_INT(aclove_gcc_version_patch, __GNUC_PATCHLEVEL__,, aclove_gcc_version_found="no")
-])
-
-AC_DEFUN([ACLOVE_GET_CLANG_VERSION], [
-	aclove_clang_version_found="yes"
-	AC_COMPUTE_INT(aclove_clang_version_major, __clang_major__,, aclove_clang_version_found="no")
-	AC_COMPUTE_INT(aclove_clang_version_minor, __clang_minor__,, aclove_clang_version_found="no")
-	AC_COMPUTE_INT(aclove_clang_version_patch, __clang_patchlevel__,, aclove_clang_version_found="no")
-])
-
-AC_DEFUN([ACLOVE_CPP14_TEST_FLAG], [
-	aclove_cpp14_test_cxx14name="no"
-	ACLOVE_CXX_FLAG_TEST([-std=c++14], aclove_cpp14_test_cxx14name="c++14", [])
-	AS_VAR_IF([aclove_cpp14_test_cxx14name], [no],
-		[AC_MSG_ERROR([LÖVE needs a C++ compiler with C++14 support])],
-		[CXXFLAGS="$CXXFLAGS -std=$aclove_cpp14_test_cxx14name"])
-])
-
-AC_DEFUN([ACLOVE_CPP14_CHECK_VERSION], [ dnl compiler, targetmajor, targetminor, on-failure
-	aclove_cpp14_check_version_status="no"
-	AC_MSG_CHECKING([whether $1 version is at least $2.$3])
-	AS_IF([test "$aclove_[]$1[]_version_major" -gt $2], aclove_cpp14_check_version_status="yes")
-	AS_IF([test "$aclove_[]$1[]_version_major" -eq $2 && test "$aclove_[]$1[]_version_minor" -ge $3], aclove_cpp14_check_version_status="yes")
-	AC_MSG_RESULT([$aclove_cpp14_check_version_status])
-	AS_VAR_IF([aclove_cpp14_check_version_status], [no],
-		[$4])
-])
-
-AC_DEFUN([ACLOVE_CPP14_TEST_VERSION_GCC], [
-	ACLOVE_CPP14_CHECK_VERSION([gcc], 4, 9,
-		[AC_MSG_ERROR([LÖVE needs a GCC version of at least 4.9])])
-])
-
-AC_DEFUN([ACLOVE_CPP14_TEST_VERSION_CLANG], [
-	ACLOVE_CPP14_CHECK_VERSION([clang], 3, 4,
-		[AC_MSG_ERROR([LÖVE needs a clang version of at least 3.4])])
-])
-
-AC_DEFUN([ACLOVE_CPP14_TEST], [
-	ACLOVE_CPP14_TEST_FLAG
-
-	ACLOVE_GET_GCC_VERSION
-	ACLOVE_GET_CLANG_VERSION
-
-	# Since clang also sets gcc headers, check clang after
-	aclove_cpp14_test_compiler="unknown"
-	AS_VAR_IF([aclove_gcc_version_found], [yes], aclove_cpp14_test_compiler="gcc")
-	AS_VAR_IF([aclove_clang_version_found], [yes], aclove_cpp14_test_compiler="clang")
-
-	AS_CASE([$aclove_cpp14_test_compiler],
-		[gcc], [ACLOVE_CPP14_TEST_VERSION_GCC],
-		[clang], [ACLOVE_CPP14_TEST_VERSION_CLANG],
-		[AC_MSG_WARN([Could not determine compiler version])])
-])

+ 0 - 77
platform/unix/deps.m4

@@ -1,77 +0,0 @@
-AC_DEFUN([ACLOVE_DEP_FREETYPE2], [
-	PKG_CHECK_MODULES([freetype2], [freetype2], [], [LOVE_MSG_ERROR([FreeType2])])])
-
-AC_DEFUN([ACLOVE_DEP_HARFBUZZ], [
-	PKG_CHECK_MODULES([harfbuzz], [harfbuzz], [], [LOVE_MSG_ERROR([Harfbuzz])])])
-
-AC_DEFUN([ACLOVE_DEP_OPENAL], [
-	PKG_CHECK_MODULES([openal], [openal], [], [LOVE_MSG_ERROR([OpenAL])])])
-
-AC_DEFUN([ACLOVE_DEP_LIBMODPLUG], [
-	PKG_CHECK_MODULES([libmodplug], [libmodplug], [], [LOVE_MSG_ERROR([libmodplug])])])
-
-AC_DEFUN([ACLOVE_DEP_VORBISFILE], [
-	PKG_CHECK_MODULES([vorbisfile], [vorbisfile], [], [LOVE_MSG_ERROR([libvorbis and libvorbisfile])])])
-
-AC_DEFUN([ACLOVE_DEP_ZLIB], [
-	PKG_CHECK_MODULES([zlib], [zlib], [], [LOVE_MSG_ERROR([zlib])])])
-
-AC_DEFUN([ACLOVE_DEP_THEORA], [
-	PKG_CHECK_MODULES([theora], [theoradec], [], [LOVE_MSG_ERROR([libtheora])])])
-
-AC_DEFUN([ACLOVE_DEP_LIBM], [
-	AC_SEARCH_LIBS([sqrt], [m], [], [LOVE_MSG_ERROR([the C math library])])])
-
-AC_DEFUN([ACLOVE_DEP_SDL2], [
-	aclove_sdl2_found=no
-	AM_PATH_SDL2([2.0.9], [aclove_sdl2_found=yes], [])
-	AS_VAR_IF([aclove_sdl2_found], [no], [LOVE_MSG_ERROR([SDL 2])], [])])
-
-AC_DEFUN([ACLOVE_DEP_PTHREAD], [
-	AC_SEARCH_LIBS([pthread_create], [pthread], [], [LOVE_MSG_ERROR([the POSIX threads library])])])
-
-# does not use pkg-config because of the FILE_OFFSET_BITS.. bit
-AC_DEFUN([ACLOVE_DEP_MPG123], [
-	AC_SEARCH_LIBS([mpg123_open_feed], [mpg123], [],
-		[LOVE_MSG_ERROR([libmpg123])])
-	AC_SEARCH_LIBS([mpg123_seek_64], [mpg123],
-		AC_SUBST([FILE_OFFSET],[-D_FILE_OFFSET_BITS=64]),
-		AC_SUBST([FILE_OFFSET],[]))])
-
-# For enet
-AC_DEFUN([ACLOVE_SOCKLEN_T], [
-	AC_CHECK_TYPE([socklen_t], [AC_DEFINE([HAS_SOCKLEN_T], [1], [Define if socklen_t exists.] )], ,
-		#include <sys/types.h>
-		#include <sys/socket.h>
-	)])
-
-# The lua detection is quite annoying because of distro differences and our version selection code
-AC_DEFUN([ACLOVE_DEP_LUA_PKGCONFIG], [
-	PKG_CHECK_MODULES([lua], [${with_lua}${with_luaversion}], [aclove_lua_found=yes],
-		[PKG_CHECK_MODULES([lua], [${with_lua}${with_clean_luaversion}], [aclove_lua_found=yes],
-			[PKG_CHECK_MODULES([lua], [${with_lua}], [aclove_lua_found=yes], [])])])
-
-	AS_VAR_IF([aclove_lua_found], [yes],
-		[
-			aclove_luaheaders_found=yes
-			AC_MSG_CHECKING([for library containing lua_call])
-			AC_MSG_RESULT([${lua_LIBS}])
-		], [])])
-
-AC_DEFUN([ACLOVE_DEP_LUA_FALLBACK], [
-	AC_MSG_WARN([Could not find pkg-config definition for ${with_lua}${with_luaversion} or ${with_lua}${with_clean_luaversion}${with_lua}, falling back to manual detection])
-	AC_SEARCH_LIBS([lua_call], ["${with_lua}${with_luaversion}" "${with_lua}"], [aclove_lua_found=yes],
-		[LOVE_MSG_ERROR([$with_lua])])
-
-	AC_CHECK_HEADER(["${with_lua}${with_luaversion}/lua.h"], [aclove_luaheaders_found=yes includes="$includes -I/usr/include/${with_lua}${with_luaversion}"], [])
-	AC_CHECK_HEADER(["${with_lua}/lua.h"], [aclove_luaheaders_found=yes includes="$includes -I/usr/include/${with_lua}"], [])])
-
-# First, try pkg-config, then fall back to manual detection if not available.
-AC_DEFUN([ACLOVE_DEP_LUA], [ dnl Requires with-lua and with-luaversion
-	aclove_lua_found=no
-	aclove_luaheaders_found=no
-
-	ACLOVE_DEP_LUA_PKGCONFIG
-	AS_VAR_IF([aclove_lua_found], [no], [ACLOVE_DEP_LUA_FALLBACK], [])
-	AS_VAR_IF([aclove_luaheaders_found], [no],
-		[AC_MSG_WARN([Could not locate lua headers for ${with_lua}${with_luaversion} or ${with_lua}, you probably need to specify them with CPPFLAGS])], [])])

+ 0 - 3
platform/unix/exclude

@@ -1,3 +0,0 @@
-\./libraries/luasocket/libluasocket/wsocket.*
-\./love\.cpp
-\./libraries/glslang/glslang/OSDependent/Windows

+ 0 - 150
platform/unix/genmodules

@@ -1,150 +0,0 @@
-#!/bin/bash
-
-love_suffix="$1"
-love_amsuffix="$(echo "$love_suffix" | sed 's/\-/_/g' | sed 's/\./_/g')"
-
-flags=()
-upper()
-{
-	echo "$@" | tr '[:lower:]' '[:upper:]'
-}
-
-sourcefind()
-{
-	find "$1" $2 -type f \( -iname "*.c" -o -iname "*.cpp" -o -iname "*.h" -o -iname "*.hpp" -o -iname "*.lch" -o -iname "*.lua" \) | awk "{print \"./$prefix\"\$0\" \\\\\"}" | grep -v -f"$LOVEROOT/platform/unix/exclude" | sort
-}
-
-handlemodule()
-{
-	module="$1"
-	DEFINENAME="LOVE_MODULE_$(upper "$module")"
-	printf "$DEFINENAME"
-}
-
-genmodules()
-{
-	LOVEROOT="$(pwd)"
-	cd ./src
-
-	printf "liblove${love_amsuffix}_la_SOURCES = \\\\\n"
-	sourcefind "common" | sed "s/^/    /"
-	FILES="$(sourcefind "scripts" | sed "s/^/    /")"
-	printf "${FILES:0:${#FILES}-2}\n\n"
-
-	local -a modulelist=()
-	local -a liblist=()
-
-	cd ./modules
-	prefix="modules/"
-	for module in *; do
-		flags+=("module-$module")
-
-		FILES="$(sourcefind "$module" | sed "s/^/    /")"
-		if [[ "x$FILES" != "x" ]]; then
-			printf "liblove_module_$module = \\\\\n"
-			printf "${FILES:0:${#FILES}-2}\n\n"
-			modulelist+=("$module")
-		fi
-	done
-
-	cd ../libraries
-	prefix="libraries/"
-	for library in *; do
-		flags+=("library-$library")
-		FILES="$(sourcefind "$library" | sed "s/^/    /")"
-
-		if [[ ${#FILES} -gt 2 ]]; then
-			printf "liblove_library_$library = \\\\\n"
-			printf "${FILES:0:${#FILES}-2}\n\n"
-			liblist+=("$library")
-		fi
-	done
-
-	for module in "${modulelist[@]}"; do
-		NAME=$(handlemodule "$module")
-		printf "if $NAME\n"
-		printf "liblove${love_amsuffix}_la_SOURCES += \$(liblove_module_$module)\n"
-		printf "endif\n\n"
-	done
-
-	for library in "${liblist[@]}"; do
-		NAME="LOVE_LIBRARY_$(upper "$library")"
-		printf "if $NAME\n"
-		printf "liblove${love_amsuffix}_la_SOURCES += \$(liblove_library_$library)\n"
-		printf "endif\n\n"
-	done
-
-	cd ../..
-}
-
-genflags()
-{
-	printf > configure-modules-pre.ac
-	printf > configure-modules-post.ac
-	for flag in "${flags[@]}"; do
-		prettyflag="$(echo "$flag" | sed -e 's/-/ love./' -e 's/-/./g')"
-		varflag="enable_$(echo "$flag" | sed -e 's/[^a-zA-Z0-9]/_/')"
-		defineflag="LOVE_ENABLE_$(upper $(echo $flag | sed -e 's/^[^-]*-//' -e 's/-/_/g'))"
-		amflag="$(upper $(echo love-$flag | sed 's/-/_/g'))"
-
-		# Don't generate an --enable rule for libraries
-		if [[ "$(echo $flag | sed -e '/^library-/d')" != "" ]]; then
-			printf "AC_ARG_ENABLE([$flag], [  --disable-$flag    Turn off $prettyflag], [], [$varflag=yes])\n" >> configure-modules-pre.ac
-		fi
-
-		printf "AH_TEMPLATE([$defineflag], [])\n" >> configure-modules-post.ac
-		printf "if test x\"\$$varflag\" = xyes; then\n" >> configure-modules-post.ac
-		printf "    AC_DEFINE([$defineflag], [])\n" >> configure-modules-post.ac
-		printf "fi\n" >> configure-modules-post.ac
-		printf "AM_CONDITIONAL([$amflag], [test x\$$varflag = xyes])\n\n" >> configure-modules-post.ac
-	done
-}
-
-echo Generating src/Makefile.am ...
-inc_current='$(srcdir)'
-inc_modules="$inc_current/modules"
-inc_libraries="$inc_current/libraries"
-
-cat > src/Makefile.am << EOF
-AM_CPPFLAGS = -I$inc_current -I$inc_modules -I$inc_libraries -I$inc_libraries/enet/libenet/include -I$inc_libraries/box2d \$(LOVE_INCLUDES) \$(FILE_OFFSET)\
-	\$(SDL_CFLAGS) \$(lua_CFLAGS) \$(freetype2_CFLAGS) \$(harfbuzz_CFLAGS)\
-	\$(openal_CFLAGS) \$(zlib_CFLAGS) \$(libmodplug_CFLAGS)\
-	\$(vorbisfile_CFLAGS) \$(theora_CFLAGS)
-AUTOMAKE_OPTIONS = subdir-objects
-SUBDIRS =
-SUFFIXES = .lua .lua.h
-
-if LOVE_BUILD_EXE
-# LÖVE executable
-bin_PROGRAMS = love${love_suffix}
-#love_LDFLAGS =
-love${love_amsuffix}_LDADD = liblove${love_suffix}.la \$(lua_LIBS)
-love${love_amsuffix}_SOURCES = love.cpp
-love${love_amsuffix}_LIBTOOLFLAGS = --tag=CXX
-endif
-
-# Compile scripts
-.lua.lua.h:
-	cd ./scripts; \
-	\$(LUA_EXECUTABLE) auto.lua \$<
-
-# libLÖVE
-lib_LTLIBRARIES = liblove${love_suffix}.la
-liblove${love_amsuffix}_la_LDFLAGS = -module -export-dynamic \$(LDFLAGS) -release \$(PACKAGE_VERSION)
-liblove${love_amsuffix}_la_LIBADD = \
-	\$(SDL_LIBS) \$(freetype2_LIBS) \$(harfbuzz_LIBS) \$(lua_LIBS)\
-	\$(openal_LIBS) \$(zlib_LIBS) \$(libmodplug_LIBS)\
-	\$(vorbisfile_LIBS) \$(theora_LIBS)
-
-EOF
-
-genmodules >> src/Makefile.am
-
-echo "src/Makefile.am is updated! ^.^"
-
-echo "Generating configure-modules.ac"
-genflags
-cat >> configure-modules-post.ac << EOF
-AC_SUBST([LOVE_SUFFIX], [${love_suffix}])
-EOF
-echo "configure-modules.ac is updated! ^.^"