update asyncrun
This commit is contained in:
parent
2d08d35e7d
commit
f79d1f46f7
@ -1 +1 @@
|
|||||||
Subproject commit ad94d5ef7537049b6c0a3045119ff35061d7bb89
|
Subproject commit 6e650fb9e26af280ffe097f7f851aceec33a1167
|
@ -1,9 +1,7 @@
|
|||||||
command DlcPro call s:ProjectDlcproSet('device-control')
|
command DlcPro call s:ProjectDlcproSet('device-control')
|
||||||
command DlcProShg call s:ProjectDlcproSet('shg')
|
command DlcProShg call s:ProjectDlcproSet('shg')
|
||||||
function s:ProjectDlcproSet(project_type)
|
function s:ProjectDlcproSet(project_type)
|
||||||
compiler gcc
|
" directories
|
||||||
let s:makegoals = ['artifacts', 'device-control', 'user-interface', 'doxygen', 'shg-firmware']
|
|
||||||
let s:makeopts = ['-j4']
|
|
||||||
if (a:project_type == 'device-control')
|
if (a:project_type == 'device-control')
|
||||||
let s:ProjectBaseDir = '/home/liebl/dlcpro/firmware'
|
let s:ProjectBaseDir = '/home/liebl/dlcpro/firmware'
|
||||||
let s:Program = '/device-control/device-control'
|
let s:Program = '/device-control/device-control'
|
||||||
@ -15,23 +13,39 @@ function s:ProjectDlcproSet(project_type)
|
|||||||
endif
|
endif
|
||||||
let s:ProjectSrcDir = s:ProjectBaseDir.'/src'
|
let s:ProjectSrcDir = s:ProjectBaseDir.'/src'
|
||||||
let g:ProjectBuildDir = s:ProjectBaseDir.'/build'
|
let g:ProjectBuildDir = s:ProjectBaseDir.'/build'
|
||||||
let g:Program = g:ProjectBuildDir.s:Program
|
|
||||||
|
" vim path
|
||||||
execute 'cd '.s:ProjectSrcDir
|
execute 'cd '.s:ProjectSrcDir
|
||||||
execute 'set path-=./**'
|
execute 'set path-=./**'
|
||||||
execute 'set path+=' . s:ProjectBaseDir.'/**'
|
execute 'set path+=' . s:ProjectBaseDir.'/**'
|
||||||
let g:GdbHost = 'dlcpro_stefan'
|
|
||||||
let g:GdbPort = '2345'
|
" editor settings
|
||||||
let s:GdbSlave = '~/tools/gdb-slave.sh'
|
|
||||||
let g:GdbPath = '/opt/OSELAS.Toolchain-2012.12.1/arm-cortexa8-linux-gnueabi/gcc-4.7.3-glibc-2.16.0-binutils-2.22-kernel-3.6-sanitized/bin/arm-cortexa8-linux-gnueabi-gdb'
|
|
||||||
set spell spelllang=en,de
|
set spell spelllang=en,de
|
||||||
set expandtab
|
set expandtab
|
||||||
set cinoptions=:2,=2,l1,g2,h2,N-2,t0,+0,(0,w1,Ws,m1,)100,*100
|
set cinoptions=:2,=2,l1,g2,h2,N-2,t0,+0,(0,w1,Ws,m1,)100,*100
|
||||||
|
|
||||||
|
" compiler
|
||||||
|
compiler gcc
|
||||||
|
let s:makegoals = ['artifacts', 'device-control', 'user-interface', 'doxygen', 'shg-firmware', 'docu-ul0', 'code-generation']
|
||||||
|
let s:makeopts = ['-j4']
|
||||||
|
let g:Program = g:ProjectBuildDir.s:Program
|
||||||
command! -complete=custom,GetAllMakeCompletions -nargs=* Make call s:Make('<args>')
|
command! -complete=custom,GetAllMakeCompletions -nargs=* Make call s:Make('<args>')
|
||||||
command! DlcProFirmwareUpdate call CopyFirmware('update')
|
|
||||||
command! DlcProFirmwareDebug call CopyFirmware('debug')
|
" configure quickfix window for asyncrun
|
||||||
command! DlcProFirmwareStart call CopyFirmware('start')
|
augroup QuickfixStatus
|
||||||
command! DlcProDebug call DlcProDebug(g:Program)
|
autocmd BufWinEnter quickfix setlocal
|
||||||
|
\ statusline=%t\ [%{g:asyncrun_status}]\ %{exists('w:quickfix_title')?\ '\ '.w:quickfix_title\ :\ ''}\ %=%-15(%l,%c%V%)\ %P
|
||||||
|
augroup END
|
||||||
|
|
||||||
|
" debugger
|
||||||
|
let g:GdbHost = 'dlcpro_stefan'
|
||||||
|
let g:GdbPort = '2345'
|
||||||
|
let s:GdbSlave = '~/tools/gdb-slave.sh'
|
||||||
|
let g:GdbPath = '/opt/OSELAS.Toolchain-2012.12.1/arm-cortexa8-linux-gnueabi/gcc-4.7.3-glibc-2.16.0-binutils-2.22-kernel-3.6-sanitized/bin/arm-cortexa8-linux-gnueabi-gdb'
|
||||||
|
command! DlcProFirmwareUpdate call s:CopyFirmware('update')
|
||||||
|
command! DlcProFirmwareDebug call s:CopyFirmware('debug')
|
||||||
|
command! DlcProFirmwareStart call s:CopyFirmware('start')
|
||||||
|
command! DlcProDebug call s:DlcProDebug(g:Program)
|
||||||
|
|
||||||
" vc-plugin
|
" vc-plugin
|
||||||
let g:vc_branch_url = ['https://svn.toptica.com/svn/DiSiRa/SW/firmware/branches']
|
let g:vc_branch_url = ['https://svn.toptica.com/svn/DiSiRa/SW/firmware/branches']
|
||||||
@ -51,7 +65,6 @@ function s:ProjectDlcproSet(project_type)
|
|||||||
\'~/dlcpro/firmware/.ycm_extra_conf.py',
|
\'~/dlcpro/firmware/.ycm_extra_conf.py',
|
||||||
\'!~/tools/vimsuite/vimfiles.YouCompleteMe/*',
|
\'!~/tools/vimsuite/vimfiles.YouCompleteMe/*',
|
||||||
\]
|
\]
|
||||||
|
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
" ====
|
" ====
|
||||||
@ -63,15 +76,11 @@ endfunction
|
|||||||
|
|
||||||
function s:Make(args)
|
function s:Make(args)
|
||||||
wa
|
wa
|
||||||
let g:asyncrun_quickfix = 12
|
call asyncrun#quickfix_toggle(10, 1)
|
||||||
augroup QuickfixStatus
|
|
||||||
au! BufWinEnter quickfix setlocal
|
|
||||||
\ statusline=%t\ [%{g:asyncrun_status}]\ %{exists('w:quickfix_title')?\ '\ '.w:quickfix_title\ :\ ''}\ %=%-15(%l,%c%V%)\ %P
|
|
||||||
augroup END
|
|
||||||
execute 'AsyncRun -save=1 -program=make @ --directory='.g:ProjectBuildDir.' '.a:args
|
execute 'AsyncRun -save=1 -program=make @ --directory='.g:ProjectBuildDir.' '.a:args
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
function CopyFirmware(command)
|
function s:CopyFirmware(command)
|
||||||
let command = 'bash '.s:GdbSlave.' -h '.g:GdbHost.' '.a:command
|
let command = 'bash '.s:GdbSlave.' -h '.g:GdbHost.' '.a:command
|
||||||
if a:command == 'update'
|
if a:command == 'update'
|
||||||
let command .= ' '.g:Program
|
let command .= ' '.g:Program
|
||||||
@ -87,7 +96,7 @@ function DlcProDebugGfV(program)
|
|||||||
" execute 'D set sysroot '.g:ProjectBuildDir.'/dlcpro-sdk/sysroot-target'
|
" execute 'D set sysroot '.g:ProjectBuildDir.'/dlcpro-sdk/sysroot-target'
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
function DlcProDebug(program)
|
function s:DlcProDebug(program)
|
||||||
DlcProFirmwareDebug
|
DlcProFirmwareDebug
|
||||||
let g:pyclewn_terminal = 'konsole, -e'
|
let g:pyclewn_terminal = 'konsole, -e'
|
||||||
let g:pyclewn_args = '--pgm='.g:GdbPath
|
let g:pyclewn_args = '--pgm='.g:GdbPath
|
||||||
|
Loading…
x
Reference in New Issue
Block a user