]> git.proxmox.com Git - ceph.git/blob - Makefile
bump version to 15.2.17-pve1~bpo10
[ceph.git] / Makefile
1 PACKAGE=ceph
2 VER != dpkg-parsechangelog -l changelog.Debian -Sversion | cut -d- -f1
3 PKGVER != dpkg-parsechangelog -l changelog.Debian -Sversion
4 DEBREL=pve1
5
6 SRCDIR=ceph
7 BUILDSRC=${SRCDIR}-${VER}
8
9 ARCH:=$(shell dpkg-architecture -qDEB_BUILD_ARCH)
10 GITVERSION:=$(shell git rev-parse HEAD)
11
12 DBG_DEBS=ceph-common-dbg_${PKGVER}_${ARCH}.deb \
13 ceph-fuse-dbg_${PKGVER}_${ARCH}.deb \
14 ceph-mds-dbg_${PKGVER}_${ARCH}.deb \
15 ceph-mgr-dbg_${PKGVER}_${ARCH}.deb \
16 ceph-mon-dbg_${PKGVER}_${ARCH}.deb \
17 ceph-osd-dbg_${PKGVER}_${ARCH}.deb \
18 ceph-test-dbg_${PKGVER}_${ARCH}.deb \
19 libcephfs2-dbg_${PKGVER}_${ARCH}.deb \
20 librados2-dbg_${PKGVER}_${ARCH}.deb \
21 libradosstriper1-dbg_${PKGVER}_${ARCH}.deb \
22 librbd1-dbg_${PKGVER}_${ARCH}.deb \
23 librgw2-dbg_${PKGVER}_${ARCH}.deb \
24 radosgw-dbg_${PKGVER}_${ARCH}.deb \
25 rbd-fuse-dbg_${PKGVER}_${ARCH}.deb \
26 rbd-mirror-dbg_${PKGVER}_${ARCH}.deb \
27 rbd-nbd-dbg_${PKGVER}_${ARCH}.deb
28
29 MAIN_DEB=ceph_${PKGVER}_${ARCH}.deb
30 DEBS_REST=cephadm_${PKGVER}_${ARCH}.deb \
31 ceph-base_${PKGVER}_${ARCH}.deb \
32 ceph-common_${PKGVER}_${ARCH}.deb \
33 ceph-fuse_${PKGVER}_${ARCH}.deb \
34 ceph-grafana-dashboards_${PKGVER}_all.deb \
35 ceph-immutable-object-cache_${PKGVER}_${ARCH}.deb \
36 ceph-mds_${PKGVER}_${ARCH}.deb \
37 ceph-mgr_${PKGVER}_${ARCH}.deb \
38 ceph-mgr-cephadm_${PKGVER}_all.deb \
39 ceph-mgr-dashboard_${PKGVER}_all.deb \
40 ceph-mgr-diskprediction-cloud_${PKGVER}_all.deb \
41 ceph-mgr-diskprediction-local_${PKGVER}_all.deb \
42 ceph-mgr-k8sevents_${PKGVER}_all.deb \
43 ceph-mgr-modules-core_${PKGVER}_all.deb \
44 ceph-mgr-rook_${PKGVER}_all.deb \
45 ceph-mon_${PKGVER}_${ARCH}.deb \
46 ceph-osd_${PKGVER}_${ARCH}.deb \
47 ceph-prometheus-alerts_${PKGVER}_all.deb \
48 ceph-resource-agents_${PKGVER}_${ARCH}.deb \
49 ceph-test_${PKGVER}_${ARCH}.deb \
50 cephfs-shell_${PKGVER}_all.deb \
51 libcephfs2_${PKGVER}_${ARCH}.deb \
52 libcephfs-dev_${PKGVER}_${ARCH}.deb \
53 libcephfs-java_${PKGVER}_all.deb \
54 libcephfs-jni_${PKGVER}_${ARCH}.deb \
55 librados2_${PKGVER}_${ARCH}.deb \
56 librados-dev_${PKGVER}_${ARCH}.deb \
57 libradospp-dev_${PKGVER}_${ARCH}.deb \
58 libradosstriper1_${PKGVER}_${ARCH}.deb \
59 libradosstriper-dev_${PKGVER}_${ARCH}.deb \
60 librbd1_${PKGVER}_${ARCH}.deb \
61 librbd-dev_${PKGVER}_${ARCH}.deb \
62 librgw2_${PKGVER}_${ARCH}.deb \
63 librgw-dev_${PKGVER}_${ARCH}.deb \
64 python3-ceph_${PKGVER}_${ARCH}.deb \
65 python3-ceph-common_${PKGVER}_all.deb \
66 python3-ceph-argparse_${PKGVER}_all.deb \
67 python3-cephfs_${PKGVER}_${ARCH}.deb \
68 python3-rados_${PKGVER}_${ARCH}.deb \
69 python3-rbd_${PKGVER}_${ARCH}.deb \
70 python3-rgw_${PKGVER}_${ARCH}.deb \
71 radosgw_${PKGVER}_${ARCH}.deb \
72 rados-objclass-dev_${PKGVER}_${ARCH}.deb \
73 rbd-fuse_${PKGVER}_${ARCH}.deb \
74 rbd-mirror_${PKGVER}_${ARCH}.deb \
75 rbd-nbd_${PKGVER}_${ARCH}.deb
76 DEBS=$(MAIN_DEB) $(DEBS_REST)
77
78 DSC=ceph_${PKGVER}.dsc
79
80 all: ${DEBS} ${DBG_DEBS}
81 @echo ${DEBS}
82 @echo ${DBG_DEBS}
83
84 ${BUILDSRC}: ${SRCDIR} patches
85 rm -rf $@
86 mkdir $@.tmp
87 rsync -ra ${SRCDIR}/ $@.tmp
88 cd $@.tmp; ln -s ../patches patches
89 cd $@.tmp; quilt push -a
90 cd $@.tmp; rm -rf .pc ./patches
91 echo "git clone git://git.proxmox.com/git/ceph.git\\ngit checkout ${GITVERSION}" > $@.tmp/debian/SOURCE
92 echo "debian/SOURCE" >> $@.tmp/debian/docs
93 echo "${GITVERSION}\\n${VER}" > $@.tmp/src/.git_version
94 cp changelog.Debian $@.tmp/debian/changelog
95 mv $@.tmp $@
96
97 .PHONY: deb
98 deb: ${DEBS} ${DBG_DEBS}
99 ${DEBS_REST} ${DBG_DEBS}: $(MAIN_DEB)
100 $(MAIN_DEB): ${BUILDSRC}
101 cd ${BUILDSRC}; dpkg-buildpackage -b -uc -us
102 lintian ${DEBS}
103 @echo ${DEBS}
104
105 .PHONY: dsc
106 dsc: ${DSC}
107 ${DSC}: ${BUILDSRC}
108 cd ${BUILDSRC}; dpkg-buildpackage -S -uc -us -d -nc
109 @echo ${DSC}
110
111 # NOTE: always downloads latest version!
112 .PHONY: download
113 download:
114 rm -rf ${SRCDIR}.tmp ${SRCDIR}
115 dgit -cdgit-distro.ceph.archive-query=aptget: -cdgit-distro.ceph.mirror=http://download.ceph.com/debian-octopus -cdgit-distro.ceph.git-check=false --apt-get:--option=Dir::Etc::Trusted=${CURDIR}/upstream-key.asc -d ceph clone ceph bionic ./${SRCDIR}.tmp
116 @echo "WARNING"
117 @echo "Check output above for verification errors!"
118 @echo "WARNING"
119 rm -rf ${SRCDIR}.tmp/.git
120 find ${SRCDIR}.tmp/ -type f -name '.gitignore' -delete
121 mv ${SRCDIR}.tmp/debian/changelog ${SRCDIR}.tmp/changelog.upstream
122 mv ${SRCDIR}.tmp ${SRCDIR}
123
124 .PHONY: upload
125 upload: ${DEBS}
126 tar cf - ${DEBS} | ssh repoman@repo.proxmox.com upload --product ceph-octopus --dist buster --arch ${ARCH}
127
128 distclean: clean
129
130 .PHONY: clean
131 clean:
132 rm -rf ${BUILDSRC} ${BUILDSRC}.tmp *_all.deb *_${ARCH}.deb *.changes *.dsc *.buildinfo *.tar.gz
133
134 .PHONY: dinstall
135 dinstall: ${DEB}
136 dpkg -i ${DEB}