From d21447d096a320a08b3efb2b8768fad0dcdcfd64 Mon Sep 17 00:00:00 2001 From: Vincent Sanders Date: Thu, 5 May 2016 22:28:51 +0100 Subject: move frontends into sub directory --- frontends/windows/Makefile | 75 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 75 insertions(+) create mode 100644 frontends/windows/Makefile (limited to 'frontends/windows/Makefile') diff --git a/frontends/windows/Makefile b/frontends/windows/Makefile new file mode 100644 index 000000000..a3a95d9da --- /dev/null +++ b/frontends/windows/Makefile @@ -0,0 +1,75 @@ +# +# Makefile for NetSurf Windows target +# +# This file is part of NetSurf + +LDFLAGS += -L${GCCSDK_INSTALL_ENV}/lib +CFLAGS += -I${GCCSDK_INSTALL_ENV}/include/ + + +$(eval $(call pkg_config_find_and_add,libcares,Cares)) +$(eval $(call pkg_config_find_and_add,zlib,ZLib)) + + +LDFLAGS += -lssl -lcrypto -lgnurx -lgdi32 -lcomctl32 -lws2_32 -lmsimg32 -mwindows + +CFLAGS += -U__STRICT_ANSI__ -mwin32 +# only windows versions after XP are supported +CFLAGS += '-DWINVER=0x0501' +CFLAGS += '-D_WIN32_WINNT=0x0501' +CFLAGS += '-D_WIN32_WINDOWS=0x0501' +CFLAGS += '-D_WIN32_IE=0x0501' + +#installed resource path +CFLAGS += '-DNETSURF_WINDOWS_RESPATH="$(NETSURF_WINDOWS_RESPATH)"' + +WSCFLAGS := -std=c99 -DCURL_STATICLIB -DCARES_STATICLIB -g + +CFLAGS += $(WSCFLAGS) +LDFLAGS += $(WSCFLAGS) + +# ---------------------------------------------------------------------------- +# built-in resource setup +# ---------------------------------------------------------------------------- + +$(OBJROOT)/windows_resource.o: $(FRONTEND_RESOURCES_DIR)/resource.rc + $(VQ)echo " WINDRES: compiling windows resources" + ${Q}$(WINDRES) $< -O coff -o $@ + +S_RESOURCES := windows_resource.o + +# ---------------------------------------------------------------------------- +# Source file setup +# ---------------------------------------------------------------------------- + +# sources purely for the windows build +S_FRONTEND := main.c window.c gui.c drawable.c plot.c findfile.c \ + font.c bitmap.c about.c prefs.c download.c filetype.c file.c \ + localhistory.c schedule.c windbg.c pointers.c + +# This is the final source build list +# Note this is deliberately *not* expanded here as common and image +# are not yet available +SOURCES = $(S_COMMON) $(S_IMAGE) $(S_BROWSER) $(S_FRONTEND) $(S_RESOURCES) +EXETARGET := NetSurf.exe + +# ---------------------------------------------------------------------------- +# Install target +# ---------------------------------------------------------------------------- + +install-windows: + +# ---------------------------------------------------------------------------- +# Package target +# ---------------------------------------------------------------------------- + +package-windows: netsurf-installer.exe + +WIN_RES_OBJ := installer.nsi NetSurf.ico netsurf.png welcome.html default.css +WIN_RES_INS_OBJ := $(addprefix $(FRONTEND_RESOURCES_DIR)/,$(WIN_RES_OBJ)) $(OBJROOT)/messages + +$(OBJROOT)/messages: resources/FatMessages + $(Q)$(SPLIT_MESSAGES) -l en -p win -f messages resources/FatMessages > $@ + +netsurf-installer.exe: $(EXETARGET) $(WIN_RES_INS_OBJ) + makensis -V4 -NOCD $(FRONTEND_RESOURCES_DIR)/installer.nsi -- cgit v1.2.3