A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://github.com/arduino/arduino-cli/commit/ed3825da846be22a148e3800f7beb89284fdf7c2 below:

Build and distribuite deb packages (#2926) · arduino/arduino-cli@ed3825d · GitHub

File tree Expand file treeCollapse file tree 4 files changed

+92

-0

lines changed

Filter options

Expand file treeCollapse file tree 4 files changed

+92

-0

lines changed Original file line number Diff line number Diff line change

@@ -76,6 +76,10 @@ tasks:

76 76

-p "{{.BUILD_PLATFORM}}"

77 77 78 78

tar cz -C {{.PLATFORM_DIR}} {{.PROJECT_NAME}} -C ../.. LICENSE.txt -f {{.PACKAGE_NAME}}

79 +

- task: build_deb

80 +

vars:

81 +

GO_BINARY: "{{.DIST_DIR}}/{{.PLATFORM_DIR}}/{{.PROJECT_NAME}}"

82 +

ARCH: "i386"

79 83 80 84

vars:

81 85

PLATFORM_DIR: "{{.PROJECT_NAME}}_linux_amd32"

@@ -97,6 +101,10 @@ tasks:

97 101

-p "{{.BUILD_PLATFORM}}"

98 102 99 103

tar cz -C {{.PLATFORM_DIR}} {{.PROJECT_NAME}} -C ../.. LICENSE.txt -f {{.PACKAGE_NAME}}

104 +

- task: build_deb

105 +

vars:

106 +

GO_BINARY: "{{.DIST_DIR}}/{{.PLATFORM_DIR}}/{{.PROJECT_NAME}}"

107 +

ARCH: "amd64"

100 108 101 109

vars:

102 110

PLATFORM_DIR: "{{.PROJECT_NAME}}_linux_amd64"

@@ -118,6 +126,10 @@ tasks:

118 126

-p "{{.BUILD_PLATFORM}}"

119 127 120 128

tar cz -C {{.PLATFORM_DIR}} {{.PROJECT_NAME}} -C ../.. LICENSE.txt -f {{.PACKAGE_NAME}}

129 +

- task: build_deb

130 +

vars:

131 +

GO_BINARY: "{{.DIST_DIR}}/{{.PLATFORM_DIR}}/{{.PROJECT_NAME}}"

132 +

ARCH: "armhf"

121 133 122 134

vars:

123 135

PLATFORM_DIR: "{{.PROJECT_NAME}}_linux_arm_7"

@@ -139,6 +151,10 @@ tasks:

139 151

-p "{{.BUILD_PLATFORM}}"

140 152 141 153

tar cz -C {{.PLATFORM_DIR}} {{.PROJECT_NAME}} -C ../.. LICENSE.txt -f {{.PACKAGE_NAME}}

154 +

- task: build_deb

155 +

vars:

156 +

GO_BINARY: "{{.DIST_DIR}}/{{.PLATFORM_DIR}}/{{.PROJECT_NAME}}"

157 +

ARCH: "armel"

142 158 143 159

vars:

144 160

PLATFORM_DIR: "{{.PROJECT_NAME}}_linux_arm_6"

@@ -160,6 +176,10 @@ tasks:

160 176

-p "{{.BUILD_PLATFORM}}"

161 177 162 178

tar cz -C {{.PLATFORM_DIR}} {{.PROJECT_NAME}} -C ../.. LICENSE.txt -f {{.PACKAGE_NAME}}

179 +

- task: build_deb

180 +

vars:

181 +

GO_BINARY: "{{.DIST_DIR}}/{{.PLATFORM_DIR}}/{{.PROJECT_NAME}}"

182 +

ARCH: "arm64"

163 183 164 184

vars:

165 185

PLATFORM_DIR: "{{.PROJECT_NAME}}_linux_arm_64"

@@ -231,3 +251,19 @@ tasks:

231 251

cmds:

232 252

- mkdir --parents {{.DIST_DIR}}

233 253

- cp ./internal/cli/configuration/configuration.schema.json {{.DIST_DIR}}/{{.PROJECT_NAME}}_{{.VERSION}}_configuration.schema.json

254 + 255 +

build_deb:

256 +

desc: Builds the deb package

257 +

internal: true

258 +

cmds:

259 +

- |

260 +

docker build \

261 +

--build-arg BINARY_NAME={{.PROJECT_NAME}} \

262 +

--build-arg DEB_NAME={{.PROJECT_NAME}} \

263 +

--build-arg VERSION={{ .VERSION }} \

264 +

--build-arg ARCH={{ .ARCH }} \

265 +

--build-arg GO_BINARY={{ .GO_BINARY }} \

266 +

--output=./dist \

267 +

-f debian/Dockerfile .

268 +

vars:

269 +

VERSION: "{{if .TAG}}{{.VERSION}}{{else}}v0.0.0-{{.VERSION}}{{end}}"

Original file line number Diff line number Diff line change

@@ -0,0 +1,33 @@

1 +

FROM debian:bookworm AS debian

2 + 3 +

ARG VERSION

4 +

RUN test -n "${VERSION}" || (echo "Error: VERSION is not set" && exit 1)

5 + 6 +

ARG REVISION="1"

7 +

ARG ARCH

8 +

RUN test -n "${ARCH}" || (echo "Error: ARCH is not set" && exit 1)

9 + 10 +

ARG DEB_NAME

11 +

RUN test -n "${DEB_NAME}" || (echo "Error: DEB_NAME is not set" && exit 1)

12 + 13 +

ARG BINARY_NAME

14 +

RUN test -n "${BINARY_NAME}" || (echo "Error: BINARY_NAME is not set" && exit 1)

15 + 16 +

RUN apt-get update && apt-get install -y sed

17 + 18 +

ARG GO_BINARY

19 + 20 +

COPY ./debian/${DEB_NAME} /${DEB_NAME}/

21 +

COPY ./${GO_BINARY} /${DEB_NAME}/usr/bin/${BINARY_NAME}

22 +

COPY ./debian/${DEB_NAME}/DEBIAN/copyright /${DEB_NAME}/usr/share/doc/copyright

23 + 24 +

# Go application are tagged with `v` prefix, this remove the first v if present

25 +

RUN export VERSION=$(echo "${VERSION}" | sed -e "s/^v\(.*\)/\1/") && \

26 +

sed -i "s/\$ARCH/${ARCH}/" /${DEB_NAME}/DEBIAN/control && \

27 +

sed -i "s/\$VERSION/${VERSION}/" /${DEB_NAME}/DEBIAN/control && \

28 +

dpkg-deb --build --root-owner-group /${DEB_NAME} &&\

29 +

mv /${DEB_NAME}.deb "/${DEB_NAME}_${VERSION}-${REVISION}_${ARCH}.deb"

30 + 31 +

FROM scratch

32 + 33 +

COPY --from=debian /*.deb /

Original file line number Diff line number Diff line change

@@ -0,0 +1,5 @@

1 +

Package: arduino-cli

2 +

Version: $VERSION

3 +

Architecture: $ARCH

4 +

Maintainer: arduino <support@arduino.cc>

5 +

Description: Arduino CLI

Original file line number Diff line number Diff line change

@@ -0,0 +1,18 @@

1 +

Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/

2 +

Source: https://github.com/arduino/arduino-cli

3 +

Upstream-Name: arduino-cli

4 + 5 +

Files:

6 +

*

7 +

Copyright: Copyright 2020-2025 ARDUINO SA (http://www.arduino.cc/)

8 +

License: GPL-3+ with exception

9 +

This software is released under the GNU General Public License version 3,

10 +

which covers the main part of arduino-cli.

11 +

The terms of this license can be found at:

12 +

https://www.gnu.org/licenses/gpl-3.0.en.html

13 +

.

14 +

You can be released from the requirements of the above licenses by purchasing

15 +

a commercial license. Buying such a license is mandatory if you want to

16 +

modify or otherwise use the software for commercial activities involving the

17 +

Arduino software without disclosing the source code of your own applications.

18 +

To purchase a commercial license, send an email to license@arduino.cc.

You can’t perform that action at this time.


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4