Permalink
Browse files

Updated WIN_RELEASE target to download the versioned package.

Fixed a few issues when running the unit tests on my osx and windows
installs.
Bumped version number for new release.
  • Loading branch information...
1 parent 983fb3f commit 91b649b9722ded3c7fa9df0e8ba727f22549ce12 @quarnster committed Nov 21, 2012
Showing with 15 additions and 9 deletions.
  1. +3 −1 clang/cindex.py
  2. +3 −3 package.json
  3. +7 −3 src/CMakeLists.txt
  4. +0 −1 sublimeclang.sublime-project
  5. BIN unittests/gold.txt.gz
  6. +2 −1 unittests/unittest.py
View
@@ -1122,7 +1122,9 @@ def get_returned_pointer_level(self, curr=0):
children = self.get_children()
if len(children) == 1 and children[0].kind == CursorKind.TYPE_REF:
ref = children[0].get_reference()
- return ret + ref.get_returned_pointer_level()
+ if ref != self:
+ return ret + ref.get_returned_pointer_level()
+ return ret
if self.kind == CursorKind.TYPEDEF_DECL:
for child in children:
View
@@ -6,12 +6,12 @@
"description": "C/C++/ObjC/ObjC++ autocompletions and code navigation",
"author": "Fredrik Ehnbom (quarnster)",
"homepage": "http://github.com/quarnster/SublimeClang",
- "last_modified": "2012-11-07 10:10:00",
+ "last_modified": "2012-11-21 13:50:00",
"platforms": {
"*": [
{
- "version": "1.0.38",
- "url": "http://cloud.github.com/downloads/quarnster/SublimeClang/SublimeClang-1.0.38.sublime-package"
+ "version": "1.0.39",
+ "url": "http://cloud.github.com/downloads/quarnster/SublimeClang/SublimeClang-1.0.39.sublime-package"
}
]
}
View
@@ -241,13 +241,17 @@ if(${CMAKE_SYSTEM_NAME} MATCHES "Darwin")
endif()
if(DEFINED WIN_RELEASE)
- if(NOT EXISTS ./SublimeClang.sublime-package)
+ file(DOWNLOAD https://raw.github.com/quarnster/SublimeClang/master/package.json ${PROJECT_BINARY_DIR}/current.json LOG log)
+ file(READ "${PROJECT_BINARY_DIR}/current.json" TEMP)
+ string(REGEX MATCH "\"url\": \"(.*/(.*))\"" TEMP ${TEMP})
+
+ if(NOT EXISTS ${PROJECT_BINARY_DIR}/${CMAKE_MATCH_2})
message("Downloading current SublimeClang release...")
- file(DOWNLOAD http://cloud.github.com/downloads/quarnster/SublimeClang/SublimeClang.sublime-package ./SublimeClang.sublime-package)
+ file(DOWNLOAD ${CMAKE_MATCH_1} ${PROJECT_BINARY_DIR}/${CMAKE_MATCH_2})
endif()
add_custom_command(OUTPUT ${PROJECT_BINARY_DIR}/source
COMMAND ${CMAKE_COMMAND} -E make_directory source
- COMMAND ${CMAKE_COMMAND} -E chdir source ${CMAKE_COMMAND} -E tar xf ../SublimeClang.sublime-package
+ COMMAND ${CMAKE_COMMAND} -E chdir source ${CMAKE_COMMAND} -E tar xf ${PROJECT_BINARY_DIR}/${CMAKE_MATCH_2}
COMMAND ${CMAKE_COMMAND} -E copy_if_different source/libclang.dll ${PROJECT_SOURCE_DIR}/../libclang.dll
COMMAND ${CMAKE_COMMAND} -E copy_if_different source/libclang_x64.dll ${PROJECT_SOURCE_DIR}/../libclang_x64.dll
WORKING_DIRECTORY ${PROJECT_BINARY_DIR}
@@ -47,7 +47,6 @@
"-DSUBLIMECLANG_VERSION=\"1.0\"",
"-DSUBLIMECLANG_USE_TR1",
"-isystem", "/",
- "-isystem", "/usr/lib/c++/v1",
"-Wall"
]
}
View
Binary file not shown.
View
@@ -236,7 +236,8 @@ def read_file(filename):
f.close()
return data
-opts.extend(json.loads(read_file("sublimeclang.sublime-project"))["settings"]["sublimeclang_options"])
+if platform.system() != "Windows":
+ opts.extend(json.loads(read_file("sublimeclang.sublime-project"))["settings"]["sublimeclang_options"])
if goto_def:
tu = get_tu("src/main.cpp")

0 comments on commit 91b649b

Please sign in to comment.