[prev in list] [next in list] [prev in thread] [next in thread] 

List:       nsis-commits
Subject:    [NSIS-commits] SF.net SVN: nsis:[6446] NSIS/trunk
From:       anders_k () users ! sourceforge ! net
Date:       2014-03-04 19:26:57
Message-ID: E1WKuzU-0001Cl-49 () sfs-ml-4 ! v29 ! ch3 ! sourceforge ! com
[Download RAW message or body]

Revision: 6446
          http://sourceforge.net/p/nsis/code/6446
Author:   anders_k
Date:     2014-03-04 19:26:56 +0000 (Tue, 04 Mar 2014)
Log Message:
-----------
Don't list /amd64-unicode in !addplugindir help (makensis win32)

Modified Paths:
--------------
    NSIS/trunk/Docs/src/history.but
    NSIS/trunk/Source/build.cpp
    NSIS/trunk/Source/build.h
    NSIS/trunk/Source/script.cpp

Modified: NSIS/trunk/Docs/src/history.but
===================================================================
--- NSIS/trunk/Docs/src/history.but	2014-03-04 19:00:09 UTC (rev 6445)
+++ NSIS/trunk/Docs/src/history.but	2014-03-04 19:26:56 UTC (rev 6446)
@@ -15,6 +15,7 @@
 \S2{} Minor Changes
 
 \b Added Int<32|64|Ptr><Op|Cmp[U]> helper macros to Util.nsh
+
 \b Added P<, P<=, P=, P<>, P>= and P> LogicLib ptrdiff_t tests
 
 \H{v3.0a2} 3.0 Alpha 2

Modified: NSIS/trunk/Source/build.cpp
===================================================================
--- NSIS/trunk/Source/build.cpp	2014-03-04 19:00:09 UTC (rev 6445)
+++ NSIS/trunk/Source/build.cpp	2014-03-04 19:26:56 UTC (rev 6446)
@@ -3703,12 +3703,12 @@
   for(int i = CEXEBuild::TARGETFIRST; i < CEXEBuild::TARGETCOUNT; ++i)
   {
     CEXEBuild::TARGETTYPE tt = (CEXEBuild::TARGETTYPE) i;
-    if (!_tcsicmp(get_target_suffix(tt),s)) return tt;
+    if (!_tcsicmp(get_target_suffix(tt, _T("")),s) && *s) return tt;
   }
   return TARGET_UNKNOWN;
 }
 
-const TCHAR* CEXEBuild::get_target_suffix(CEXEBuild::TARGETTYPE tt) const
+const TCHAR* CEXEBuild::get_target_suffix(CEXEBuild::TARGETTYPE tt, const \
TCHAR*defval) const  {
   switch(tt)
   {
@@ -3717,7 +3717,7 @@
 #if !defined(_WIN32) || defined(_WIN64) // BUGBUG: Need a better define for this
   case TARGET_AMD64     :return _T("amd64-unicode");
 #endif
-  default:return _T("?");
+  default:return defval;
   }
 }
 

Modified: NSIS/trunk/Source/build.h
===================================================================
--- NSIS/trunk/Source/build.h	2014-03-04 19:00:09 UTC (rev 6445)
+++ NSIS/trunk/Source/build.h	2014-03-04 19:26:56 UTC (rev 6446)
@@ -126,7 +126,7 @@
     } TARGETTYPE;
     TARGETTYPE m_target_type;
     TARGETTYPE get_target_type(const TCHAR*s) const;
-    const TCHAR* get_target_suffix(CEXEBuild::TARGETTYPE tt) const;
+    const TCHAR* get_target_suffix(CEXEBuild::TARGETTYPE tt, const TCHAR*defval = \
                _T("?")) const;
     const TCHAR* get_target_suffix() const {return \
                get_target_suffix(m_target_type);}
     bool is_target_64bit() const { return TARGET_AMD64 == m_target_type; }
 

Modified: NSIS/trunk/Source/script.cpp
===================================================================
--- NSIS/trunk/Source/script.cpp	2014-03-04 19:00:09 UTC (rev 6445)
+++ NSIS/trunk/Source/script.cpp	2014-03-04 19:26:56 UTC (rev 6446)
@@ -6234,17 +6234,18 @@
       TCHAR *path = line.gettoken_str(numtok);
       if (2 == numtok)
       {
-        const TCHAR* arcstr = line.gettoken_str(--numtok);
+        const TCHAR *arcstr = line.gettoken_str(--numtok);
         tt = get_target_type(arcstr+1);
         if (_T('/') != arcstr[0] || CEXEBuild::TARGET_UNKNOWN == tt)
         {
           tstring es = get_commandtoken_name(which_token);
           es += _T(": Target parameter must be one of: /");
-          for(int i = CEXEBuild::TARGETFIRST; i < CEXEBuild::TARGETCOUNT; ++i)
+          for(int comma = 0, i = CEXEBuild::TARGETFIRST; i < CEXEBuild::TARGETCOUNT; \
++i)  {
-            tt = (CEXEBuild::TARGETTYPE) i;
-            if (CEXEBuild::TARGETFIRST != tt) es += _T(", /");
-            es += get_target_suffix(tt);
+            const TCHAR *ts = get_target_suffix((CEXEBuild::TARGETTYPE) i, 0);
+            if (!ts) continue;
+            if (comma++) es += _T(", /");
+            es += ts;
           }
           ERROR_MSG(_T("Error: %") NPRIs _T("\n"),es.c_str());
           return PS_ERROR;

This was sent by the SourceForge.net collaborative development platform, the world's \
largest Open Source development site.


------------------------------------------------------------------------------
Subversion Kills Productivity. Get off Subversion & Make the Move to Perforce.
With Perforce, you get hassle-free workflows. Merge that actually works. 
Faster operations. Version large binaries.  Built-in WAN optimization and the
freedom to use Git, Perforce or both. Make the move to Perforce.
http://pubads.g.doubleclick.net/gampad/clk?id=122218951&iu=/4140/ostg.clktrk
_______________________________________________
NSIS-commits mailing list
NSIS-commits@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nsis-commits


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic