public inbox for cygwin-apps@cygwin.com
 help / color / mirror / Atom feed
* ITA: GNU miscfiles
@ 2016-07-12 17:06 Warren Young
  2016-07-12 17:10 ` Warren Young
  2016-07-13 11:05 ` Corinna Vinschen
  0 siblings, 2 replies; 8+ messages in thread
From: Warren Young @ 2016-07-12 17:06 UTC (permalink / raw)
  To: cygwin-apps

Per https://cygwin.com/ml/cygwin/2016-07/msg00160.html

…I would like to adopt the GNU miscfiles package.  I have constructed the following cygport file, which seems to do the trick:


NAME=miscfiles
VERSION=1.5
RELEASE=1

SUMMARY="Miscellaneous data files"
HOMEPAGE="https://www.gnu.org/software/miscfiles/"
SRC_URI="https://ftp.gnu.org/gnu/${PN}/${PN}-${PV}.tar.gz"

CATEGORY=Misc
DESCRIPTION="This is the GNU Miscfiles package, which is a collection
of files not of crucial importance for system administration or
operation, but which have come to be common on various systems over the
years. It includes data files for country codes, airport codes, currency
information, and so on."

CYGCONF_ARGS="--datarootdir=/usr/share/misc"

src_install() {
	cd ${B}
	cygmake -j11 DESTDIR=${D} install

	dodir /usr/share/dict
	dosym ../misc/web2a /usr/share/dict/words

	dodoc ${D}/usr/share/misc/GNU-manifesto
	rm ${D}/usr/share/misc/GNU-manifesto
}


The last line in my src_install() override seems heavy-handed.  I would have thought that dodoc would move the file into the doc directory from its default install location for me.

Can I avoid overriding src_install() entirely?  All I want to do here is move the GNU-manifesto file to the doc dir and create a /usr/share/dict/words symlink.

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: ITA: GNU miscfiles
  2016-07-12 17:06 ITA: GNU miscfiles Warren Young
@ 2016-07-12 17:10 ` Warren Young
  2016-07-13 11:05 ` Corinna Vinschen
  1 sibling, 0 replies; 8+ messages in thread
From: Warren Young @ 2016-07-12 17:10 UTC (permalink / raw)
  To: cygwin-apps

On Jul 12, 2016, at 11:06 AM, Warren Young <wyml@etr-usa.com> wrote:
> 
> NAME=miscfiles
> VERSION=1.5
> RELEASE=1

Late addition: ARCH=noarch

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: ITA: GNU miscfiles
  2016-07-12 17:06 ITA: GNU miscfiles Warren Young
  2016-07-12 17:10 ` Warren Young
@ 2016-07-13 11:05 ` Corinna Vinschen
  2016-07-13 12:58   ` Ken Brown
  1 sibling, 1 reply; 8+ messages in thread
From: Corinna Vinschen @ 2016-07-13 11:05 UTC (permalink / raw)
  To: cygwin-apps

[-- Attachment #1: Type: text/plain, Size: 2105 bytes --]

On Jul 12 11:06, Warren Young wrote:
> Per https://cygwin.com/ml/cygwin/2016-07/msg00160.html
> 
> …I would like to adopt the GNU miscfiles package.  I have constructed the following cygport file, which seems to do the trick:
> 
> 
> NAME=miscfiles
> VERSION=1.5
> RELEASE=1
> 
> SUMMARY="Miscellaneous data files"
> HOMEPAGE="https://www.gnu.org/software/miscfiles/"
> SRC_URI="https://ftp.gnu.org/gnu/${PN}/${PN}-${PV}.tar.gz"
> 
> CATEGORY=Misc
> DESCRIPTION="This is the GNU Miscfiles package, which is a collection
> of files not of crucial importance for system administration or
> operation, but which have come to be common on various systems over the
> years. It includes data files for country codes, airport codes, currency
> information, and so on."
> 
> CYGCONF_ARGS="--datarootdir=/usr/share/misc"
> 
> src_install() {
> 	cd ${B}
> 	cygmake -j11 DESTDIR=${D} install

Why don't you use the offical call:

	cd ${B}
	cyginstall

It sets -j as well as DESTDIR automatically.

> 	dodir /usr/share/dict
> 	dosym ../misc/web2a /usr/share/dict/words
> 
> 	dodoc ${D}/usr/share/misc/GNU-manifesto
> 	rm ${D}/usr/share/misc/GNU-manifesto

Ignoring the below comment for now... what?

So you remove the exact same file you installed with dodoc?

> }
> 
> 
> The last line in my src_install() override seems heavy-handed.  I
> would have thought that dodoc would move the file into the doc
> directory from its default install location for me.

You only explain what you expect, but left out the interesting point
what actually happens.  Also, its questionable that `dodoc foo; rm foo'
is the way to go here...

> Can I avoid overriding src_install() entirely?  All I want to do here
> is move the GNU-manifesto file to the doc dir and create a
> /usr/share/dict/words symlink.

I don't think so.  If you want the script to perform extra steps you
need to create src_install.


Corinna

-- 
Corinna Vinschen                  Please, send mails regarding Cygwin to
Cygwin Maintainer                 cygwin AT cygwin DOT com
Red Hat

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 819 bytes --]

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: ITA: GNU miscfiles
  2016-07-13 11:05 ` Corinna Vinschen
@ 2016-07-13 12:58   ` Ken Brown
  2016-07-13 13:57     ` Corinna Vinschen
  2016-07-14 14:28     ` Warren Young
  0 siblings, 2 replies; 8+ messages in thread
From: Ken Brown @ 2016-07-13 12:58 UTC (permalink / raw)
  To: cygwin-apps

On 7/13/2016 7:05 AM, Corinna Vinschen wrote:
> On Jul 12 11:06, Warren Young wrote:
>> Per https://cygwin.com/ml/cygwin/2016-07/msg00160.html
>>
>> …I would like to adopt the GNU miscfiles package.  I have constructed the following cygport file, which seems to do the trick:
>>
>>
>> NAME=miscfiles
>> VERSION=1.5
>> RELEASE=1
>>
>> SUMMARY="Miscellaneous data files"
>> HOMEPAGE="https://www.gnu.org/software/miscfiles/"
>> SRC_URI="https://ftp.gnu.org/gnu/${PN}/${PN}-${PV}.tar.gz"
>>
>> CATEGORY=Misc

This is not a legal category.

>> DESCRIPTION="This is the GNU Miscfiles package, which is a collection
>> of files not of crucial importance for system administration or
>> operation, but which have come to be common on various systems over the
>> years. It includes data files for country codes, airport codes, currency
>> information, and so on."
>>
>> CYGCONF_ARGS="--datarootdir=/usr/share/misc"
>>
>> src_install() {
>> 	cd ${B}
>> 	cygmake -j11 DESTDIR=${D} install
>
> Why don't you use the offical call:
>
> 	cd ${B}
> 	cyginstall
>
> It sets -j as well as DESTDIR automatically.
>
>> 	dodir /usr/share/dict
>> 	dosym ../misc/web2a /usr/share/dict/words
>>
>> 	dodoc ${D}/usr/share/misc/GNU-manifesto
>> 	rm ${D}/usr/share/misc/GNU-manifesto
>
> Ignoring the below comment for now... what?
>
> So you remove the exact same file you installed with dodoc?
>
>> }
>>
>>
>> The last line in my src_install() override seems heavy-handed.  I
>> would have thought that dodoc would move the file into the doc
>> directory from its default install location for me.
>
> You only explain what you expect, but left out the interesting point
> what actually happens.  Also, its questionable that `dodoc foo; rm foo'
> is the way to go here...

He's trying to move GNU-manifesto from one directory under ${D} to 
another.  He should just use 'mv'.  'dodoc' copies, it doesn't move.

>> Can I avoid overriding src_install() entirely?  All I want to do here
>> is move the GNU-manifesto file to the doc dir and create a
>> /usr/share/dict/words symlink.
>
> I don't think so.  If you want the script to perform extra steps you
> need to create src_install.

Ken

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: ITA: GNU miscfiles
  2016-07-13 12:58   ` Ken Brown
@ 2016-07-13 13:57     ` Corinna Vinschen
  2016-07-14 14:30       ` Warren Young
  2016-07-14 14:28     ` Warren Young
  1 sibling, 1 reply; 8+ messages in thread
From: Corinna Vinschen @ 2016-07-13 13:57 UTC (permalink / raw)
  To: cygwin-apps

[-- Attachment #1: Type: text/plain, Size: 1210 bytes --]

On Jul 13 08:58, Ken Brown wrote:
> On 7/13/2016 7:05 AM, Corinna Vinschen wrote:
> > On Jul 12 11:06, Warren Young wrote:
> > > 	dodoc ${D}/usr/share/misc/GNU-manifesto
> > > 	rm ${D}/usr/share/misc/GNU-manifesto
> > 
> > Ignoring the below comment for now... what?
> > 
> > So you remove the exact same file you installed with dodoc?
> > 
> > > }
> > > 
> > > 
> > > The last line in my src_install() override seems heavy-handed.  I
> > > would have thought that dodoc would move the file into the doc
> > > directory from its default install location for me.
> > 
> > You only explain what you expect, but left out the interesting point
> > what actually happens.  Also, its questionable that `dodoc foo; rm foo'
> > is the way to go here...
> 
> He's trying to move GNU-manifesto from one directory under ${D} to another.
> He should just use 'mv'.  'dodoc' copies, it doesn't move.

Ok, but still.  Even when using dodoc it should better point to the source
file.  Also, why not use a symlink as for the other file?


Corinna

-- 
Corinna Vinschen                  Please, send mails regarding Cygwin to
Cygwin Maintainer                 cygwin AT cygwin DOT com
Red Hat

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 819 bytes --]

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: ITA: GNU miscfiles
  2016-07-13 12:58   ` Ken Brown
  2016-07-13 13:57     ` Corinna Vinschen
@ 2016-07-14 14:28     ` Warren Young
  2016-07-14 16:09       ` Marco Atzeri
  1 sibling, 1 reply; 8+ messages in thread
From: Warren Young @ 2016-07-14 14:28 UTC (permalink / raw)
  To: cygwin-apps

On Jul 13, 2016, at 6:58 AM, Ken Brown <kbrown@cornell.edu> wrote:
> 
> On 7/13/2016 7:05 AM, Corinna Vinschen wrote:
>> On Jul 12 11:06, Warren Young wrote:
>>> CATEGORY=Misc
> 
> This is not a legal category.

Sorry, I used it because setup.exe shows that as a category here.  But on looking at the category’s contents, everything looks like packages I downloaded long ago, which have since been removed.

I also used it because nothing else looked suitable.  The next closest ones I see (Database and System) are quite a stretch.

Honestly, Base seems to fit better, but then of course we have to decide if this is really something that needs to be in Base.

>>> The last line in my src_install() override seems heavy-handed.
>> 
>> You only explain what you expect, but left out the interesting point
>> what actually happens.
> 
> He's trying to move GNU-manifesto from one directory under ${D} to another. 

Yes.  The normal “make install” rules put GNU-manifesto in the same directory as all the other files, when it should be off in the doc dir.  Apparently cygport’s rules for finding such doc files (e.g. README, COPYING, etc.) doesn’t include this name.

> He should just use 'mv'.

It’s not that simple.  This doesn’t work:

     mv ${D}/usr/share/misc/GNU-manifesto ${D}/usr/share/doc/${PN}

because /usr/share/doc doesn’t exist in the inst dir, so you get an error from mv.  Fixing that involves replacing two short lines of code with two longer lines, plus I’m reinventing part of the dodoc wheel.

I think I’ll just stick with dodoc + rm.

> 'dodoc' copies, it doesn't move.

Well, maybe it *should* move if the source file is also under the inst directory.  What would be the point of shipping two copies of the same file in a package?

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: ITA: GNU miscfiles
  2016-07-13 13:57     ` Corinna Vinschen
@ 2016-07-14 14:30       ` Warren Young
  0 siblings, 0 replies; 8+ messages in thread
From: Warren Young @ 2016-07-14 14:30 UTC (permalink / raw)
  To: cygwin-apps

On Jul 13, 2016, at 7:56 AM, Corinna Vinschen <corinna-cygwin@cygwin.com> wrote:
> 
> when using dodoc it should better point to the source file

The problem is that the GNU-manifesto file is installed, but in the wrong location, IMHO.  I was hoping that dodoc would be smart enough to realize that I’m asking it to relocate this file within the inst tree.

>  Also, why not use a symlink as for the other file?

Because I don’t want /usr/share/misc/GNU-manifesto to exist at all.

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: ITA: GNU miscfiles
  2016-07-14 14:28     ` Warren Young
@ 2016-07-14 16:09       ` Marco Atzeri
  0 siblings, 0 replies; 8+ messages in thread
From: Marco Atzeri @ 2016-07-14 16:09 UTC (permalink / raw)
  To: cygwin-apps

On 14/07/2016 16:28, Warren Young wrote:
> On Jul 13, 2016, at 6:58 AM, Ken Brown <kbrown@cornell.edu> wrote:
>>
>> On 7/13/2016 7:05 AM, Corinna Vinschen wrote:
>>> On Jul 12 11:06, Warren Young wrote:
>>>> CATEGORY=Misc
>>
>> This is not a legal category.
>
> Sorry, I used it because setup.exe shows that as a category here.  But on looking at the category’s contents, everything looks like packages I downloaded long ago, which have since been removed.
>
> I also used it because nothing else looked suitable.  The next closest ones I see (Database and System) are quite a stretch.
>

Text ?

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2016-07-14 16:09 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-07-12 17:06 ITA: GNU miscfiles Warren Young
2016-07-12 17:10 ` Warren Young
2016-07-13 11:05 ` Corinna Vinschen
2016-07-13 12:58   ` Ken Brown
2016-07-13 13:57     ` Corinna Vinschen
2016-07-14 14:30       ` Warren Young
2016-07-14 14:28     ` Warren Young
2016-07-14 16:09       ` Marco Atzeri

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).