[PKG-Openstack-devel] [MoM] Packaging manila

Malihe Asemani ml.asemani at gmail.com
Tue Apr 28 21:20:21 UTC 2015


Hey,

On Fri, Apr 24, 2015 at 6:42 PM, Andreas Tille <andreas at an3as.eu> wrote:

> Hi,
>
> sorry for the delay - I was a bit busy.
>
> Sorry for my delay, too.


> > Then, I tried to create a Test rgit reo, using the script. The created
> git
> > repository is not observable on http://git.debian.org/openstack.  Is
> this
> > the issue that Thamos has mentioned it, before?
> >    "This should be slightly adapted if you're not add (to handle a
> > different username with "-     guest" at the end). "
>
> I guess the web display on git.debian.org is OK since the repository does
> not exist at all:
>
>    moszumanska:~$ ls /git/openstack/* | grep manila
>    moszumanska:~$
>
> The name of my repo in this state was "TEST" not manila, and after doing
my test, I removed the repo from git-server. That's why you could not find
it.

About the issue that I mentioned it in the previous email (web display of
git repo), I found out it was related to time. It seems changes on
git.debian.org are not displaying immediately on web.
In other words, After spending a little time removed/added items will be
displayed. I should just be a little more patient ;)


I think it might be a good idea to use the script with "set -x" to see
> where it fails and in case of problems do all the steps manually.


Actually, It did not fail. As I mentioned above, It was just my mistake.
The script was done successfully without reporting any failure.


  If
> you send me the link where you downloaded the script I could check
> myself but I guess it will be no magic and contains some "git init" etc.
> stuff that could be done manually for sure.
>
> I think it is a little bit late for sending the link :P
sorry for delay

Please always keep in mind that I do not know the relation between the
> launchpad and the github, but *I* consider it good practice to use the
> version that is released by upstream and as far as I can see upstream is
> at github.  To fetch the latest version from github you can use a
> debian/watch file with the following content:
>
>
> version=3
> opts="uversionmangle=s/([\d.]*)([a-zA-Z])/$1~$2/;s/\.0b/~b/" \
>   https://github.com/openstack/manila/releases
> .*/archive/(\d[\d.-brc]+)\.(?:tar(?:\.gz|\.bz2)?|tgz)
>
>
> If you do this and go to the main packaging dir (== the dir where you
> see the content above if you do `cat debian/watch`) than you can do
>
>  $ uscan --verbose --report
> -- Scanning for watchfiles in .
> -- Found watchfile in ./debian
> -- In debian/watch, processing watchfile line:
>    opts="uversionmangle=s/([\d.]*)([a-zA-Z])/$1~$2/;s/\.0b/~b/"
> https://github.com/openstack/manila/releases
> .*/archive/(\d[\d.-brc]+)\.(?:tar(?:\.gz|\.bz2)?|tgz)
> -- Found the following matching hrefs:
>      /openstack/manila/archive/2015.1.0rc1.tar.gz (2015.1.0~rc1)
>      /openstack/manila/archive/2015.1.0b3.tar.gz (2015.1.0~b3)
>      /openstack/manila/archive/2015.1.0b2.tar.gz (2015.1.0~b2)
>      /openstack/manila/archive/2015.1.0b1.tar.gz (2015.1.0~b1)
>      /openstack/manila/archive/2014.2.tar.gz (2014.2)
>      /openstack/manila/archive/2014.2.rc2.tar.gz (2014.2.~rc2)
>      /openstack/manila/archive/2014.2.rc1.tar.gz (2014.2.~rc1)
>      /openstack/manila/archive/2014.2.b3.tar.gz (2014.2.~b3)
> Newest version on remote site is 2015.1.0~rc1, local version is 2015.1~b2
>  => Newer version available from
>     https://github.com/openstack/manila/archive/2015.1.0rc1.tar.gz
> -- Scan finished
>
> If you do
>
>  $ uscan --verbose --force-download
>
> you get what *I* would start packaging (and I repeat that I'm quite
> clueless about OpenStack in general and Manila in special and so I have
> no idea whether it is a good idea to use "~b" but "~rc" seems to be even
> a release candidate from upstream which might be fit for packaging.
>
> Great explanation. thanks


> > Now, I dont know as the first commit, I should add a debian dir which is
> > added using *dh-make*?
>
> I *personally* hate dh-make since it leaves you alone with a lot of
> useless templates you need to delete afterwards.  Since I'd regard this
> as a very dumb work and I've seen so many not deleted templates that
> just leave noise I always recommend to start with some existing package.
> As you might have seen in the Debian Med policy I've created an adapted
> package_template but this is not as helpful in your case.
>
> > or i can copy ubuntu-Manila debian directory on my
> > repository, and do the first commit?
>
> I'd (strongly) recommend to start from this since this is most probably
> the best way to start from.  I'd always consider starting from some
> existing packaging work and see how far it leads.  I had a view into
> this and have seen several needed changes - but we can do this step by
> step.
>
> Okay :)

> if iI copy ubuntu-Manila debian dir,
> > is it needed to change some thing like control file, changelog, ...? Or I
> > should just do the first commit, and then we will try to adapt it for
> > Debain Repositories?
>
> You should have a close look into some other package done by the
> openstack team and adapt the "Maintainer" and "Uploaders" field
> accordingly.  Please confirm that you were able to follow up to this
> point (or not and ask what might remain unclear).  Than we might
> continue from here.
>
> I found them on control file. As for Uploaders, should I only add my and
your name/email? or the name of main maintainer of openstack in Debian (I
mean Thomas) should  be added to all of the openstack packages, too.

So please send me some mail that you did a commit (perhaps with a short
> commit log) and I'll pull from Git and will check your changes.
>
> Got it. sure, I will send.


> > I dont know what are " d/watch files". May I know where can I find some
> > documents about it?
>
> Sorry for the stupid shortcut.  Please note:  If I write "d/<something>"
> I mean "debian/<something>".  Its a stupid pedagocial mistake of mine to
> throw those shortcuts onto newcomers and I'll avoid this in future.  I
> think the debian/watch issue was explained above.  Its simply the meta
> information where to seek for new upstream versions.
>
> Uhum. got it.

>
> [tag-based-packaging]
> > > > git clone git://github.com/openstack/manila.git
> > > > cd manila
> > > > git tag 2015.1_b3 2015.1.0b3
> > > > git reset --hard 2015.1_b3
> > > > git checkout -b debian/kilo
> > > > git branch -d master
> > > > # <add here your debian folder for the packaging>
> > > > git add debian
> > > > git commit -a -m "Initial debian folder"
> > > >
> > > > Make sure that, when you add your Debian folder, you get something
> > > > like this in debian/gbp.conf:
> > > >
> > > > [DEFAULT]
> > > > debian-branch = debian/kilo
> > > > upstream-tag = %(version)s
> > > > compression = xz
> > > >
> > > > [git-buildpackage]
> > > > export-dir = ../build-area/
> > > >
> > > > Then doing "pkgos-bop" should rebuild the package correctly.
> > >
> > Thank you Thomas for the explanation. I need to study about
> > debian/gbp.conf
>
> Hmm, reading this again this is possibly what Thomas means with "tag
> based packaging".  Did you went all these single steps?

While I
> think the tag is not the one we should target at since uscan reports
> some newer version this sounds quite sensible to me.  I'm afraid
> you just where not able to push this to git.debian.org.
>
> So please if there are remaining problems:  Do *every* single step and
> post the output (may be shortened) to enable me reproducing what you did
> and comment ond potential problems.  If you confirm that all above went
> smoothly you might just hang on the pkgos-alioth-new-git script which as
> I wrote above could be separated into simple steps most probably.  Just
> let me know about any single step and any single failure that might
> occure.  I'll try to reproduce this here and will take over things that
> might fail on your side (for whatever reason).
>
> Yes, I had done them when you replied my email. I just didn't know what is
the correct format of line "git tag 2015.1_b3 2015.1.0b3" in my case, as I
described in the previous email.
Finally, I replaced the line with "git tag 2015.1_rc1 2015.1.0rc1" and
finished the above steps. Then I used pkgos-alioth-new-git  and uploaded
the cod on git-server. The only problem was displaying on web, which it was
not a real problem. But, I thought s/th is wrong when I saw nothing is
displaying on the web, and so i deleted my repo from git.debian.org


> I guess the retagging is done since in Debian we are using the tilde (~)
> to make sure we can easily increase the version number when there is an
> official release (without the attached "b3").  You might like to have a
> look at the following comparison:
>
>   if dpkg --compare-versions 2015.1~b3 lt 2015.1 ; then echo "2015.1~b3 is
> lower than 2015.1" ; fi
>
> That's the reason why in debian/changelog you find the '~' before the
> 'b' in the version string and this in turn is the reason why in
> debian/watch the '~' is injected in the uversionmangle expression (see
> above).  However, (as far as I know) the tilde is no valid character for
> Git tags and thus in Git tags it is emulated with an underscore ('_').
>
> On the other hand you are correct that Thomas was not refering to the
> latest upstream tag (as we know from the uscan --report above) and thus
> I think it is rather
>
>    git tag 2015.1.0_rc1 2015.1.0rc1
>
> what we want to write here.  Please note that I have currently no clone
> on my machine - may be the upstream tag is different - adapt if needed.
>
> Great explanation. thanks.


> Please refer to Debian Med policy.  Its explained there if you seek for
> "pristine-tar".  I need to admit that I do not see the constraints given
> above.
>
> Okay. Thanks.


> See above.  As I said in the beginning you need to ask in more small
> steps and more frequently.  I think this is more efficient than those
> large mails.  Please break up your single steps in the future and do
> not hesitate to ask any single bit - there is no chance to ask stupid
> questions.  Only my answers might be stupid - but I hope they will be
> not. ;-)
>
> Okay. I will do it :)


> Hope this helps
>
> Of course it helps.
Thank you :)


>        Andreas.
>
> --
> http://fam-tille.de
>
> _______________________________________________
> Openstack-devel mailing list
> Openstack-devel at lists.alioth.debian.org
> http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/openstack-devel
>



-- 
------------
you can't start the next chapter if you keep re-reading the last one

mali
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.alioth.debian.org/pipermail/openstack-devel/attachments/20150429/6165765b/attachment-0001.html>


More information about the Openstack-devel mailing list