aboutsummaryrefslogtreecommitdiff
path: root/tools/mhmake
diff options
context:
space:
mode:
Diffstat (limited to 'tools/mhmake')
-rw-r--r--tools/mhmake/src/mhmakefileparser.cpp3
-rw-r--r--tools/mhmake/src/util.cpp14
-rw-r--r--tools/mhmake/src/util.h2
3 files changed, 18 insertions, 1 deletions
diff --git a/tools/mhmake/src/mhmakefileparser.cpp b/tools/mhmake/src/mhmakefileparser.cpp
index de7b22da3..d5d2980f8 100644
--- a/tools/mhmake/src/mhmakefileparser.cpp
+++ b/tools/mhmake/src/mhmakefileparser.cpp
@@ -520,7 +520,10 @@ void mhmakefileparser::GetAutoDeps(const refptr<fileinfo> &FirstDep,set< refptr<
else if (Ret=='#' || Ret=='.')
{
if (Ret=='#')
+ {
+ fscanf(pIn,"%*[ \t]");
Ret=fscanf(pIn,"include %1[\"<]%254[^>\"]%*[\">]",&Type,IncludeList);
+ }
else
Ret=fscanf(pIn,"import %1[\"<]%254[^>\"]%*[\">]",&Type,IncludeList);
if (Ret==2)
diff --git a/tools/mhmake/src/util.cpp b/tools/mhmake/src/util.cpp
index 9fc03ddad..a6ce9e8bf 100644
--- a/tools/mhmake/src/util.cpp
+++ b/tools/mhmake/src/util.cpp
@@ -276,7 +276,21 @@ loadedmakefile::loadedmakefile_statics::loadedmakefile_statics()
try
{
string SvnCommand=SearchCommand("svn",EXEEXT);
+ #ifdef WIN32
Ret=OsExeCommand(SvnCommand,string(" info ")+m_MhMakeConf->GetQuotedFullFileName(),false,&Output);
+ #else
+ struct stat Stat;
+ lstat(m_MhMakeConf->GetFullFileName().c_str(),&Stat);
+ if (S_ISLNK(Stat.st_mode))
+ {
+ char FileName[1024];
+ int len=readlink(m_MhMakeConf->GetFullFileName().c_str(),FileName,sizeof(FileName));
+ FileName[len]=0;
+ Ret=OsExeCommand(SvnCommand,string(" info ")+GetFileInfo(FileName,m_MhMakeConf->GetDir())->GetQuotedFullFileName(),false,&Output);
+ }
+ else
+ Ret=OsExeCommand(SvnCommand,string(" info ")+m_MhMakeConf->GetQuotedFullFileName(),false,&Output);
+ #endif
}
catch (string Message)
{
diff --git a/tools/mhmake/src/util.h b/tools/mhmake/src/util.h
index 23f26e0ad..4c5528452 100644
--- a/tools/mhmake/src/util.h
+++ b/tools/mhmake/src/util.h
@@ -50,7 +50,7 @@
#define PLATFORM "linux"
#endif
-#define MHMAKEVER "1.4.11"
+#define MHMAKEVER "1.4.13"
string SearchCommand(const string &Command, const string &Extension="");