From 617be983b9d9afd67dd1752f3331f02a4450361e Mon Sep 17 00:00:00 2001 From: Hans Erik van Elburg Date: Sat, 3 Jan 2015 02:27:27 +0100 Subject: initial cygwin tweaks --- acprep | 3 +++ 1 file changed, 3 insertions(+) (limited to 'acprep') diff --git a/acprep b/acprep index b0af2108..63cabe6b 100755 --- a/acprep +++ b/acprep @@ -644,6 +644,9 @@ class PrepareBuild(CommandLineApp): ] self.log.info('Executing: ' + ' '.join(packages)) self.execute(*packages) + elif system.startswith('CYGWIN'): + self.log.info('Looks like you are using Cygwin') + self.log.info('Please install the dependencies manually, see https://github.com/ledger/ledger/wiki/Build-instructions-for-Cygwin.') ######################################################################### # Determine the system's basic configuration # -- cgit v1.2.3 From 93c55c5ec6db6bce3173204f6a62ab5b2b8afde1 Mon Sep 17 00:00:00 2001 From: Hans Erik van Elburg Date: Sat, 3 Jan 2015 23:35:39 +0100 Subject: also added cygwin tweak to src/CMakeLists.txt --- acprep | 8 +++++++- src/CMakeLists.txt | 14 ++++++++++++-- 2 files changed, 19 insertions(+), 3 deletions(-) (limited to 'acprep') diff --git a/acprep b/acprep index 63cabe6b..6dd0f911 100755 --- a/acprep +++ b/acprep @@ -685,7 +685,10 @@ class PrepareBuild(CommandLineApp): if self.options.python: self.configure_args.append('-DUSE_PYTHON=1') - if self.options.use_ninja: + if system.startswith('CYGWIN'): + self.configure_args.append('-G') + self.configure_args.append('Unix Makefiles') + elif self.options.use_ninja: self.configure_args.append('-GNinja') if exists('/Users/johnw/Projects/ledger/plan/TODO'): @@ -819,6 +822,9 @@ class PrepareBuild(CommandLineApp): if self.prefix_directory(): conf_args.append('-DCMAKE_INSTALL_PREFIX=%s' % self.prefix_directory()) + if self.is_cygwin: + + return (environ, conf_args + self.configure_args) def phase_configure(self, *args): diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index aec75c06..dcafeba2 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -167,7 +167,12 @@ if (CMAKE_BUILD_TYPE STREQUAL "Debug") if (BUILD_LIBRARY) list(APPEND _args ${CMAKE_SHARED_LIBRARY_CXX_FLAGS}) endif() - list(APPEND _args "-std=c++11 ") + if (CYGWIN) + list(APPEND _args "-std=c++11 ") + list(APPEND _args "-U__STRICT_ANSI__") + else() + list(APPEND _args "-std=c++11 ") + endif() list(APPEND _args "-x c++-header " ${_inc}) list(APPEND _args -c ${_header_filename} -o ${_pch_filename}) @@ -223,7 +228,12 @@ if (CMAKE_BUILD_TYPE STREQUAL "Debug") list(APPEND _args ${CMAKE_SHARED_LIBRARY_CXX_FLAGS}) endif() list(APPEND _args ${GXX_WARNING_FLAGS}) - list(APPEND _args "-std=c++11 ") + if (CYGWIN) + list(APPEND _args "-std=c++11 ") + list(APPEND _args "-U__STRICT_ANSI__") + else() + list(APPEND _args "-std=c++11 ") + endif() list(APPEND _args "-x c++-header " ${_inc}) list(APPEND _args -c ${_header_filename} -o ${_gch_filename}) -- cgit v1.2.3 From 6644d3c6412d7ff0b0d8b20c30195b932e4fde2d Mon Sep 17 00:00:00 2001 From: Hans Erik van Elburg Date: Sun, 4 Jan 2015 00:02:49 +0100 Subject: remove reference to url --- acprep | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'acprep') diff --git a/acprep b/acprep index 6dd0f911..6336e902 100755 --- a/acprep +++ b/acprep @@ -646,7 +646,7 @@ class PrepareBuild(CommandLineApp): self.execute(*packages) elif system.startswith('CYGWIN'): self.log.info('Looks like you are using Cygwin') - self.log.info('Please install the dependencies manually, see https://github.com/ledger/ledger/wiki/Build-instructions-for-Cygwin.') + self.log.info('Please install the dependencies manually.') ######################################################################### # Determine the system's basic configuration # -- cgit v1.2.3 From ea397d205c84d01b8089e8fac0dd30e9100d1571 Mon Sep 17 00:00:00 2001 From: Hans Erik van Elburg Date: Sun, 4 Jan 2015 00:10:55 +0100 Subject: remove unnecessary if artifact --- acprep | 3 --- 1 file changed, 3 deletions(-) (limited to 'acprep') diff --git a/acprep b/acprep index 6336e902..9e661aad 100755 --- a/acprep +++ b/acprep @@ -822,9 +822,6 @@ class PrepareBuild(CommandLineApp): if self.prefix_directory(): conf_args.append('-DCMAKE_INSTALL_PREFIX=%s' % self.prefix_directory()) - if self.is_cygwin: - - return (environ, conf_args + self.configure_args) def phase_configure(self, *args): -- cgit v1.2.3