From mboxrd@z Thu Jan 1 00:00:00 1970 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 1164f8,438e2b92dfe10363 X-Google-Attributes: gid1164f8,public X-Google-ArrivalTime: 1992-05-29 07:53:26 PST Path: sparky!uunet!spool.mu.edu!umn.edu!news.cs.indiana.edu!bronze!mdchaney From: mdchaney@bronze.ucs.indiana.edu (M Darrin Chaney) Newsgroups: comp.sys.dec Subject: Re: what library do I use to make windows, portably between Ultrix & VMS? Keywords: X Motif VMS Message-ID: <1992May29.193819.18100@bronze.ucs.indiana.edu> Date: 29 May 92 19:38:19 GMT Article-I.D.: bronze.1992May29.193819.18100 References: <40825@sunquest.UUCP> Distribution: usa Organization: Indiana University In article <40825@sunquest.UUCP> terry@venus.sunquest.com (Terry R. Friedrichsen) writes: >klee@wsl.dec.com writes: > >>Mike Levin writes: > >>> I want to add a windows interface to my program. This program >>> works on Ultrix, SunOs, VMS, etc. What library (xlib?) should I use, >>> so that my window-making code is portble (i.e., compiles with minor >>> conditional compilation #ifdefs) between Unix and VMS with DecWindows? > >>Use Motif. It is available on all 3 of your platforms. Code often >>recompiles on each with no changes. > >Um. Wait. You can't compile on VMS without changes; at the very least >you've gotta fix up the #includes to include DEC's mongo .h files instead >of all the nice functionally-split ones you get from MIT. And then you've >gotta struggle with the symbols that just mysteriously aren't there. > >After that, yeah, code often recompiles on each with no changes. It even >links successfully. But then you gotta *run* it (unless you just write code >for typing practice :-). Here VMS loses again; code that works on several >Unix boxes mysteriously hangs, does weird stuff like draw incredibly tiny >windows instead of the nice sizes they should be, or ACCVIOs deep in the heart >of the X code somewhere. > >Upgrade to the latest version of VMS, and the set of symptoms is the same, >but the programs that cause them change places ... sigh. Even the O'Reilly >examples do this sort of thing, so it ain't just me ... > >At that point I just gave up on making my code work under VMS. > >(Let me interject here that I haven't tried this with Motif widgets, just >Athena ones. And I haven't tried since VMS 5.4 first came out ... so if >things have improved since then, I wouldn't know about it.) Well, thanks for this bit of wisdom. You've astounded me. Anyway, you'd better come tell my VMS box all this, because it's running Motif just fine. The demos that come with Motif under VMS, in sys$common:[decw$motif.demos], are *exact* duplicates of the demos that come with Motif for Ultrix, in /usr/lib/DXM/demos. By *exact*, I mean line for line. And they compile and run under both platforms just fine. If you write your programs correctly, there will be no problems. Remember that VAX-C isn't ANSI compliant, but neither is cc. You need to write your code for cc if you want the widest audience. Anyway, the point is, correctly written code doesn't have to be "ported" to VMS, just ftp'd and recompiled. The same code should work under VMS, Ultrix, and HP-UX without changes. The Motif demos do... Darrin -- mdchaney@iubacs mdchaney@bronze.ucs.indiana.edu mdchaney@rose.ucs.indiana.edu "It's a marvel of vegetable containment..."