hello-debhelper パケジ

とりあえず apt-get source してみました。

$ apt-get source hello-debhelper
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Need to get 607 kB of source archives.
Get:1 http://archive.ubuntu.com/ubuntu/ oneiric/main hello-debhelper 2.7-1 (dsc) [1,358 B]
Get:2 http://archive.ubuntu.com/ubuntu/ oneiric/main hello-debhelper 2.7-1 (tar) [600 kB]                                                                                                       
Get:3 http://archive.ubuntu.com/ubuntu/ oneiric/main hello-debhelper 2.7-1 (diff) [6,175 B]                                                                                                     
Fetched 607 kB in 12s (49.0 kB/s)                                                                                                                                                               
gpgv: Signature made Tue 05 Apr 2011 11:06:08 PM JST using RSA key ID 9F1B8B32
gpgv: Can't check signature: public key not found
dpkg-source: warning: failed to verify signature on ./hello-debhelper_2.7-1.dsc
dpkg-source: info: extracting hello-debhelper in hello-debhelper-2.7
dpkg-source: info: unpacking hello-debhelper_2.7.orig.tar.gz
dpkg-source: info: unpacking hello-debhelper_2.7-1.debian.tar.gz
dpkg-source: info: applying 01-no-usr-share-info-dir-gz
$ ls
hello-debhelper-2.7  
hello-debhelper_2.7-1.debian.tar.gz  
hello-debhelper_2.7-1.dsc  
hello-debhelper_2.7.orig.tar.gz
$

これを cdbs で書き換えって思ってるのですが debian/rules を云々すれば良いだけなのかどうなのか。あ、debian/control も変更しないと駄目なのかな。

と思ったら

以下なドキュメントに hello-debhelper の debian/rules な例が出てるorz

以下が書き換え後の debian/rules らしい。

#!/usr/bin/make -f

include /usr/share/cdbs/1/rules/debhelper.mk

package = hello-cdbs

CC = gcc
CFLAGS = -g -Wall

ifeq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))
  CFLAGS += -O2
endif

clean::
	-$(MAKE) -i distclean

install/hello-cdbs::
	$(MAKE) prefix=$(CURDIR)/debian/$(package)/usr install

common-configure-arch::
	./configure --prefix=/usr

common-build-arch::
	$(MAKE) CC="$(CC)" CFLAGS="$(CFLAGS)"

DEB_INSTALL_DOCS_ALL := NEWS
DEB_INSTALL_CHANGELOGS_ALL := ChangeLog

確認必要ですが今日は終わり。