I just tried to build exip using mingw-w64 on win7, without any *nix environment. It worked, but I had to edit the Makefile a bit. Here's the files if anyone else wants to do the same thing.
I used mingw-w64-bin_i686-mingw_20111220.zip and make-3.82.90-20111115.zip.
In pc\build-params.mk:
COMPILER = x86_64-w64-mingw32-gcc
Makefile:
#/*==================================================================*\#| EXIP - Embeddable EXI Processor in C |#|--------------------------------------------------------------------|#| This work is licensed under BSD 3-Clause License |#| The full license terms and conditions are located in LICENSE.txt |#\===================================================================*/##/**# * Makefile for the EXIP library# * @date Oct 8, 2010# * @author Rumen Kyusakov# * @version 0.4# * @par[Revision] $Id: Makefile 219M 2012-11-01 14:13:45Z (local) $# */target?= pc
params?=$(target)/build-params.mk
include $(params)CC=$(COMPILER)CFLAGS+=$(WARNING)CFLAGS+=$(DEBUGGING)CFLAGS+=$(ADDITIONAL_CFLAGS)# Library versionEXIP_VERSION=0.4.1
# The project root directoryPROJECT_ROOT= ..\..
# The src folder of the project SOURCE_DIR=$(PROJECT_ROOT)/src
# The bin folder of the project BIN_DIR=$(PROJECT_ROOT)\bin
# The development documentation folder of the projectDEV_DOC_DIR=$(PROJECT_ROOT)/doc/dev
# Common moduleCOMMON= common
COMMON_SRC=$(SOURCE_DIR)/$(COMMON)# StreamIO moduleSTREAM_IO= streamIO
STREAM_IO_SRC=$(SOURCE_DIR)/$(STREAM_IO)# String Tables moduleSTRING_TABLES= stringTables
STRING_TABLES_SRC=$(SOURCE_DIR)/$(STRING_TABLES)# Grammar moduleGRAMMAR= grammar
GRAMMAR_SRC=$(SOURCE_DIR)/$(GRAMMAR)# ContentIO moduleCONTENT_IO= contentIO
CONTENT_IO_SRC=$(SOURCE_DIR)/$(CONTENT_IO)# GrammarGen moduleGRAMMAR_GEN= grammarGen
GRAMMAR_GEN_SRC=$(SOURCE_DIR)/$(GRAMMAR_GEN)# Unit tests src root directoryTESTS_SRC_DIR=$(PROJECT_ROOT)/tests
# Unit tests test data directoryTESTS_DATA_DIR=$(PROJECT_ROOT)/tests/test-set
# Unit tests bin directoryTESTS_BIN_DIR=$(BIN_DIR)/tests
# Static and dynamic library output directoryLIB_BIN_DIR=$(BIN_DIR)\lib
# Public include directoryPUBLIC_INCLUDE_DIR=$(PROJECT_ROOT)/include
# Compiler include flagsINCDIRS+= -I$(COMMON_SRC)/include
INCDIRS+= -I$(GRAMMAR_SRC)/include
INCDIRS+= -I$(STRING_TABLES_SRC)/include
INCDIRS+= -I$(CONTENT_IO_SRC)/include
INCDIRS+= -I$(STREAM_IO_SRC)/include
INCDIRS+= -I$(GRAMMAR_GEN_SRC)/include
INCDIRS+= -I$(PUBLIC_INCLUDE_DIR)INCDIRS+= -I$(target)LDFLAGS+= -L$(LIB_BIN_DIR)# Used by included Makefiles to compile; hides implementation.COMPILE=$(CC)$(CFLAGS)$(INCDIRS)# Tests all targets by default. May override in environment to specify checks to run, for example:# $make check CHECK_TARGETS="streamio strict_grammar"CHECK_TARGETS?=$(STREAM_IO)$(STRING_TABLES)$(GRAMMAR)$(CONTENT_IO) exip builtin_grammar strict_grammar emptyType
CHECK_BINS:=$(foreach acheck, $(CHECK_TARGETS), $(TESTS_BIN_DIR)/test_$(acheck))# List of all example binary namesEXAMPLE_1= exipd
EXAMPLE_2= exipe
# Examples directoriesEXAMPLES_SRC_DIR=$(PROJECT_ROOT)\examples
EXAMPLES_BIN_DIR=$(BIN_DIR)\examples
# List of all utils binary namesUTILS_1= exipg
# Utils directoriesUTILS_SRC_DIR=$(PROJECT_ROOT)\utils
UTILS_BIN_DIR=$(BIN_DIR)\utils
include common.mkinclude streamIO.mkinclude stringTables.mkinclude grammar.mkinclude contentIO.mkinclude grammarGen.mkinclude tests.mkinclude examples.mkinclude utils.mkOBJECT_ALL=$(COMMON_OBJ)$(STREAM_IO_OBJ)$(STRING_TABLES_OBJ)$(GRAMMAR_OBJ)$(CONTENT_IO_OBJ)ifeq ($(INCLUDE_GRAMMAR_GENERATION), true)OBJECT_ALL+=$(GRAMMAR_GEN_OBJ)endif.PHONY :cleanalllibdynlibcheckexamplesexipdmk_binmk_examplesmk_lib \
mk_testsmk_utilstest_sets_copy_examplesutilstest_sets_copy_utilsdocdistall:mk_bin$(OBJECT_ALL)lib:mk_binmk_lib$(LIB_BIN_DIR)/libexip.a$(LIB_BIN_DIR)/libexip.a:$(OBJECT_ALL)
x86_64-w64-mingw32-ar rcs $(LIB_BIN_DIR)/libexip.a $(OBJECT_ALL)dynlib:COMPILE += -fPICdynlib:cleanallmk_lib$(LIB_BIN_DIR)/libexip.so$(LIB_BIN_DIR)/libexip.so:$(OBJECT_ALL)$(CC) -shared -Wl,-soname,libexip.so.$(EXIP_VERSION) -o $(LIB_BIN_DIR)/libexip.so.$(EXIP_VERSION)$(OBJECT_ALL)
copy $(LIB_BIN_DIR)\libexip.so.$(EXIP_VERSION)$(LIB_BIN_DIR)\libexip.so
check:allmk_tests$(CHECK_BINS)for i in $(CHECK_BINS);do\$$i $(TESTS_DATA_DIR);\doneexamples:mk_exampleslib$(EXAMPLES_BIN_DIR)/$(EXAMPLE_1)$(EXAMPLES_BIN_DIR)/$(EXAMPLE_2)test_sets_copy_examplesutils:mk_utilslib$(UTILS_BIN_DIR)/$(UTILS_1)test_sets_copy_utilsdoc:cd$(DEV_DOC_DIR); doxygen Doxyfile
mk_bin:
-mkdir $(BIN_DIR)mk_lib:
-mkdir $(LIB_BIN_DIR)mk_examples:
-mkdir $(EXAMPLES_BIN_DIR)mk_utils:
-mkdir $(UTILS_BIN_DIR)mk_tests:
-mkdir $(TESTS_BIN_DIR)test_sets_copy_examples:
copy $(EXAMPLES_SRC_DIR)\simpleEncoding\exipe-test-xsd.exi $(EXAMPLES_BIN_DIR)\exipe-test-xsd.exi
copy $(EXAMPLES_SRC_DIR)\simpleDecoding\exipd-test-xsd.exi $(EXAMPLES_BIN_DIR)\exipd-test-xsd.exi
copy $(EXAMPLES_SRC_DIR)\simpleDecoding\exipd-test.exi $(EXAMPLES_BIN_DIR)\exipd-test.exi
copy $(EXAMPLES_SRC_DIR)\simpleDecoding\exipd-test-schema.exi $(EXAMPLES_BIN_DIR)\exipd-test-schema.exi
test_sets_copy_utils:
copy $(UTILS_SRC_DIR)\schemaHandling\EXIOptions-xsd.exi $(UTILS_BIN_DIR)\EXIOptions-xsd.exi
clean:
-rmdir /s /q $(BIN_DIR)# Builds a library distribution/release dist:
rm -f -r $(PROJECT_ROOT)/../../files/exip-$(EXIP_VERSION)
svn export$(PROJECT_ROOT)$(PROJECT_ROOT)/../../files/exip-$(EXIP_VERSION)cd$(PROJECT_ROOT)/../../files && tar cvf - exip-$(EXIP_VERSION)| gzip > exip-$(EXIP_VERSION).tar.gz
cd$(PROJECT_ROOT)/../../files && zip -lvr exip-$(EXIP_VERSION).zip exip-$(EXIP_VERSION)
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hi.
I just tried to build exip using mingw-w64 on win7, without any *nix environment. It worked, but I had to edit the Makefile a bit. Here's the files if anyone else wants to do the same thing.
I used mingw-w64-bin_i686-mingw_20111220.zip and make-3.82.90-20111115.zip.
In pc\build-params.mk:
Makefile: