Skip to content

Commit f708add

Browse files
committed
合并主线,移除对核心代码的改动
Merge branch 'master' into aic8800_flash_driver # Conflicts: # src/jtag/drivers/cmsis_dap.c # src/jtag/drivers/cmsis_dap.h # src/jtag/drivers/cmsis_dap_usb_bulk.c # src/openocd.c
2 parents c894318 + a9015ba commit f708add

File tree

637 files changed

+28220
-11422
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

637 files changed

+28220
-11422
lines changed

.checkpatch.conf

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,6 @@
1717
--ignore LINE_SPACING
1818
--ignore LOGICAL_CONTINUATIONS
1919
--ignore MACRO_WITH_FLOW_CONTROL
20-
--ignore NEW_TYPEDEFS
2120
--ignore PARENTHESIS_ALIGNMENT
2221
--ignore PREFER_DEFINED_ATTRIBUTE_MACRO
2322
--ignore PREFER_FALLTHROUGH

.github/workflows/snapshot.yml

Lines changed: 16 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ name: OpenOCD Snapshot
88

99
jobs:
1010
package:
11-
runs-on: [ubuntu-20.04]
11+
runs-on: [ubuntu-latest]
1212
env:
1313
DL_DIR: ../downloads
1414
BUILD_DIR: ../build
@@ -18,7 +18,7 @@ jobs:
1818
sudo apt-get update
1919
sudo apt-get install autotools-dev autoconf automake libtool pkg-config cmake texinfo texlive g++-mingw-w64-i686
2020
- name: Checkout Code
21-
uses: actions/checkout@v1
21+
uses: actions/checkout@v4
2222
- run: ./bootstrap
2323
- name: Prepare libusb1
2424
env:
@@ -66,6 +66,14 @@ jobs:
6666
cd libjaylink-${LIBJAYLINK_VER}
6767
./autogen.sh
6868
echo "LIBJAYLINK_SRC=$PWD" >> $GITHUB_ENV
69+
- name: Prepare jimtcl
70+
env:
71+
JIMTCL_VER: 0.83
72+
run: |
73+
mkdir -p $DL_DIR && cd $DL_DIR
74+
wget https://github.com/msteveb/jimtcl/archive/refs/tags/${JIMTCL_VER}.tar.gz
75+
tar -xzf ${JIMTCL_VER}.tar.gz
76+
echo "JIMTCL_SRC=$PWD/jimtcl-${JIMTCL_VER}" >> $GITHUB_ENV
6977
- name: Package OpenOCD for windows
7078
env:
7179
MAKE_JOBS: 2
@@ -75,6 +83,7 @@ jobs:
7583
LIBFTDI_CONFIG: -DSTATICLIBS=OFF -DEXAMPLES=OFF -DFTDI_EEPROM=OFF
7684
CAPSTONE_CONFIG: "CAPSTONE_BUILD_CORE_ONLY=yes CAPSTONE_STATIC=yes CAPSTONE_SHARED=no"
7785
LIBJAYLINK_CONFIG: --enable-shared --disable-static
86+
JIMTCL_CONFIG: --with-ext=json --minimal --disable-ssl
7887
run: |
7988
# check if there is tag pointing at HEAD, otherwise take the HEAD SHA-1 as OPENOCD_TAG
8089
OPENOCD_TAG="`git tag --points-at HEAD`"
@@ -93,25 +102,24 @@ jobs:
93102
# add missing dlls
94103
cd $HOST-root/usr
95104
cp `$HOST-gcc --print-file-name=libwinpthread-1.dll` ./bin/
96-
# required by libftdi1.dll. For the gcc-mingw-10.3.x or later "libgcc_s_dw2-1.dll" will need to be copied.
97-
cp `$HOST-gcc --print-file-name=libgcc_s_sjlj-1.dll` ./bin/
105+
# required by libftdi1.dll
106+
cp `$HOST-gcc --print-file-name=libgcc_s_dw2-1.dll` ./bin/
98107
# prepare the artifact
99108
ARTIFACT="openocd-${OPENOCD_TAG}-${HOST}.tar.gz"
100109
tar -czf $ARTIFACT *
101110
echo "RELEASE_NAME=$RELEASE_NAME" >> $GITHUB_ENV
102111
echo "IS_PRE_RELEASE=$IS_PRE_RELEASE" >> $GITHUB_ENV
103112
echo "ARTIFACT_PATH=$PWD/$ARTIFACT" >> $GITHUB_ENV
104113
- name: Publish OpenOCD packaged for windows
105-
uses: actions/upload-artifact@v3
114+
uses: actions/upload-artifact@v4
106115
with:
107116
path: ${{ env.ARTIFACT_PATH }}
108117
- name: Delete 'latest' Release
109-
uses: dev-drprasad/delete-tag-and-release@v0.2.1
118+
uses: dev-drprasad/delete-tag-and-release@v1.1
110119
with:
111120
delete_release: true
112121
tag_name: ${{ env.RELEASE_NAME }}
113-
env:
114-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
122+
github_token: ${{ secrets.GITHUB_TOKEN }}
115123
- name: Create Release
116124
uses: ncipollo/release-action@v1
117125
with:

.gitignore

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,9 @@
1111
*.la
1212
*.in
1313

14-
# generated source files
15-
src/jtag/minidriver_imp.h
16-
src/jtag/jtag_minidriver.h
14+
# coverage files (gcov)
15+
*.gcda
16+
*.gcno
1717

1818
# OpenULINK driver files generated by SDCC
1919
src/jtag/drivers/OpenULINK/*.rel
@@ -84,6 +84,9 @@ patches
8484
.cproject
8585
.settings
8686

87+
# VSCode stuff
88+
.vscode
89+
8790
# Emacs temp files
8891
*~
8992

.gitmodules

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,3 @@
1-
[submodule "tools/git2cl"]
2-
path = tools/git2cl
3-
url = https://git.savannah.nongnu.org/git/git2cl.git
41
[submodule "jimtcl"]
52
path = jimtcl
63
url = https://github.com/msteveb/jimtcl.git

AUTHORS

Lines changed: 2 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,2 @@
1-
Dominic Rath <[email protected]>
2-
Magnus Lundin <[email protected]>
3-
Michael Fischer <[email protected]>
4-
Spencer Oliver <[email protected]>
5-
Carsten Schlote <[email protected]>
6-
Øyvind Harboe <[email protected]>
7-
Duane Ellis <[email protected]>
8-
Michael Schwingen <[email protected]>
9-
Rick Altherr <[email protected]>
10-
David Brownell <[email protected]>
11-
Vincint Palatin <[email protected]>
12-
Zachary T Welch <[email protected]>
1+
Please check the source code files and/or Git history for a list of all authors
2+
and contributors.

HACKING

Lines changed: 32 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,22 @@ patch:
9292
make
9393
@endcode
9494

95+
- Code coverage analysis
96+
97+
By inspecting the code coverage, you can identify potential gaps in your testing
98+
and use that information to improve your test scenarios.
99+
100+
Example usage:
101+
@code
102+
mkdir build-gcov; cd build-gcov
103+
../configure --enable-gcov [...]
104+
make
105+
# ... Now execute your test scenarios to collect OpenOCD code coverage ...
106+
lcov --capture --directory ./src --output-file openocd-coverage.info
107+
genhtml openocd-coverage.info --output-directory coverage_report
108+
# ... Open coverage_report/index.html in a web browser ...
109+
@endcode
110+
95111
Please consider performing these additional checks where appropriate
96112
(especially Clang Static Analyzer for big portions of new code) and
97113
mention the results (e.g. "Valgrind-clean, no new Clang analyzer
@@ -153,11 +169,9 @@ git remote add review https://USERNAME:[email protected]/p/openocd.git
153169
Gerrit server, even if you plan to use several local branches for different
154170
topics. It is possible because @c for/master is not a traditional Git
155171
branch.
156-
-# You will need to install this hook, we will look into a better solution:
157-
@code
158-
scp -p -P 29418 [email protected]:hooks/commit-msg .git/hooks/
159-
@endcode
160-
Or with http only:
172+
-# You will need to install this hook to automatically add the
173+
field "Change-Id:" in the commit message, as required by Gerrit.
174+
We will look into a better solution:
161175
@code
162176
wget https://review.openocd.org/tools/hooks/commit-msg
163177
mv commit-msg .git/hooks
@@ -234,6 +248,12 @@ doc: fix typos
234248
@code
235249
git pull --rebase origin master
236250
@endcode
251+
252+
-# When you create a new version of an old patch, check that the new patch
253+
keeps the same 'Change-Id:' field of the old patch.
254+
This allows the Gerrit server to recognize the patch as a new version of
255+
the older one and keeps track of the history and the review process.
256+
237257
-# Send the patches to the Gerrit server for review:
238258
@code
239259
git push review
@@ -291,6 +311,13 @@ Only for <em>exceptional cases</em>, it is allowed to submit patches
291311
to Gerrit with the special field 'Checkpatch-ignore:' in the commit
292312
message. This field will cause checkpatch to ignore the error types
293313
listed in the field, only for the patch itself.
314+
For errors in the commit message, the special field has to be put in
315+
the commit message before the line that produces the error.
316+
The special field must be added <em>before</em> the 'Signed-off-by:'
317+
line, otherwise it is ignored.
318+
To ignore multiple errors, either add multiple lines with the special
319+
field or add multiple error types, separated by space or commas, in a
320+
single line.
294321
The error type is printed by checkpatch on failure.
295322
For example the names of Windows APIs mix lower and upper case chars,
296323
in violation of OpenOCD coding style, triggering a 'CAMELCASE' error:

0 commit comments

Comments
 (0)