Browse Source

Merge branch 'master' into 12.0

Alex Szpakowski 5 years ago
parent
commit
7684920f19

+ 5 - 0
.gitattributes

@@ -0,0 +1,5 @@
+.git* export-ignore
+.hg* export-ignore
+*.c diff=cpp
+*.cpp diff=cpp
+*.h diff=cpp

+ 1 - 1
.github/workflows/main.yml

@@ -43,7 +43,7 @@ jobs:
       run: cmake -Bbuild -Hmegasource -T v142 -A %PLATFORM% -DCMAKE_INSTALL_PREFIX=%CD%\install
       run: cmake -Bbuild -Hmegasource -T v142 -A %PLATFORM% -DCMAKE_INSTALL_PREFIX=%CD%\install
     - name: Install
     - name: Install
       shell: cmd
       shell: cmd
-      run: cmake --build build --config Release --target install
+      run: cmake --build build --config Release --target install -j2
     - name: Artifact
     - name: Artifact
       uses: actions/upload-artifact@v1
       uses: actions/upload-artifact@v1
       with:
       with:

+ 11 - 2
CMakeLists.txt

@@ -24,7 +24,9 @@
 #include <stdlib.h>
 #include <stdlib.h>
 
 
 #ifdef LOVE_WINDOWS
 #ifdef LOVE_WINDOWS
+#define WIN32_LEAN_AND_MEAN
 #include <malloc.h>
 #include <malloc.h>
+#include <Windows.h>
 #else
 #else
 #include <unistd.h> // Assume POSIX support.
 #include <unistd.h> // Assume POSIX support.
 #endif
 #endif
@@ -54,8 +56,15 @@ void alignedFree(void *mem)
 size_t getPageSize()
 size_t getPageSize()
 {
 {
 #ifdef LOVE_WINDOWS
 #ifdef LOVE_WINDOWS
-	// TODO: Do an actual query.
-	return 4096;
+	static DWORD size = 0;
+	if (size == 0)
+	{
+		SYSTEM_INFO si;
+		GetSystemInfo(&si);
+		size = si.dwPageSize;
+	}
+
+	return (size_t) size;
 #else
 #else
 	static const long size = sysconf(_SC_PAGESIZE);
 	static const long size = sysconf(_SC_PAGESIZE);
 	return size > 0 ? (size_t) size : 4096;
 	return size > 0 ? (size_t) size : 4096;

File diff suppressed because it is too large
+ 366 - 172
src/libraries/dr_flac/dr_flac.h


+ 1 - 1
src/libraries/glslang/glslang/MachineIndependent/preprocessor/Pp.cpp

@@ -1,6 +1,6 @@
 # luasocket src/makefile
 # luasocket src/makefile
 #
 #
-# Definitions in this section can be overriden on the command line or in the
+# Definitions in this section can be overridden on the command line or in the
 # environment.
 # environment.
 #
 #
 # These are equivalent:
 # These are equivalent:

+ 1 - 1
src/libraries/luasocket/libluasocket/smtp.lua

@@ -219,7 +219,7 @@ function send_message(mesgt)
     else send_string(mesgt) end
     else send_string(mesgt) end
 end
 end
 
 
--- set defaul headers
+-- set default headers
 local function adjust_headers(mesgt)
 local function adjust_headers(mesgt)
     local lower = lower_headers(mesgt.headers)
     local lower = lower_headers(mesgt.headers)
     lower["date"] = lower["date"] or
     lower["date"] = lower["date"] or

+ 2 - 3
src/libraries/lz4/lz4.c

@@ -34,7 +34,7 @@ namespace lullaby
 FLACDecoder::FLACDecoder(Data *data, int nbufferSize)
 FLACDecoder::FLACDecoder(Data *data, int nbufferSize)
 : Decoder(data, nbufferSize)
 : Decoder(data, nbufferSize)
 {
 {
-	flac = drflac_open_memory(data->getData(), data->getSize());
+	flac = drflac_open_memory(data->getData(), data->getSize(), nullptr);
 	if (flac == nullptr)
 	if (flac == nullptr)
 		throw love::Exception("Could not load FLAC file");
 		throw love::Exception("Could not load FLAC file");
 }
 }
@@ -52,7 +52,7 @@ bool FLACDecoder::accepts(const std::string &ext)
 	// Please remove once it's no longer the case.
 	// Please remove once it's no longer the case.
 	static const std::string supported[] =
 	static const std::string supported[] =
 	{
 	{
-		"flac", "ogg"
+		"flac", "ogg", ""
 	};
 	};
 
 
 	for (int i = 0; !(supported[i].empty()); i++)
 	for (int i = 0; !(supported[i].empty()); i++)
@@ -125,4 +125,3 @@ double FLACDecoder::getDuration()
 } // lullaby
 } // lullaby
 } // sound
 } // sound
 } // love
 } // love
-

Some files were not shown because too many files changed in this diff