Currently, we use the value of hw.machine to get the arch of the machine in bsd.port.mk and bsd.port.subdir.mk. But, we should use the value of hw.machine_arch instead of hw.machine. We can use 'uname -p' to get hw.machine_arch because 'uname -p' prints the value of hw.machine_arch now.
Responsible Changed From-To: freebsd-ports->portmgr Over to maintainer.
On Sun, Mar 03, 2002 at 08:39:09PM +0900, Takahashi Yoshihiro wrote: > > >Number: 35514 > >Category: ports > >Synopsis: Use the value of hw.machine_arch instead of hw.machine to get the arch of the machine. > >Originator: Takahashi Yoshihiro > >Description: > Currently, we use the value of hw.machine to get the arch of the machine in > bsd.port.mk and bsd.port.subdir.mk. But, we should use the value of > hw.machine_arch instead of hw.machine. > > We can use 'uname -p' to get hw.machine_arch because 'uname -p' prints the > value of hw.machine_arch now. [snip] > .if !defined(ARCH) > -ARCH!= ${UNAME} -m > +ARCH!= ${UNAME} -p > .endif Just a minor comment: I think this, as well as the other places ARCH is set, should be made conditional upon OSVERSION - not all the FreeBSD versions we support have the uname -p format. Other than that, this would be a Good Thing(tm). G'luck, Peter -- Peter Pentchev roam@ringlet.net roam@FreeBSD.org PGP key: http://people.FreeBSD.org/~roam/roam.key.asc Key fingerprint FDBA FD79 C26F 3C51 C95E DF9E ED18 B68D 1619 4553 If I were you, who would be reading this sentence?
In article <20020314155144.D362@straylight.oblivion.bg> Peter Pentchev <roam@ringlet.net> writes: > > .if !defined(ARCH) > > -ARCH!= ${UNAME} -m > > +ARCH!= ${UNAME} -p > > .endif > > Just a minor comment: I think this, as well as the other places ARCH is > set, should be made conditional upon OSVERSION - not all the FreeBSD > versions we support have the uname -p format. Currently, hw.machine_arch is same as hw.machine with all architectures FreeBSD supports. (pc98 is special case. I may change it.) So, I think that it does not need to make conditional. BTW, uname -p option was added at Feb 24 1998 for compatibility. All versions of 3.x and 4.x (of course 5-current) have uname -p option. --- TAKAHASHI Yoshihiro THE CENTER for INFORMATION SCIENCE, Kogakuin Univ.
On Thu, Mar 14, 2002 at 11:28:18PM +0900, Takahashi Yoshihiro wrote: > In article <20020314155144.D362@straylight.oblivion.bg> > Peter Pentchev <roam@ringlet.net> writes: > > > > .if !defined(ARCH) > > > -ARCH!= ${UNAME} -m > > > +ARCH!= ${UNAME} -p > > > .endif > > > > Just a minor comment: I think this, as well as the other places ARCH is > > set, should be made conditional upon OSVERSION - not all the FreeBSD > > versions we support have the uname -p format. > > Currently, hw.machine_arch is same as hw.machine with all architectures > FreeBSD supports. (pc98 is special case. I may change it.) So, I think > that it does not need to make conditional. Yep, I was aware of that; my comment arose from the fact that I thought that uname(1) did not support the -p cmdline argument until recently. > BTW, uname -p option was added at Feb 24 1998 for compatibility. All > versions of 3.x and 4.x (of course 5-current) have uname -p option. Oops; I seem to have confused the change to uname to make -p actually return the arch with the change to uname to support -p at all. Thanks for the clarification! G'luck, Peter -- Peter Pentchev roam@ringlet.net roam@FreeBSD.org PGP key: http://people.FreeBSD.org/~roam/roam.key.asc Key fingerprint FDBA FD79 C26F 3C51 C95E DF9E ED18 B68D 1619 4553 Do you think anybody has ever had *precisely this thought* before?
State Changed From-To: open->analyzed This is being tested and will be committed shortly.
State Changed From-To: analyzed->closed Patch committed, thanks!