1 Return-Path: dale@felix.dircon.co.uk
2 Return-Path: <dale@felix.dircon.co.uk>
3 Received: from eagle.is.lmsc.lockheed.com by rocket (SPCOT.6)
4 id AA07582; Wed, 30 Mar 94 21:26:48 EST
5 Received: from felix.dircon.co.uk by eagle.is.lmsc.lockheed.com (5.65/Ultrix4.3-C)
6 id AA27884; Wed, 30 Mar 1994 18:24:30 -0800
7 Received: from ISOlde.dale.co.uk by tristan.dale.co.uk with smtp
8 (Linux Smail3.1.28.1 #25) id m0pm2IB-0002kOC; Wed, 30 Mar 94 16:34 BST
9 Received: by ISOlde.dale.co.uk (Linux Smail3.1.28.1 #25)
10 id m0pm2IP-000JHaC; Wed, 30 Mar 94 16:35 BST
11 Message-Id: <m0pm2IP-000JHaC@ISOlde.dale.co.uk>
12 Date: Wed, 30 Mar 94 16:35 BST
13 From: Pete.Chown@dale.dircon.co.uk
14 Subject: fvwm, copyright infringement, m4, etc...
16 I came up with a hack in m4 to get round the problem where you get
17 substitution for ordinary words, like 'include'. I wanted to
18 substitute a # onto the beginning of every command, so you say
19 #include as in cpp. I couldn't do that because only the underscore
20 and the alphabetics are recognised by m4 as being legitimate in
21 identifiers. However, I put an underscore onto the beginning, and
22 that seems to work quite well.
24 Given that you refer to the same problem in the documentation for
25 fvwm, I thought I would send the hack to you:
27 ------ snip ------ snip ------ snip ------ snip ------ snip ------ snip
33 # We now add an underscore onto the front of all the builtins, to prevent
34 # unexpected conflicts with words in the text. The following gross hack does
35 # this. Understand it if you can... ;-)
37 define(def,defn(@`define@'))
38 define(definition,defn(@`defn@'))
39 define(remove,defn(@`undefine@'))
40 define(alias,@`def(@`$2@',definition(@`$1@'))@')
41 define(hack,@`alias(@`$1@',@`_$1@') remove(@`$1@')@')
89 _undefine(@`definition@')
94 ------ snip ------ snip ------ snip ------ snip ------ snip ------ snip
96 (I redefine the quotes as well, because I find that the ordinary
97 single quote characters are much too common in text that you want to
100 One problem with this script is that if someone extends m4 by adding a
101 new builtin command foo, say, then it will not get an underscore
102 prepended; this is because you can't get m4 to give you a complete
103 list of builtins. For the same reason, the script will probably give
104 trouble with System V m4, because it won't have definitions for the
107 Anyway, do what you want with the script - if you think it might be
108 useful to fvwm users you are more than welcome to include it in the
109 distribution. Or file it away in /dev/null if you are unimpressed.
111 I was rather concerned by the little bit of Motif that is getting
112 distributed along with fvwm. It may be only a couple of pages out of
113 10M (is Motif really that big? Argh!) but that will not stop you
114 getting sued. If the Motif people start to get the idea that they are
115 not selling so many copies because people use fvwm instead of twm,
116 they will sue you for copyright infringement - not because there is
117 any particular justice to them protecting two pages of code, but just
118 because it is the easiest way of making you go away.
120 It is correct that there is no copyright in structures, only in the
121 source code that defines them. So you would be quite within your
122 rights to rewrite the offending two pages, and then I can't see that
123 there is anything that the Motif people could do.
125 -------------------------------------------------------------------------------
126 Pete.Chown@dale.dircon.co.uk "The Pen is mightier than the Quill"