View Issue Details

IDProjectCategoryView StatusLast Update
0000665Other Unix PortBugpublic2016-01-24 01:40
ReporterkomhAssigned To 
PrioritynormalSeverityminorReproducibilityalways
Status newResolutionopen 
Summary0000665: CMake: cmake fails if not set MAKESHELL=sh.exe
DescriptionHi/2.

CMake generated Makefiles assume that sh.exe will be used. So, if some env vars such as MAKESHELL is not set to sh.exe, CMake testing fails.

I attach a patch.

Review, please...
TagsNo tags attached.

Activities

komh

2016-01-23 19:18

reporter  

0001-Use-sh.exe-as-the-shell-in-which-to-execute-make-rul.patch (998 bytes)
From b5adfb142646f0612295735adfdf4187a90cb18f Mon Sep 17 00:00:00 2001
From: KO Myung-Hun <komh@chollian.net>
Date: Thu, 21 Jan 2016 21:46:54 +0900
Subject: [PATCH] Use sh.exe as the shell in which to execute make rules

OS/2 Make use CMD.EXE by default.

    modified:   Source/cmLocalUnixMakefileGenerator3.cxx
---
 Source/cmLocalUnixMakefileGenerator3.cxx | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/Source/cmLocalUnixMakefileGenerator3.cxx b/Source/cmLocalUnixMakefileGenerator3.cxx
index 4cacaa9..566a80e 100644
--- a/Source/cmLocalUnixMakefileGenerator3.cxx
+++ b/Source/cmLocalUnixMakefileGenerator3.cxx
@@ -723,10 +723,14 @@ cmLocalUnixMakefileGenerator3
     }
   else
     {
-#if !defined(__VMS) && !defined(__OS2__)
+#if !defined(__VMS)
       makefileStream
         << "# The shell in which to execute make rules.\n"
+#ifndef __OS2__
         << "SHELL = /bin/sh\n"
+#else
+        << "SHELL = sh.exe\n"
+#endif
         << "\n";
 #endif
     }
-- 
2.7.0

gianfli

2016-01-23 20:24

reporter   ~0003099

Last edited: 2016-01-23 21:14

View 6 revisions

Yes, discovered porting vidalia, since that, always used a little rexx script to set more comfortable statements before generate/make using cmake.
I suggest also to switch object extensions to .o, instead of .obj, wich is the default for linux and our gcc and this make cmake more usable with both netlabs dllar and the Ko's one ;).
Now we should try to automatically generate short filenames building shared libs using cmake.
Well done ;) !

komh

2016-01-24 01:40

reporter   ~0003101

See .o for http://mantis.smedley.id.au/view.php?id=666

See short dll name for http://mantis.smedley.id.au/view.php?id=600

Issue History

Date Modified Username Field Change
2016-01-23 19:18 komh New Issue
2016-01-23 19:18 komh File Added: 0001-Use-sh.exe-as-the-shell-in-which-to-execute-make-rul.patch
2016-01-23 20:24 gianfli Note Added: 0003099
2016-01-23 20:26 gianfli Note Edited: 0003099 View Revisions
2016-01-23 20:34 gianfli Note Edited: 0003099 View Revisions
2016-01-23 20:41 gianfli Note Edited: 0003099 View Revisions
2016-01-23 20:49 gianfli Note Edited: 0003099 View Revisions
2016-01-23 21:14 gianfli Note Edited: 0003099 View Revisions
2016-01-24 01:40 komh Note Added: 0003101