Last Comment Bug 236599 - openbsd configuration fixes for alpha, amd64, arm, i386, macppc and sparc64
: openbsd configuration fixes for alpha, amd64, arm, i386, macppc and sparc64
Status: RESOLVED FIXED
: fixed1.8.1.8
Product: Core
Classification: Components
Component: Build Config (show other bugs)
: 1.8 Branch
: All OpenBSD
: P5 normal with 10 votes (vote)
: ---
Assigned To: Peter Strömberg
:
Mentors:
: openbsd (view as bug list)
Depends on: 232742
Blocks: 237202
  Show dependency treegraph
 
Reported: 2004-03-05 13:32 PST by Peter Strömberg
Modified: 2007-11-07 10:12 PST (History)
21 users (show)
brendan: blocking1.9+
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---


Attachments
moz-configure patch (1.04 KB, patch)
2004-03-05 13:34 PST, Peter Strömberg
no flags Details | Diff | Splinter Review
ldap lber patch (1.21 KB, patch)
2004-03-05 13:34 PST, Peter Strömberg
dmose: review+
dmose: superreview+
Details | Diff | Splinter Review
nspr configure patch (1.33 KB, patch)
2004-03-05 13:35 PST, Peter Strömberg
no flags Details | Diff | Splinter Review
nspr openbsd.cfg (1.78 KB, patch)
2004-03-05 13:35 PST, Peter Strömberg
cls: review+
wtc: superreview+
Details | Diff | Splinter Review
nspr openbsd.h patch (1.56 KB, patch)
2004-03-05 13:36 PST, Peter Strömberg
cls: review+
wtc: superreview+
Details | Diff | Splinter Review
NSS openbsd patch (653 bytes, patch)
2004-03-05 13:36 PST, Peter Strömberg
wtc: review+
Details | Diff | Splinter Review
xptcall makefile patch (1.85 KB, patch)
2004-03-05 13:36 PST, Peter Strömberg
cls: review+
Details | Diff | Splinter Review
complete alpha xptcinvoke file (6.85 KB, patch)
2004-03-05 13:37 PST, Peter Strömberg
shaver: review+
Details | Diff | Splinter Review
complete alpha xptcstubs file (8.72 KB, patch)
2004-03-05 13:37 PST, Peter Strömberg
no flags Details | Diff | Splinter Review
complete xptcinvoke amd64 file (5.62 KB, patch)
2004-03-05 13:37 PST, Peter Strömberg
no flags Details | Diff | Splinter Review
complete xptcstubs amd64 file (7.01 KB, patch)
2004-03-05 13:38 PST, Peter Strömberg
no flags Details | Diff | Splinter Review
complete xptcinvoke powerpc file (3.81 KB, patch)
2004-03-05 13:38 PST, Peter Strömberg
no flags Details | Diff | Splinter Review
powerpc patch (2.71 KB, patch)
2004-03-05 13:38 PST, Peter Strömberg
no flags Details | Diff | Splinter Review
complete xptcinvoke powerpc file (5.76 KB, patch)
2004-03-05 13:40 PST, Peter Strömberg
no flags Details | Diff | Splinter Review
complete xptcstubs asm powerpc file (2.71 KB, patch)
2004-03-05 13:40 PST, Peter Strömberg
no flags Details | Diff | Splinter Review
complete xptcstubs powerpc file (9.22 KB, patch)
2004-03-05 13:41 PST, Peter Strömberg
no flags Details | Diff | Splinter Review
complete xptcinvoke asm sparc64 file (3.85 KB, patch)
2004-03-05 13:41 PST, Peter Strömberg
no flags Details | Diff | Splinter Review
complete xptcinvoke sparc64 file (3.17 KB, patch)
2004-03-05 13:41 PST, Peter Strömberg
no flags Details | Diff | Splinter Review
complete xptcstubs sparc64 file (3.97 KB, patch)
2004-03-05 13:42 PST, Peter Strömberg
no flags Details | Diff | Splinter Review
all patches/files in one tgz file (15.99 KB, application/octet-stream)
2004-03-05 22:08 PST, Peter Strömberg
no flags Details
moz-configure patch (916 bytes, patch)
2004-03-09 01:28 PST, Peter Strömberg
cls: review+
Details | Diff | Splinter Review
nspr configure patch (1.26 KB, patch)
2004-03-09 01:29 PST, Peter Strömberg
cls: review+
Details | Diff | Splinter Review
nspr prprf.c va_copy patch (not needed for NSPR 4.6/Mozilla 1.8 or newer) (518 bytes, patch)
2004-03-20 05:41 PST, Peter Strömberg
wtc: review+
Details | Diff | Splinter Review
all xptcalls for 1.8 in one tgz file + link in the Makefile, new (17.31 KB, application/gzip)
2007-08-07 17:04 PDT, Martynas Venckus
no flags Details
Xptcall files (against 1.8 branch) (29.56 KB, application/octet-stream)
2007-08-07 17:08 PDT, Frank Wein [:mcsmurf]
no flags Details
Makefile patch (1.8 branch) (2.35 KB, patch)
2007-08-08 11:24 PDT, Frank Wein [:mcsmurf]
benjamin: review+
Details | Diff | Splinter Review
Xptcall files patch (1.8 branch) (84.84 KB, patch)
2007-08-09 08:39 PDT, Frank Wein [:mcsmurf]
benjamin: review+
dveditz: approval1.8.1.8+
Details | Diff | Splinter Review
xptcinvoke_openbsd_amd64.cpp + license (7.29 KB, text/plain)
2007-08-09 09:18 PDT, Martynas Venckus
no flags Details
xptcstubs_openbsd_amd64.cpp + license + small fixes (8.71 KB, text/plain)
2007-08-09 09:20 PDT, Martynas Venckus
no flags Details

Description Peter Strömberg 2004-03-05 13:32:57 PST
User-Agent:       Mozilla/5.0 (X11; U; OpenBSD macppc; en-US; rv:1.6) Gecko/20040302 Firefox/0.8
Build Identifier: Mozilla/5.0 (X11; U; OpenBSD macppc; en-US; rv:1.6) Gecko/20040302 Firefox/0.8

mozilla now works on all major platforms in openbsd
the patches are from our ports tree and I would like to get them back into mozilla

Reproducible: Always
Steps to Reproduce:
Comment 1 Peter Strömberg 2004-03-05 13:34:33 PST
Created attachment 143027 [details] [diff] [review]
moz-configure patch
Comment 2 Peter Strömberg 2004-03-05 13:34:59 PST
Created attachment 143028 [details] [diff] [review]
ldap lber patch
Comment 3 Peter Strömberg 2004-03-05 13:35:14 PST
Created attachment 143029 [details] [diff] [review]
nspr configure patch
Comment 4 Peter Strömberg 2004-03-05 13:35:42 PST
Created attachment 143030 [details] [diff] [review]
nspr openbsd.cfg
Comment 5 Peter Strömberg 2004-03-05 13:36:03 PST
Created attachment 143031 [details] [diff] [review]
nspr openbsd.h patch
Comment 6 Peter Strömberg 2004-03-05 13:36:22 PST
Created attachment 143032 [details] [diff] [review]
NSS openbsd patch
Comment 7 Peter Strömberg 2004-03-05 13:36:37 PST
Created attachment 143033 [details] [diff] [review]
xptcall makefile patch
Comment 8 Peter Strömberg 2004-03-05 13:37:01 PST
Created attachment 143034 [details] [diff] [review]
complete alpha xptcinvoke file
Comment 9 Peter Strömberg 2004-03-05 13:37:28 PST
Created attachment 143035 [details] [diff] [review]
complete alpha xptcstubs file
Comment 10 Peter Strömberg 2004-03-05 13:37:46 PST
Created attachment 143036 [details] [diff] [review]
complete xptcinvoke amd64 file
Comment 11 Peter Strömberg 2004-03-05 13:38:08 PST
Created attachment 143037 [details] [diff] [review]
complete xptcstubs amd64 file
Comment 12 Peter Strömberg 2004-03-05 13:38:36 PST
Created attachment 143038 [details] [diff] [review]
complete xptcinvoke powerpc file
Comment 13 Peter Strömberg 2004-03-05 13:38:55 PST
Created attachment 143039 [details] [diff] [review]
powerpc patch
Comment 14 Peter Strömberg 2004-03-05 13:40:31 PST
Created attachment 143040 [details] [diff] [review]
complete xptcinvoke powerpc file
Comment 15 Peter Strömberg 2004-03-05 13:40:52 PST
Created attachment 143041 [details] [diff] [review]
complete xptcstubs asm powerpc file
Comment 16 Peter Strömberg 2004-03-05 13:41:14 PST
Created attachment 143042 [details] [diff] [review]
complete xptcstubs powerpc  file
Comment 17 Peter Strömberg 2004-03-05 13:41:33 PST
Created attachment 143043 [details] [diff] [review]
complete xptcinvoke asm sparc64 file
Comment 18 Peter Strömberg 2004-03-05 13:41:48 PST
Created attachment 143044 [details] [diff] [review]
complete xptcinvoke sparc64 file
Comment 19 Peter Strömberg 2004-03-05 13:42:01 PST
Created attachment 143045 [details] [diff] [review]
complete xptcstubs sparc64 file
Comment 20 Peter Strömberg 2004-03-05 13:42:53 PST
Comment on attachment 143039 [details] [diff] [review]
powerpc patch

oops, duplicate of 143038
Comment 21 Roland Mainz 2004-03-05 14:06:49 PST
Peter:
Is it possible to make one big all-in-one patch which includes the new files, too ?
Comment 22 cls 2004-03-05 14:27:35 PST
What versions of OpenBSD have these patches been tested with?  Some of the
changes (like the pthread changes) look like they wouldn't work with older
versions of OpenBSD (we worked there once a long time ago).  I'd like to see a
minimally supported version in a doc somewhere.  People never tell us when
things work, only then they break so we have no idea who's using what.   Also,
can you put a more descriptive label on the patches?  Several of those listed as
'patch' are actually whole files.

Comment 23 Peter Strömberg 2004-03-05 22:08:42 PST
Created attachment 143084 [details]
all patches/files in one tgz file
Comment 24 Peter Strömberg 2004-03-05 22:31:14 PST
-pthread appeared in openbsd 2.9 (more than three years ago)

In openbsd 3.4 - were we got moz to work for the first time (see #124958), moz
worked on alpha, i386, sparc and sparc64
Now on the upcomming 3.5, powerpc and amd64 are added
Comment 25 cls 2004-03-05 23:22:04 PST
Comment on attachment 143027 [details] [diff] [review]
moz-configure patch

Is there a reason that the MKSHLIB_FORCE_ALL & MKSHLIB_UNFORCE_ALL vars are
being explicitly unset?    I think all of the MKSHLIB related lines can be
removed completely.  The defaults listed on line 733 of configure.in should
just work.
Comment 26 cls 2004-03-05 23:40:40 PST
Comment on attachment 143029 [details] [diff] [review]
nspr configure patch

Is setting LDFLAGS necessary? $_PTHREAD_LDFLAGS is already added to $OS_LIBS.
Comment 27 Dan Mosedale (:dmose) 2004-03-06 00:49:00 PST
Comment on attachment 143028 [details] [diff] [review]
ldap lber patch

r+sr=dmose
Comment 28 Peter Strömberg 2004-03-06 07:02:43 PST
(In reply to comment #25)
> (From update of attachment 143027 [details] [diff] [review])
> Is there a reason that the MKSHLIB_FORCE_ALL & MKSHLIB_UNFORCE_ALL vars are
> being explicitly unset?    I think all of the MKSHLIB related lines can be
> removed completely.  The defaults listed on line 733 of configure.in should
> just work.

Yes, you are right, those four lines can go.
Comment 29 Peter Strömberg 2004-03-06 07:04:49 PST
(In reply to comment #26)
> (From update of attachment 143029 [details] [diff] [review])
> Is setting LDFLAGS necessary? $_PTHREAD_LDFLAGS is already added to $OS_LIBS.

Copy/paste from the ../configure.in patch, this line can also go away.
Comment 30 Wan-Teh Chang 2004-03-06 12:37:28 PST
Comment on attachment 143032 [details] [diff] [review]
NSS openbsd patch

r=wtc.

What's the difference between the outputs of 'uname -p'
and 'arch -s'?

Do we really need to pass -fPIC to the *linker* when we
build a shared library?
Comment 31 Wan-Teh Chang 2004-03-06 12:39:40 PST
Comment on attachment 143030 [details] [diff] [review]
nspr openbsd.cfg

r=wtc.

Is the removal of __arm32__ support intentional?
Comment 32 Wan-Teh Chang 2004-03-06 12:43:05 PST
Comment on attachment 143031 [details] [diff] [review]
nspr openbsd.h patch

r=wtc.

Is the removal of __arm32__ support intentional?

Do all the versions of OpenBSD that we care about
support the IPv6 socket API?
Comment 33 Peter Strömberg 2004-03-07 00:49:18 PST
(In reply to comment #30)
> (From update of attachment 143032 [details] [diff] [review])
> r=wtc.
> 
> What's the difference between the outputs of 'uname -p'
> and 'arch -s'?

Completely different :-)

bagheera:~ $ uname -p ; arch -s
Intel Pentium III ("GenuineIntel" 686-class, 512KB L2 cache)
i386

> 
> Do we really need to pass -fPIC to the *linker* when we
> build a shared library?

Yes
[from espie@openbsd.org]
"You must reuse -fPIC. We've had platforms in the past where this makes a
difference:
- the compiler may have to compile extra stub code (constructors, destructors,
for instance)
- the compiler may select different library path (we've had fpic/libgcc.a)"

Comment 34 Peter Strömberg 2004-03-07 00:54:26 PST
(In reply to comment #31)
> (From update of attachment 143030 [details] [diff] [review])
> r=wtc.
> 
> Is the removal of __arm32__ support intentional?
> 
Yes, support in openbsd was removed after 2.8 and that's really old.
Comment 35 Peter Strömberg 2004-03-07 02:05:10 PST
> Do all the versions of OpenBSD that we care about
> support the IPv6 socket API?

yes
Comment 36 cls 2004-03-08 21:52:07 PST
Peter, can you please attach an updated patch for the configure.in changes?  Thanks.
Comment 37 Peter Strömberg 2004-03-09 01:28:23 PST
Created attachment 143367 [details] [diff] [review]
moz-configure patch
Comment 38 Peter Strömberg 2004-03-09 01:29:00 PST
Created attachment 143368 [details] [diff] [review]
nspr configure patch
Comment 39 Roland Mainz 2004-03-09 15:08:58 PST
Assigning bug to author.
Comment 40 Wan-Teh Chang 2004-03-09 16:55:47 PST
Comment on attachment 143368 [details] [diff] [review]
nspr configure patch

Just a minor question: do we really need to define _THREAD_SAFE?
Is that done by the -pthread compiler flag?
Comment 41 Peter Strömberg 2004-03-09 23:24:26 PST
(In reply to comment #40)
> Just a minor question: do we really need to define _THREAD_SAFE?
> Is that done by the -pthread compiler flag?

-pthread defines _POSIX_THREADS
If moz doesn't check on _THREAD_SAFE (as a quick glimpse seems to indicate) it
can also go.
Comment 42 cls 2004-03-09 23:54:20 PST
All of the patches have been checked in (including respective client branches &
trunks) with the exception of the xptcall changes and the NSS patch.
Comment 43 cls 2004-03-10 02:27:03 PST
*** Bug 124958 has been marked as a duplicate of this bug. ***
Comment 44 Takanori MATSUURA 2004-03-10 21:10:48 PST
I came here from the bonsai checkin list at 03/09/2004 23:46.

Is this bug related to Bug 163013 and Bug 232742 ?

In the attachment 140309 [details] [diff] [review], amd64 platform is defined as "__x86_64__".
And a part of this attachment is merged into the trunk at 03/08/2004 19:10.

On the other hand, in the rev. 5.3 of
mozilla/directory/c-sdk/ldap/libraries/liblber/lber-int.h, 
amd64 platform is defined as "__amd64__".
Comment 45 Wolfgang Rosenauer [:wolfiR] 2004-03-10 21:32:34 PST
AMD64's architecture name is defined as x86-64 as comment #44 stated.
Please change this. It seems to be a race condition in check-ins ;-)
Comment 46 Peter Strömberg 2004-03-20 05:41:16 PST
Created attachment 144400 [details] [diff] [review]
nspr prprf.c va_copy patch (not needed for NSPR 4.6/Mozilla 1.8 or newer)

forgot this file
Comment 47 Wan-Teh Chang 2004-07-08 06:56:06 PDT
Comment on attachment 144400 [details] [diff] [review]
nspr prprf.c va_copy patch (not needed for NSPR 4.6/Mozilla 1.8 or newer)

r=wtc.	This patch is suitable for NSPR 4.5/Mozilla 1.7
or older.  In newer NSPR releases, I fixed this porting
problem by completely eliminating the VARARGS_ASSIGN
macro, so this patch is not needed there.
Comment 48 Mike Shaver (:shaver -- probably not reading bugmail closely) 2004-11-11 18:45:12 PST
Comment on attachment 143034 [details] [diff] [review]
complete alpha xptcinvoke file

Other than that we probably don't want to put more code under Netscape's
copyright (and as of 1998, no less -- this bug's not _that_ old!), this looks
OK.

Please fix the copyright and date before committing.
Comment 49 Brendan Eich [:brendan] 2005-11-02 17:30:09 PST
What can I do to help get this bug moving again?

/be
Comment 50 Brendan Eich [:brendan] 2007-08-07 16:20:12 PDT
Benjamin, Luser: can one of you take this and help get the patches updated and landed?

/be
Comment 51 Martynas Venckus 2007-08-07 17:04:02 PDT
Created attachment 275702 [details]
all xptcalls for 1.8 in one tgz file + link in the Makefile, new

Brendan, please CC r? the right people...
Comment 52 Frank Wein [:mcsmurf] 2007-08-07 17:08:10 PDT
Created attachment 275703 [details]
Xptcall files (against 1.8 branch)

Martynas Venckus provided a new patch against the 1.8 branch (trunk will follow). This ZIP file includes a patch for xpcom/reflect/xptcall/src/md/unix/Makefile.in and all the respective files for arm/sparc64/ppc/alpha/amd64.
Comment 53 Frank Wein [:mcsmurf] 2007-08-07 17:10:15 PDT
Comment on attachment 275703 [details]
Xptcall files (against 1.8 branch)

lack of communication :)
Comment 54 Brendan Eich [:brendan] 2007-08-07 18:40:49 PDT
One big zip file is not the way to get review. It's much better to split the patch up by module (http://www.mozilla.org/owners.html is still the source -- there's a single-field form in which you can type a relative source pathname to find which module a file belongs to) and request r? of the right people.

Honestly, I'm sorry this bug did not get action, but I'm not your patch review requesting, unzipping and splitting and reattaching slave. The owners and peers who failed you last time should probably do that, this once, to make up for inaction. But it's a two way street, so if mcsmurf or martynas could do it, even better.

Cc'ing dveditz, who can help bless 1.8 branch landings for porting changes.

/be
Comment 55 Brendan Eich [:brendan] 2007-08-07 18:43:18 PDT
Another approach: someone with commit access just unzip, verify that only ifdef'ed or otherwise build-configured-for-openbsd code is affected, ask dveditz to bless en-masse, and commit to the branch.

Trunk should probably be done the hard way.

/be
Comment 56 Frank Wein [:mcsmurf] 2007-08-08 11:24:38 PDT
Created attachment 275813 [details] [diff] [review]
Makefile patch (1.8 branch)

This is the Makefile change required for building, changes xpcom/reflect/xptcall/src/md/unix/Makefile.in. If this gets checked in, all the other new files need to be checked in, too.
Comment 57 Benjamin Smedberg AWAY UNTIL 2-AUG-2016 [:bsmedberg] 2007-08-09 07:15:07 PDT
Comment on attachment 275813 [details] [diff] [review]
Makefile patch (1.8 branch)

Boy I hate the OS_TEST usage, but it seems to be standard in this makefile... I'm pretty sure we should end up using TARGET_CPU instead.
Comment 58 Frank Wein [:mcsmurf] 2007-08-09 08:39:06 PDT
Created attachment 275976 [details] [diff] [review]
Xptcall files patch (1.8 branch)

This patch includes all the xptcall files needed for OpenBSD for the various platforms. I noticed the license header is missing in the amd64 files, those headers must of course be added before check-in (I didn't do it since I dunno who worked on this).
Martynas: Were you the only person working on the amd64 files?
Comment 59 Frank Wein [:mcsmurf] 2007-08-09 09:08:54 PDT
Dan Veditz: Would it be ok to check in the xptcall files patch on the 1.8 branch? Only OpenBSD is affected here. For the trunk a real review should be done I guess, but getting someone to review this patch for the 1.8 branch? Dunno if it is worth it, IMHO rather not.
Comment 60 Martynas Venckus 2007-08-09 09:18:14 PDT
Created attachment 275980 [details]
xptcinvoke_openbsd_amd64.cpp + license
Comment 61 Martynas Venckus 2007-08-09 09:20:37 PDT
Created attachment 275982 [details]
xptcstubs_openbsd_amd64.cpp + license + small fixes
Comment 62 Daniel Veditz [:dveditz] 2007-08-29 15:52:25 PDT
(In reply to comment #59)
> Dan Veditz: Would it be ok to check in the xptcall files patch on the 1.8
> branch? Only OpenBSD is affected here. For the trunk a real review should be
> done I guess, but getting someone to review this patch for the 1.8 branch?
> Dunno if it is worth it, IMHO rather not.

I don't know if getting a review is worth it to you or not, but it's not getting approved for the (more conservative) branches without one. On the other hand these aren't supported platforms so we're not going to be too conservative about untested code as long as it's been approved (reviewed) by the module owner.
Comment 63 Daniel Veditz [:dveditz] 2007-09-07 11:55:32 PDT
Comment on attachment 275976 [details] [diff] [review]
Xptcall files patch (1.8 branch)

please get this reviewed by a module owner or peer before asking for branch approval
Comment 64 Daniel Veditz [:dveditz] 2007-09-11 10:45:54 PDT
Comment on attachment 275976 [details] [diff] [review]
Xptcall files patch (1.8 branch)

approved for 1.8.1.7, a=dveditz for release-drivers
Comment 65 Martynas Venckus 2007-09-11 10:53:15 PDT
Comment on attachment 275982 [details]
xptcstubs_openbsd_amd64.cpp + license + small fixes

Please don't forget to commit this too, for amd64 support.
Comment 66 Martynas Venckus 2007-09-11 10:53:18 PDT
Comment on attachment 275980 [details]
xptcinvoke_openbsd_amd64.cpp + license

Please don't forget to commit this too, for amd64 support.
Comment 67 Benjamin Smedberg AWAY UNTIL 2-AUG-2016 [:bsmedberg] 2007-09-15 06:27:30 PDT
Comment on attachment 275980 [details]
xptcinvoke_openbsd_amd64.cpp + license

This should be part of the patch, and it's ok to land with the existing r+a
Comment 68 Frank Wein [:mcsmurf] 2007-09-29 14:14:26 PDT
I'll check this in soon.
Comment 69 Frank Wein [:mcsmurf] 2007-10-03 06:00:17 PDT
Checked in on the 1.8 branch.
Comment 70 Robert Sayre 2007-11-06 23:34:02 PST
Is this fixed?
Comment 71 Frank Wein [:mcsmurf] 2007-11-07 10:12:40 PST
Resolving as fixed. It is fixed on the 1.8.1 branch, but not on trunk because the patch needs updating for trunk.
Martynas: Please open a new bug for any trunk work.

Note You need to log in before you can comment on or make changes to this bug.