Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
R
robotpkg-wip
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Gepetto
robotpkg-wip
Commits
9a647efa
Commit
9a647efa
authored
13 years ago
by
Arnaud Degroote
Browse files
Options
Downloads
Patches
Plain Diff
[wip/MPC] Add a patch to fix incorrect use of substring on cmake < 2.8
parent
740cb90f
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
MPC/distinfo
+1
-0
1 addition, 0 deletions
MPC/distinfo
MPC/patches/patch-ab
+19
-0
19 additions, 0 deletions
MPC/patches/patch-ab
with
20 additions
and
0 deletions
MPC/distinfo
+
1
−
0
View file @
9a647efa
...
...
@@ -2,3 +2,4 @@ SHA1 (MPC-1.0.tar.gz) = a45fe2e16fb0d93673b014ddff38c074218a0517
RMD160 (MPC-1.0.tar.gz) = 0383006d9f413d201b7b3dc6da8d6169beaf5a4e
Size (MPC-1.0.tar.gz) = 803443 bytes
SHA1 (patch-aa) = 66e1c649e6adbb86e6c49256ce8abcc4293f2bc5
SHA1 (patch-ab) = 6883ab33b9e2e1a469c872d6cbb05ca6c5dc43e3
This diff is collapsed.
Click to expand it.
MPC/patches/patch-ab
0 → 100644
+
19
−
0
View file @
9a647efa
[CMakeLists.txt] Fix it for cmake < 2.8
cmake 2.8 allows a length of -1 in substring, but not previous
version. So do manually the size computation before calling
substring !
--- MPC/CMakeLists.txt
+++ MPC/CMakeLists.txt
@@ -5,7 +5,9 @@
set(PACKAGE_VERSION 1.0)
macro(GET_LIBRARY_NAME LIBRARY_FULL LIBRARY_NAME)
get_filename_component(LIBRARY_BASE ${LIBRARY_FULL} NAME_WE)
- string(SUBSTRING ${LIBRARY_BASE} 3 -1 PIPO)
+ string(LENGTH ${LIBRARY_BASE} LEN)
+ math(EXPR SUB_LEN "${LEN} - 3")
+ string(SUBSTRING ${LIBRARY_BASE} 3 ${SUB_LEN} PIPO)
set(${LIBRARY_NAME} ${PIPO})
endmacro()
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment