X-Spam-Check-By: sourceware.org X-IronPort-AV: i="3.99,317,1131339600"; d="scan'208"; a="148156259:sNHT26472526" To: cygwin AT cygwin DOT com, =?utf-8?Q?Ren=C3=A9?= Berber Subject: Re: executable = exe + data Mail-Copies-To: never Reply-To: sds AT gnu DOT org X-Attribution: Sam X-Disclaimer: You should not expect anyone to agree with me. From: Sam Steingold In-Reply-To: (=?utf-8?Q?Ren=C3=A9?= Berber's message of "Fri, 30 Dec 2005 01:16:52 -0600") References: Mail-Followup-To: cygwin AT cygwin DOT com, =?utf-8?Q?Ren=C3=A9?= Berber Date: Sat, 31 Dec 2005 18:22:29 -0500 Message-ID: User-Agent: Gnus/5.11 (Gnus v5.11) Emacs/22.0.50 (windows-nt) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm Precedence: bulk List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from quoted-printable to 8bit by delorie.com id jBVNNl7v014913 > * René Berber [2005-12-30 01:16:52 -0600]: > > Sam Steingold wrote: > >> the only idea I have had so far is this: >> >> char string[]="this is a buffer into which I will be writing my stuff"; >> size_t my_length = atol(string); >> >> and then have a post-processor edit lisp.exe and replace the contents of >> string with the actual lisp.exe file length (I need the long initial >> junk there so that the post-processor will be able to find where it is to >> write the length). > > The steps would be something like: > > 1. Compile program, say "gcc -mwindows h.c -o h"; > > 2. Record file size; > > 3. Concatenate program and data, say "cat h.exe h.data > longh.exe"; > > 4. Run through post-processor (with longh.exe and size as parameter). so, the only reasonable way is to search the executable for the magic line... I hoped that there is some other way to find out where the variable is stored in the executable file. Thanks! -- Sam Steingold (http://www.podval.org/~sds) running w2k http://www.honestreporting.com http://www.camera.org http://www.iris.org.il http://www.memri.org/ http://www.jihadwatch.org/ Despite the raising cost of living, it remains quite popular. -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/