Skip to content

Commit

Permalink
name using SDK_VERSION
Browse files Browse the repository at this point in the history
The sdk version will be used to name the debian
  • Loading branch information
jon-nokia committed Feb 4, 2022
1 parent 1c3c09a commit 9a81cf4
Show file tree
Hide file tree
Showing 5 changed files with 15 additions and 4 deletions.
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -7,3 +7,6 @@ bcm/sdk*
sdk
libbcmsdk*
openbcm/
nfpm-dbg.yaml
nfpm-dev.yaml
nfpm.yaml
2 changes: 1 addition & 1 deletion nfpm-dbg.yaml → nfpm-dbg.yaml.in
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
name: "libbcmsdk-dbg"
arch: "amd64"
platform: "linux"
version: "v1.0.0"
version: "v%SDK_VERSION%"
section: "default"
priority: "extra"
replaces:
Expand Down
2 changes: 1 addition & 1 deletion nfpm-dev.yaml → nfpm-dev.yaml.in
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
name: "libbcmsdk-dev"
arch: "amd64"
platform: "linux"
version: "v1.0.0"
version: "v%SDK_VERSION%"
section: "default"
priority: "extra"
replaces:
Expand Down
2 changes: 1 addition & 1 deletion nfpm.yaml → nfpm.yaml.in
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
name: "libbcmsdk"
arch: "amd64"
platform: "linux"
version: "v1.0.0"
version: "v%SDK_VERSION%"
section: "default"
priority: "extra"
replaces:
Expand Down
10 changes: 9 additions & 1 deletion secondary.mk
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,17 @@ secondary.mk: ;

include bcmsdk.mk

nfpm_yaml = \
./nfpm.yaml \
./nfpm-dbg.yaml \
./nfpm-dev.yaml

$(nfpm_yaml):
cat $@.in | sed "s,%SDK_VERSION%,$(SDK_VERSION),g" > $@

# make pkgs word2(deb,rpm)
.PHONY: pkg_%
pkg_%: bcmsdk_all
pkg_%: bcmsdk_all $(nfpm_yaml)
nfpm pkg --packager $(word2) --config ./nfpm-dev.yaml --target ./
nfpm pkg --packager $(word2) --config ./nfpm.yaml --target ./
nfpm pkg --packager $(word2) --config ./nfpm-dbg.yaml --target ./
Expand Down

0 comments on commit 9a81cf4

Please sign in to comment.