Skip to content

Commit

Permalink
Build Windows SDL target with icon.
Browse files Browse the repository at this point in the history
  • Loading branch information
indigoparadox committed Dec 23, 2023
1 parent ac9e651 commit 77ae60b
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 0 deletions.
15 changes: 15 additions & 0 deletions make/Makeico.inc
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,21 @@ $$(OBJDIR_WATCOM386_WIN_GLUT)/$(1).rc: $$(OBJDIR_WATCOM386_WIN_GLUT)/$(1).ico
$$(OBJDIR_WATCOM386_WIN_GLUT)/$(1).res: $$(OBJDIR_WATCOM386_WIN_GLUT)/$(1).rc
wrc -r $$< -bt=nt -fo=$$@

# Watcom-Win-SDL

# Don't use MAUG_DEPS since these have to be passed directly to the compiler.
RES_WATCOM386_WIN_SDL_DEP=$$(OBJDIR_WATCOM386_WIN_SDL)/$(1).res
RES_WATCOM386_WIN_SDL=resource {$$(RES_WATCOM386_WIN_SDL_DEP)}

$$(OBJDIR_WATCOM386_WIN_SDL)/$(1).ico: $(1).bmp
convert "$$<" "$$@"

$$(OBJDIR_WATCOM386_WIN_SDL)/$(1).rc: $$(OBJDIR_WATCOM386_WIN_SDL)/$(1).ico
echo "$$(WIN_ICO_RES_ID) ICON \"$$(OBJDIR_WATCOM386_WIN_SDL)/$(1).ico\"" > $$@

$$(OBJDIR_WATCOM386_WIN_SDL)/$(1).res: $$(OBJDIR_WATCOM386_WIN_SDL)/$(1).rc
wrc -r $$< -bt=nt -fo=$$@

# Watcom-Win-Win16

RES_WATCOM_WIN_WIN16_DEP=$$(OBJDIR_WATCOM_WIN_WIN16)/$(1).res
Expand Down
3 changes: 3 additions & 0 deletions src/retroflt.h
Original file line number Diff line number Diff line change
Expand Up @@ -3615,6 +3615,9 @@ int retroflat_init( int argc, char* argv[], struct RETROFLAT_ARGS* args ) {
info = SDL_GetVideoInfo();
maug_cleanup_if_null_alloc( SDL_VideoInfo*, info );

debug_printf( 3, "maximum window size: %ux%u",
info->current_w, info->current_h );

/* Setup default screen position. */
if( 0 == args->screen_x ) {
/* Get screen width so we can center! */
Expand Down

0 comments on commit 77ae60b

Please sign in to comment.