Skip to content

Commit

Permalink
Merge branch 'main' into ouruin
Browse files Browse the repository at this point in the history
  • Loading branch information
Timbles committed Jun 2, 2024
2 parents 04caa99 + 15c319a commit ed71089
Show file tree
Hide file tree
Showing 4 changed files with 22 additions and 16 deletions.
18 changes: 10 additions & 8 deletions COMPILING.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,16 +54,18 @@ The following command should install all necessary dependencies to build Overgro

1. Go to the folder of the project
2. Create a build directory ```% mkdir Build```
3. Run cmake to generate Makefiles, include the path to an already installed instance of Overgrowth ```% cmake ../Projects -DAUX_DATA="/path/to/installed/Overgrowth.app/Contents/MacOS"```
4. Run make to build the game ```% make```
5. Run the game by first moving to the project directory ```% cd ..```
6. Then start the game ```% ./Build/Overgrowth.app/Contents/MacOS/Overgrowth```
3. Switch the terminal to the directory you just created. ```% cd Build```
4. Run cmake to generate Makefiles, include the path to an already installed instance of Overgrowth ```% cmake ../Projects -DAUX_DATA="/path/to/installed/Overgrowth.app/Contents/MacOS"```
5. Run make to build the game ```% make```
6. Run the game by first moving to the project directory ```% cd ..```
7. Then start the game ```% ./Build/Overgrowth.app/Contents/MacOS/Overgrowth```

## Linux

1. Go to the folder of the project
2. Create a build directory ```$ mkdir Build```
3. Run cmake to generate Makefiles, include the path to an already installed instance of Overgrowth ```$ cmake ../Projects -DAUX_DATA="/path/to/installed/Overgrowth"```
4. Run make to build the game ```$ make```
5. Run the game by first moving to the project directory ```$ cd ..```
6. Then start the game ```$ Build/Release/Overgrowth.x86_64```
3. Switch the terminal to the directory you just created. ```% cd Build```
4. Run cmake to generate Makefiles, include the path to an already installed instance of Overgrowth ```$ cmake ../Projects -DAUX_DATA="/path/to/installed/Overgrowth"```
5. Run make to build the game ```$ make```
6. Run the game by first moving to the project directory ```$ cd ..```
7. Then start the game ```$ Build/Release/Overgrowth.x86_64```
12 changes: 6 additions & 6 deletions Libraries/binn-3.0/src/binn.c
Original file line number Diff line number Diff line change
Expand Up @@ -704,7 +704,7 @@ BINN_PRIVATE unsigned char * SearchForKey(unsigned char *p, int header_size, int

/***************************************************************************/

BINN_PRIVATE BOOL AddValue(binn *item, int type, void *pvalue, int size);
BINN_PRIVATE BOOL AddValue(binn *item, int type, const void *pvalue, int size);

/***************************************************************************/

Expand All @@ -724,7 +724,7 @@ BINN_PRIVATE BOOL binn_list_add_raw(binn *item, int type, void *pvalue, int size

/***************************************************************************/

BINN_PRIVATE BOOL binn_object_set_raw(binn *item, const char *key, int type, void *pvalue, int size) {
BINN_PRIVATE BOOL binn_object_set_raw(binn *item, const char *key, int type, const void *pvalue, int size) {
unsigned char *p, len;
int int32;

Expand Down Expand Up @@ -909,7 +909,7 @@ BINN_PRIVATE void * compress_int(int *pstorage_type, int *ptype, void *psource)

BINN_PRIVATE int type_family(int type);

BINN_PRIVATE BOOL AddValue(binn *item, int type, void *pvalue, int size) {
BINN_PRIVATE BOOL AddValue(binn *item, int type, const void *pvalue, int size) {
int int32, ArgSize, storage_type, extra_type;
unsigned char *p;

Expand Down Expand Up @@ -2044,7 +2044,7 @@ int APIENTRY binn_get_read_storage(int type) {

/*************************************************************************************/

BINN_PRIVATE BOOL GetWriteConvertedData(int *ptype, void **ppvalue, int *psize) {
BINN_PRIVATE BOOL GetWriteConvertedData(int *ptype, const void **ppvalue, int *psize) {
int type;
float f1;
double d1;
Expand Down Expand Up @@ -2399,7 +2399,7 @@ BINN_PRIVATE BOOL copy_value(void *psource, void *pdest, int source_type, int de
/*** WRITE FUNCTIONS *****************************************************************/
/*************************************************************************************/

BOOL APIENTRY binn_list_add(binn *list, int type, void *pvalue, int size) {
BOOL APIENTRY binn_list_add(binn *list, int type, const void *pvalue, int size) {

if (GetWriteConvertedData(&type, &pvalue, &size) == FALSE) return FALSE;

Expand All @@ -2409,7 +2409,7 @@ BOOL APIENTRY binn_list_add(binn *list, int type, void *pvalue, int size) {

/*************************************************************************************/

BOOL APIENTRY binn_map_set(binn *map, int id, int type, void *pvalue, int size) {
BOOL APIENTRY binn_map_set(binn *map, int id, int type, const void *pvalue, int size) {

if (GetWriteConvertedData(&type, &pvalue, &size) == FALSE) return FALSE;

Expand Down
4 changes: 2 additions & 2 deletions Libraries/binn-3.0/src/binn.h
Original file line number Diff line number Diff line change
Expand Up @@ -292,8 +292,8 @@ BOOL APIENTRY binn_object_set_new(binn *obj, const char *key, binn *value);

// extended interface

BOOL APIENTRY binn_list_add(binn *list, int type, void *pvalue, int size);
BOOL APIENTRY binn_map_set(binn *map, int id, int type, void *pvalue, int size);
BOOL APIENTRY binn_list_add(binn *list, int type, const void *pvalue, int size);
BOOL APIENTRY binn_map_set(binn *map, int id, int type, const void *pvalue, int size);
BOOL APIENTRY binn_object_set(binn *obj, const char *key, int type, const void *pvalue, int size);


Expand Down
4 changes: 4 additions & 0 deletions Projects/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -222,6 +222,10 @@ if(LINUX)
SET(ARCH_OUT "amd64")
SET(TOOL_BIN_NAME "bin64")
set_property(GLOBAL PROPERTY FIND_LIBRARY_USE_LIB64_PATHS ON)

### Ensure LargeFileSupport on 64bit linux
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -D_LARGEFILE64_SOURCE=1")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -D_LARGEFILE64_SOURCE=1")
ELSE()
SET(LIB_SUFFIX "lib")
SET(BIN_SUFFIX ".bin.x86")
Expand Down

0 comments on commit ed71089

Please sign in to comment.