Compare commits

...

2 commits

Author SHA1 Message Date
09cfe6cee9 Fix compiler warnings.
Signed-off-by: yzrh <yzrh@noema.org>
2023-01-09 15:18:37 +00:00
471a8b42d2 Update Makefile
Signed-off-by: yzrh <yzrh@noema.org>
2022-12-19 23:18:43 +00:00
4 changed files with 24 additions and 16 deletions

View file

@ -1,3 +1,8 @@
0.6.2_7 (2022-12-19)
====================
* Update Makefile.
0.6.2_6 (2020-12-30) 0.6.2_6 (2020-12-30)
==================== ====================

View file

@ -1,5 +1,5 @@
# #
# Copyright (c) 2019-2021, yzrh <yzrh@noema.org> # Copyright (c) 2019-2023, yzrh <yzrh@noema.org>
# #
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
# #
@ -18,8 +18,8 @@ obj = ${src:.c=.o}
PREFIX = /usr/local PREFIX = /usr/local
CFLAGS = -O3 -march=native -pipe -flto -Wall -Wextra -Wno-unused-result -Wno-unused-parameter CFLAGS = -O2 -pipe -flto -Wall -Wextra -Wno-unused-parameter
LDFLAGS = -Wl,-O3 -lpthread -lSDL2 -lSDL2_ttf LDFLAGS = -Wl,-O2 -lpthread -lSDL2 -lSDL2_ttf
.ifdef SOUND .ifdef SOUND

View file

@ -1,5 +1,5 @@
/* /*
* Copyright (c) 2019-2021, yzrh <yzrh@noema.org> * Copyright (c) 2019-2023, yzrh <yzrh@noema.org>
* *
* SPDX-License-Identifier: Apache-2.0 * SPDX-License-Identifier: Apache-2.0
*/ */
@ -108,19 +108,22 @@ static void*
handler_rendering(void *args) handler_rendering(void *args)
{ {
const SDL_Color fg = { const SDL_Color fg = {
COLOUR_FOREGROUND_R, .r = COLOUR_FOREGROUND_R,
COLOUR_FOREGROUND_G, .g = COLOUR_FOREGROUND_G,
COLOUR_FOREGROUND_B .b = COLOUR_FOREGROUND_B,
.a = 255
}; };
const SDL_Color bg = { const SDL_Color bg = {
COLOUR_BACKGROUND_R, .r = COLOUR_BACKGROUND_R,
COLOUR_BACKGROUND_G, .g = COLOUR_BACKGROUND_G,
COLOUR_BACKGROUND_B .b = COLOUR_BACKGROUND_B,
.a = 255
}; };
const SDL_Color bg_s = { const SDL_Color bg_s = {
COLOUR_BACKGROUND_SHADE_R, .r = COLOUR_BACKGROUND_SHADE_R,
COLOUR_BACKGROUND_SHADE_G, .g = COLOUR_BACKGROUND_SHADE_G,
COLOUR_BACKGROUND_SHADE_B .b = COLOUR_BACKGROUND_SHADE_B,
.a = 255
}; };
char result_str[23]; char result_str[23];
@ -941,7 +944,7 @@ int
main(void) main(void)
{ {
printf("Snake " VERSION "." RELEASE "." PATCH EXTRA "\n" printf("Snake " VERSION "." RELEASE "." PATCH EXTRA "\n"
"Copyright (c) 2019-2021, yzrh <yzrh@noema.org>\n"); "Copyright (c) 2019-2022, yzrh <yzrh@noema.org>\n");
if (SDL_Init(SDL_INIT_VIDEO | if (SDL_Init(SDL_INIT_VIDEO |
SDL_INIT_AUDIO | SDL_INIT_AUDIO |

View file

@ -1,5 +1,5 @@
/* /*
* Copyright (c) 2019-2021, yzrh <yzrh@noema.org> * Copyright (c) 2019-2022, yzrh <yzrh@noema.org>
* *
* SPDX-License-Identifier: Apache-2.0 * SPDX-License-Identifier: Apache-2.0
*/ */
@ -7,4 +7,4 @@
#define VERSION "0" #define VERSION "0"
#define RELEASE "6" #define RELEASE "6"
#define PATCH "2" #define PATCH "2"
#define EXTRA "_6" #define EXTRA "_7"