Path: utzoo!utgpu!jarvis.csri.toronto.edu!rutgers!apple!bloom-beacon!tut.cis.ohio-state.edu!unmvax!ncar!husc6!spdcc!ima!compilers-sender From: les@chinet.chi.il.us (Leslie Mikesell) Newsgroups: comp.compilers Subject: Re: Encripted source as an ANDF Message-ID: <4004@ima.ima.isc.com> Date: 28 May 89 18:41:19 GMT References: <3963@ima.ima.isc.com> <3978@ima.ima.isc.com> Sender: compilers-sender@ima.ima.isc.com Reply-To: les@chinet.chi.il.us (Leslie Mikesell) Organization: Chinet - Public Access Unix Lines: 42 Approved: compilers@ima.UUCP In article <3978@ima.ima.isc.com> jeffb@grace.cs.washington.edu (Jeff Bowden) writes: >>PROBLEM: what to do about things like putc(), which are macros >I was going to post this objection. Since Mr. Spencer beat me to it, I will >offer a solution (so someone else can tear *it* apart). > >1) Write a preprocessor which, in addition to obfuscating, >replaces #include with some goop that cpp will leave alone but will >indicate the name (e.g. extern int _foo_h();) How about a better approach altogether? Instead of requiring all manufactures to produce an obfucated code compiler, and all end users to maintain the resources to store and run the code and compiler, why not suggest that the manufacturers that want applications to be available for their machines provide a code-generator and libraries for a standard compiler with no restrictions on distribution. That way the program writer does not have to have access to the target machine or spend a fortune to buy a cross-compiler that may act differently from the standard version. This relieves the burden from the end user and places it where it belongs. It would prevent the end user from compiling a copy of a previously purchased program for a new environment by himself but I suspect the the program suppliers would not see that as a real problem. The need for testing still applies, of course, but the steps required to do so are not increased by this approach. Can anyone comment on how far GNU C is from being a suitable platform for acting as a multi-machine cross compiler? Les Mikesell [It seems to me that this proposal misses the point -- my understanding of ANDF is to permit a single version of a program to exist that, probably as part of the installation process, is turned into something executable on whatever the local machine is without the vendor having to create N different versions for N machines. -John] [From les@chinet.chi.il.us (Leslie Mikesell)] -- Send compilers articles to compilers@ima.isc.com or, perhaps, Levine@YALE.EDU Plausible paths are { decvax | harvard | yale | bbn}!ima Please send responses to the originator of the message -- I cannot forward mail accidentally sent back to compilers. Meta-mail to ima!compilers-request