Skip to content

Commit e37981c

Browse files
committed
CI: modify build.yml
1 parent b0e9245 commit e37981c

File tree

8 files changed

+24
-29
lines changed

8 files changed

+24
-29
lines changed

.github/workflows/build.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,14 +81,16 @@ jobs:
8181
echo "[:us: Change log](https://github.com/KangLin/SerialPortAssistant/blob/${{env.SerialPortAssistant_VERSION}}/ChangeLog.md)" >> ${{github.workspace}}/Release.md
8282
echo "" >> ${{github.workspace}}/Release.md
8383
echo "File checksum:" >> ${{github.workspace}}/Release.md
84+
echo "|File|Checksum(md5)|" >> ${{github.workspace}}/Release.md
85+
echo "| :- | :- |" >> ${{github.workspace}}/Release.md
8486
cd ${{ env.artifact_path }}
8587
for file in *
8688
do
8789
echo "$file"
8890
if [ -f $file ]; then
8991
if [ "${file##*.}" != "xml" ] && [ "${file##*.}" != "json" ]; then
9092
md5sum $file > $file.md5sum
91-
cat $file.md5sum >> ${{github.workspace}}/Release.md
93+
awk '{print "|", $2, "|", $1, "|"}' ${file}.md5sum >> ${{github.workspace}}/Release.md
9294
fi
9395
else
9496
rm -fr $file

.github/workflows/ubuntu.yml

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ jobs:
1616
build_ubuntu:
1717
strategy:
1818
matrix:
19-
BUILD_TYPE: [Release]
19+
BUILD_TYPE: [Release, Debug]
2020

2121
# See: https://docs.github.com/zh/actions/using-github-hosted-runners/about-github-hosted-runners/about-github-hosted-runners
2222
# See: https://github.com/actions/runner-images/
@@ -48,14 +48,14 @@ jobs:
4848
4949
- name: Install apt packages
5050
run: |
51-
sudo apt update
52-
sudo apt upgrade
51+
sudo apt update -y
52+
sudo apt upgrade -y
5353
sudo apt install -y -q cmake build-essential xvfb xpra \
5454
libglu1-mesa-dev libpulse-mainloop-glib0 \
5555
cmake debhelper fakeroot \
5656
qt6-tools-dev qt6-tools-dev-tools qt6-base-dev qt6-base-dev-tools \
5757
qt6-l10n-tools qt6-translations-l10n qt6-scxml-dev \
58-
qt6-webengine-dev qt6-webengine-dev-tools libqt6serialport6-dev \
58+
libqt6serialport6-dev \
5959
libxkbcommon-dev libxkbcommon-x11-dev xorg-dev libx11-xcb-dev \
6060
libx11-dev libxfixes-dev \
6161
libcmark-dev cmark
@@ -76,10 +76,9 @@ jobs:
7676
- name: build SerialPortAssistant
7777
env:
7878
RabbitCommon_DIR: ${{env.SOURCE_DIR}}/RabbitCommon
79-
PKG_CONFIG_PATH: ${{env.INSTALL_DIR}}/lib/pkgconfig
8079
run: |
8180
cd ${{github.workspace}}
82-
./build_debpackage.sh /usr/lib/`uname -a`-linux-gnu/cmake/Qt6
81+
./build_debpackage.sh
8382
cp ../serialportassistant_${{env.SerialPortAssistant_VERSION}}_amd64.deb serialportassistant_${{env.SerialPortAssistant_VERSION}}_amd64.deb
8483
8584
- name: update configure file

CMakeLists.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,8 @@ if(Qt${QT_VERSION_MAJOR}_FOUND)
5151
ENDFOREACH()
5252
endif()
5353
get_filename_component(QT_INSTALL_DIR "${Qt${QT_VERSION_MAJOR}_DIR}/../../.." ABSOLUTE)
54+
message("QT_ROOT:${QT_ROOT}")
55+
message("Qt${QT_VERSION_MAJOR}_ROOT:${Qt${QT_VERSION_MAJOR}_ROOT}")
5456
message("Qt${QT_VERSION_MAJOR}_DIR:${Qt${QT_VERSION_MAJOR}_DIR}")
5557
message("QT_INSTALL_DIR:${QT_INSTALL_DIR}")
5658
message("QT_LIBRARIES:${QT_LIBRARIES}")

ChangeLog.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
## Change log
2+
13
- Version: v0.5.28
24
- Use [RabbitCommon v2.3.1](https://github.com/KangLin/RabbitCommon/releases/tag/v2.3.1)
35

ChangeLog_zh_CN.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
## 修改日志
2+
13
- 版本: v0.5.28
24
- 使用 [RabbitCommon v2.3.1](https://github.com/KangLin/RabbitCommon/releases/tag/v2.3.1)
35

build_debpackage.sh

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,16 @@
11
#!/bin/bash
22

3+
function help()
4+
{
5+
echo "Usage: $0 QT_ROOT RabbitCommon_DIR"
6+
}
7+
38
if [ -n "$1" -a -z "$QT_ROOT" ]; then
49
QT_ROOT=$1
510
fi
611

7-
if [ -z "$QT_ROOT" ]; then
8-
echo "$0 QT_ROOT RabbitCommon_DIR"
9-
exit -1
12+
if [ -n "$QT_ROOT" ]; then
13+
export QT_ROOT=$QT_ROOT
1014
fi
1115

1216
if [ -n "$2" -a -z "$RabbitCommon_DIR" ]; then
@@ -17,11 +21,10 @@ if [ -z "$RabbitCommon_DIR" ]; then
1721
RabbitCommon_DIR=`pwd`/../RabbitCommon
1822
fi
1923

20-
if [ ! -d "$RabbitCommon_DIR" ]; then
21-
echo "$0 QT_ROOT RabbitCommon_DIR"
24+
if [ -d "$RabbitCommon_DIR" ]; then
25+
export RabbitCommon_DIR=$RabbitCommon_DIR
2226
fi
2327

24-
2528
#fakeroot debian/rules binary
2629

2730
# -p, --sign-command=sign-command
@@ -64,4 +67,3 @@ dpkg-buildpackage -us -uc -b -d
6467
#dpkg-buildpackage -us -uc
6568

6669
#dpkg-buildpackage
67-

debian/control

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ Section: main
66
Priority: optional
77
Maintainer: Kang Lin <[email protected]>
88
Build-Depends: cmake, debhelper (>=13~), debhelper-compat (=13), fakeroot,
9-
libssl-dev, libcmark-dev, rabbitcommon-dev (>=2.2.6),
9+
libssl-dev, libcmark-dev, rabbitcommon-dev (>=2.3.2),
1010
qt6-tools-dev, qt6-tools-dev-tools, qt6-base-dev, qt6-base-dev-tools,
1111
qt6-l10n-tools, qt6-translations-l10n, qt6-scxml-dev, libqt6serialport6-dev
1212
Standards-Version: 4.6.2

debian/rules

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -17,17 +17,6 @@
1717
%:
1818
dh $@
1919

20-
ifdef WITH_CMARK_GFM
21-
PARAS += WITH_CMARK_GFM=$(WITH_CMARK_GFM)
22-
ifdef cmark-gfm_DIR
23-
PARAS += cmark-gfm_DIR=$(cmark-gfm_DIR)
24-
endif
25-
endif
26-
27-
ifdef INSTALL_DIR
28-
LIB_PARAS += $(INSTALL_DIR)/lib
29-
endif
30-
3120
DEB_HOST_MULTIARCH ?= $(shell dpkg-architecture -qDEB_HOST_MULTIARCH)
3221
BUILD_DIR = "build_$(DEB_HOST_MULTIARCH)"
3322
PACKAGE_DIR = "debian/serialportassistant"
@@ -56,8 +45,5 @@ override_dh_auto_install:
5645
--component Application \
5746
--prefix $(PACKAGE_DIR)/opt/SerialPortAssistant
5847

59-
#override_dh_shlibdeps:
60-
# dh_shlibdeps --dpkg-shlibdeps-params=--ignore-missing-info -l`pwd`/$(BUILD_DIR)/lib:$(LIB_PARAS)
61-
6248
override_dh_builddeb:
6349
dh_builddeb --package=serialportassistant -P$(PACKAGE_DIR)

0 commit comments

Comments
 (0)