#
# This makefile for GCC will be generate next files:
#
# ..\bin\vncserver.exe
#

# Name for binary (without path and extension)
NAME = vncserver

# Uncomment next line to make debug version
# DEBUGCODE = YES

# Binary file extension (dll/exe)
EXT = exe

VERSION = 0.1.12
DESCRIPTION = VNC Server

# Compilation flags for ../common/utils.c
UTILS_CFLAGS = -DUTILS_WITH_OPENSSL

# Sources
SRCS = main.c rfbsrv.c config.c gui.c configdlg.c avdlg.c log.c clientsdlg.c \
       utils.c ..\common\conv.c ..\common\chatwin.c

# Libraries (-Lpath -lname ...)
LIBS = -L../libvncserver -L../os2xkey -L../libgiconv \
       -los2xkey -lvncserver -llibgiconv -llibcrypto -llibssl -lz -ljpeg \
       -lpng1616_dll

CFLAGS = -DVERSION=\"$(VERSION)\" -D_DIGI

include ../common/makefile.begin


$(FILE_BIN): $(OBJS) $(FILE_DEF) $(FILE_RES) ../libvncserver/vncserver.a
	$(CC) $(FILE_DEF) $(LDFLAGS)
	$(LXLITE)
	$(RC) $(RCLFLAGS)

$(FILE_DEF):
ifneq ($(DEBUGCODE),YES)
	@echo NAME $(NAME) windowapi >$@
endif
	@cmd /c %unixroot%\\usr\\libexec\\bin\\date +"DESCRIPTION '@#Andrey Vasilkin:$(VERSION)#@##1## %F               %HOSTNAME%::::::@@$(DESCRIPTION)'" >>$@


include ../common/makefile.end
