Changeset 536 for CMT/HEAD/source
- Timestamp:
- Mar 26, 2010, 5:36:41 PM (15 years ago)
- Location:
- CMT/HEAD/source
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
CMT/HEAD/source/cmt_parser.cxx
r535 r536 7116 7116 else if (Me.m_current_package != "") 7117 7117 { 7118 if (!use.move_to ()) 7118 if (!use.move_to () && !use.move_to ("", true)) 7119 // if (!use.move_to ()) 7119 7120 { 7120 7121 CmtError::set (CmtError::package_not_found, -
CMT/HEAD/source/cmt_project.cxx
r535 r536 2243 2243 use->get_package ()->remove_use (use); 2244 2244 CmtSystem::cd (m_cmtpath_pwd); 2245 if (use->move_to ()) 2246 { 2247 cmt_string use_real; 2248 bool ok (false); 2249 if (!CmtSystem::absolute_path (use->path)) 2250 { 2251 ok = CmtSystem::realpath_ (use->real_path, use_real); 2252 } 2253 else 2254 { 2255 ok = CmtSystem::realpath_ (use->path, use_real); 2256 } 2257 if (ok && use_real.find (m_cmtpath_real) != 0) 2258 { 2259 use->~Use (); 2260 } 2261 else if (!CmtSystem::absolute_path (use->real_path)) 2262 { 2263 use->change_path (m_cmtpath_pwd); 2264 } 2245 if (use->move_to ("", true) && 2246 !CmtSystem::absolute_path (use->real_path)) 2247 { 2248 use->change_path (m_cmtpath_pwd); 2265 2249 } 2266 2250 CmtSystem::cd (m_cmtpath_pwd + CmtSystem::file_separator () + "cmt"); 2267 2251 } 2268 // cerr << CmtSystem::pwd () << endl;2269 2252 2270 2253 set_container_name (name); -
CMT/HEAD/source/cmt_use.cxx
r535 r536 1903 1903 1904 1904 //---------------------------------------------------------- 1905 bool Use::move_to (const cmt_string& native_version) 1905 bool Use::move_to (const cmt_string& native_version, bool curdir) 1906 //bool Use::move_to (const cmt_string& native_version) 1906 1907 { 1907 1908 if (m_located) … … 1924 1925 cmt_string expanded_path = path; 1925 1926 1927 if (curdir) 1928 { 1926 1929 // 1927 1930 // Try here. 1928 1931 // 1929 if (expanded_path == "") 1930 { 1931 if (reach_package ("", native_version)) 1932 // if (expanded_path == "") 1933 // { 1934 // if (reach_package ("", native_version)) 1935 cmt_string here = CmtSystem::pwd (); 1936 if (reach_package (here, native_version)) 1932 1937 { 1933 1938 if (Cmt::get_debug ()) … … 1936 1941 } 1937 1942 1938 change_path ( expanded_path);1943 change_path (here); 1939 1944 1940 1945 return (true); … … 1952 1957 } 1953 1958 } 1954 } 1955 1959 // } 1960 } // end of curdir 1961 1956 1962 // 1957 1963 // If the path specified in this use is a true absolute path, … … 1984 1990 } 1985 1991 } 1992 if (curdir) return (false); 1986 1993 1987 1994 // -
CMT/HEAD/source/cmt_use.h
r535 r536 89 89 void author_action (const CmtSystem::cmt_string_vector& words); 90 90 void manager_action (const CmtSystem::cmt_string_vector& words); 91 bool move_to (const cmt_string& native_version=""); 91 bool move_to (const cmt_string& native_version="", bool curdir = false); 92 // bool move_to (const cmt_string& native_version=""); 92 93 void discard (); 93 94 void undiscard ();
Note: See TracChangeset
for help on using the changeset viewer.