all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Chong Yidong <cyd@stupidchicken.com>
To: emacs-devel@gnu.org
Subject: Re: Compiled files without sources????
Date: Sun, 31 Jul 2011 20:14:37 -0400	[thread overview]
Message-ID: <87y5zeng2a.fsf@stupidchicken.com> (raw)
In-Reply-To: <87pqkqqbyc.fsf@engster.org> (David Engster's message of "Mon, 01 Aug 2011 01:15:07 +0200")

David Engster <deng@randomsample.de> writes:

>> So what would be entailed to let upstream CEDET generate compiled
>> grammars directly usable in Emacs?  Why don't they work out of the box
>> when the parser runtime is ostensibly what is present in upstream
>> CEDET?  Can the differences be factored out into variables?
>
> The most important change is the 8+3 file renaming; this is replicated
> in the file-rename branch. Also, the CEDET compilation process was
> complicated and dependant on autoloads from EIEIO classes and methods,
> which Emacs doesn't support and which therefore was also removed; Lluís
> has written a completely new Makefile for that.

It's actually not as complicated as that.  The major changes between the
compiled grammars and the files actually included in Emacs are (i)
renaming of the files, (ii) fixed-up copyright headers, (iii) changes in
the `feature' keyword of the file plus the filename, and (iv)
re-ordering of some code chunks in the file to avoid some byte
compilation warnings (IIRC).  These changes are not really practical to
do except by hand.

Here is an example, comparing the compiled from etc/grammars/make.by to
lisp/cedet/semantic/bovine/make-by.el on the trunk.  (The bovine parser
generator is currently broken on the trunk, because of a bug related to
the "backquote not followed by a space" change, so generation was
actually done with Emacs 23.)


*** trunk/etc/grammars/semantic-make-by.el	2011-07-31 19:58:28.774752136 -0400
--- trunk/lisp/cedet/semantic/bovine/make-by.el	2011-07-30 20:08:50.987784021 -0400
***************
*** 1,36 ****
! ;;; semantic-make-by.el --- Generated parser support file
  
! ;; Copyright (C) 1999-2011 Free Software Foundation, Inc.
  
! ;; Author: Chong Yidong <cyd@furball>
! ;; Created: 2011-07-31 19:58:28-0400
! ;; Keywords: syntax
! ;; X-RCS: $Id$
  
! ;; This file is not part of GNU Emacs.
  
! ;; This program is free software; you can redistribute it and/or
! ;; modify it under the terms of the GNU General Public License as
! ;; published by the Free Software Foundation, either version 3 of
! ;; the License, or (at your option) any later version.
! 
! ;; This software is distributed in the hope that it will be useful,
  ;; but WITHOUT ANY WARRANTY; without even the implied warranty of
! ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
! ;; General Public License for more details.
! ;;
  ;; You should have received a copy of the GNU General Public License
! ;; along with this program.  If not, see <http://www.gnu.org/licenses/>.
  
  ;;; Commentary:
  ;;
! ;; PLEASE DO NOT MANUALLY EDIT THIS FILE!  It is automatically
! ;; generated from the grammar file make.by.
! 
! ;;; History:
! ;;
  
  ;;; Code:
  \f
  ;;; Prologue
  ;;
--- 1,31 ----
! ;;; semantic/bovine/make-by.el --- Generated parser support file
  
! ;; Copyright (C) 1999-2004, 2008-2011  Free Software Foundation, Inc.
  
! ;; This file is part of GNU Emacs.
  
! ;; GNU Emacs is free software: you can redistribute it and/or modify
! ;; it under the terms of the GNU General Public License as published by
! ;; the Free Software Foundation, either version 3 of the License, or
! ;; (at your option) any later version.
  
! ;; GNU Emacs is distributed in the hope that it will be useful,
  ;; but WITHOUT ANY WARRANTY; without even the implied warranty of
! ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
! ;; GNU General Public License for more details.
! 
  ;; You should have received a copy of the GNU General Public License
! ;; along with GNU Emacs.  If not, see <http://www.gnu.org/licenses/>.
  
  ;;; Commentary:
  ;;
! ;; This file was generated from etc/grammars/make.by.
  
  ;;; Code:
+ 
+ (require 'semantic/lex)
+ (eval-when-compile (require 'semantic/bovine))
+ 
  \f
  ;;; Prologue
  ;;
***************
*** 70,76 ****
  
  (defconst semantic-make-by--parse-table
    `(
!     (bovine-toplevel 
       (Makefile)
       ) ;; end bovine-toplevel
  
--- 65,71 ----
  
  (defconst semantic-make-by--parse-table
    `(
!     (bovine-toplevel
       (Makefile)
       ) ;; end bovine-toplevel
  
***************
*** 385,399 ****
  	semantic-flex-keywords-obarray semantic-make-by--keyword-table
  	))
  
! \f
! ;;; Analyzers
! ;;
! (require 'semantic-lex)
! 
! \f
! ;;; Epilogue
! ;;
! 
! (provide 'semantic-make-by)
  
! ;;; semantic-make-by.el ends here
--- 380,385 ----
  	semantic-flex-keywords-obarray semantic-make-by--keyword-table
  	))
  
! (provide 'semantic/bovine/make-by)
  
! ;;; semantic/bovine/make-by.el ends here



  reply	other threads:[~2011-08-01  0:14 UTC|newest]

Thread overview: 130+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-03-10  5:34 Emacs 23.3 released Chong Yidong
2011-03-10  8:58 ` Bastien
2011-03-10 16:07 ` Stefan Monnier
2011-03-10 16:22   ` David Kastrup
2011-03-10 16:54     ` Chong Yidong
2011-03-10 17:54       ` David Kastrup
2011-03-10 18:00         ` Lennart Borgman
2011-03-10 19:17           ` State of the CEDET merge (was: Emacs 23.3 released) David Engster
2011-03-11 14:29             ` State of the CEDET merge Lluís
2011-03-11 14:45               ` David Kastrup
2011-03-11 15:48                 ` Lluís
2011-03-12  9:42                   ` David Kastrup
2011-03-12 13:15                     ` Eric M. Ludlam
2011-03-12 20:49                       ` Stefan Monnier
2011-03-13 14:13                         ` Ted Zlatanov
2011-03-14 19:55                           ` Lluís
2011-03-14 20:39                             ` Lennart Borgman
2011-03-14 22:28                               ` Lluís
2011-03-13 15:13                   ` David Engster
2011-03-14 20:08                     ` Lluís
2011-03-15  1:33                       ` Stefan Monnier
2011-03-16 14:03                         ` Lluís
2011-03-16 15:24                           ` Stefan Monnier
2011-03-16 15:30                             ` David Kastrup
2011-03-16 20:23                               ` Lluís
2011-03-18 17:43                             ` Eli Zaretskii
2011-03-18 17:51                               ` Eli Zaretskii
2011-07-24  8:14                     ` David Kastrup
2011-07-24 10:01                       ` David Engster
2011-07-24 13:11                         ` David Kastrup
2011-07-27  2:46                         ` Chong Yidong
2011-07-27  6:25                           ` David Kastrup
2011-07-27  7:21                             ` David Engster
2011-07-27  7:39                               ` David Kastrup
2011-07-27  8:06                                 ` Andreas Röhler
2011-07-27  8:24                                   ` David Kastrup
2011-07-27 16:14                                 ` Compiled files without sources???? Richard Stallman
2011-07-27 17:57                                   ` David Kastrup
2011-07-28  5:53                                     ` Richard Stallman
2011-07-28 10:02                                       ` Paul Eggert
2011-07-28 23:00                                         ` Richard Stallman
2011-07-28 23:28                                           ` Paul Eggert
2011-07-29 14:32                                             ` Milan
2011-07-29 22:33                                             ` Chong Yidong
2011-07-30  2:12                                               ` Chong Yidong
2011-07-30  4:36                                                 ` Richard Stallman
2011-07-30 20:33                                                   ` Chong Yidong
2011-07-30 23:20                                                     ` Thien-Thi Nguyen
2011-07-31  4:46                                                       ` Tim Cross
2011-07-31 11:03                                                         ` David Kastrup
2011-07-31 13:29                                                           ` Tim Cross
2011-07-31 17:45                                                             ` Andreas Röhler
2011-07-31 17:55                                                             ` Stephen J. Turnbull
2011-07-31 18:06                                                               ` Lars Ingebrigtsen
2011-07-31 20:06                                                                 ` Stephen J. Turnbull
2011-07-31 21:47                                                                   ` David Engster
2011-07-31 22:36                                                                     ` David Kastrup
2011-07-31 23:15                                                                       ` David Engster
2011-08-01  0:14                                                                         ` Chong Yidong [this message]
2011-07-31 23:10                                                                   ` Tim Cross
2011-08-01 12:33                                                                     ` Stephen J. Turnbull
2011-08-01 13:14                                                                       ` David Kastrup
2011-08-01 14:37                                                                         ` Stephen J. Turnbull
2011-08-01 14:42                                                                           ` Thien-Thi Nguyen
2011-08-02  0:13                                                                       ` Richard Stallman
2011-08-02  7:10                                                                         ` David Kastrup
2011-08-03  4:17                                                                           ` Richard Stallman
2011-08-02  0:13                                                                       ` Letting the users off the hook Richard Stallman
2011-08-03  4:16                                                                       ` Richard Stallman
2011-08-03  6:50                                                                         ` Stephen J. Turnbull
2011-08-03 19:18                                                                           ` Richard Stallman
2011-07-31 23:56                                                                   ` Compiled files without sources???? Richard Stallman
2011-07-31 16:19                                                     ` Richard Stallman
2011-07-31 17:04                                                       ` Chong Yidong
2011-07-31 23:56                                                         ` Richard Stallman
2011-08-01  3:08                                                           ` Chong Yidong
2011-08-01 21:28                                                             ` Replacing tarballs on-the-fly (was: Re: Compiled files without sources????) Ulrich Mueller
2011-08-02 16:09                                                               ` Replacing tarballs on-the-fly Chong Yidong
2011-08-02 17:43                                                                 ` Ulrich Mueller
2011-08-03  4:17                                                                   ` Richard Stallman
2011-08-03 20:31                                                                     ` Chong Yidong
2011-08-02  0:13                                                             ` Compiled files without sources???? Richard Stallman
2011-08-02 15:56                                                             ` Chong Yidong
2011-08-03  4:16                                                               ` Richard Stallman
2011-07-30  4:35                                               ` Richard Stallman
2011-07-29 16:25                                   ` Evgeny M. Zubok
2011-07-29 16:37                                     ` David Kastrup
2011-07-29 23:40                                     ` Richard Stallman
2011-07-30 12:56                                       ` Evgeny M. Zubok
2011-07-30 13:25                                         ` David Kastrup
2011-07-30 20:55                                         ` Chong Yidong
2011-07-31 16:19                                           ` Richard Stallman
2011-03-10 16:45   ` Emacs 23.3 released Juanma Barranquero
2011-03-11  4:26     ` Stefan Monnier
2011-03-11  4:42       ` Juanma Barranquero
2011-03-11  9:44       ` Andreas Schwab
2011-03-11 20:18         ` Stefan Monnier
2011-03-11 23:03           ` Andreas Schwab
2011-03-12  0:03             ` Juanma Barranquero
2011-03-12  1:38               ` Stefan Monnier
2011-03-10 19:21   ` Thierry Volpiatto
2011-03-11  4:20     ` Stefan Monnier
2011-03-11  7:14       ` Thierry Volpiatto
2011-03-12  3:35         ` Stefan Monnier
2011-03-12 12:23           ` Juanma Barranquero
2011-03-14 14:10             ` Stefan Monnier
2011-03-14 14:52               ` Juanma Barranquero
2011-03-14 15:51                 ` Lexbind (was: Emacs 23.3 released) Stefan Monnier
2011-03-17  1:59                   ` Juanma Barranquero
2011-03-17 10:28                     ` Eli Zaretskii
2011-03-17 12:22                       ` Juanma Barranquero
2011-03-17 15:13                         ` Juanma Barranquero
2011-03-17 16:07                           ` Eli Zaretskii
2011-03-17 18:06                             ` Juanma Barranquero
2011-03-17 19:24                               ` Eli Zaretskii
2011-03-17 19:46                                 ` Juanma Barranquero
2011-03-19  0:54                                 ` Juanma Barranquero
2011-03-19  8:35                                   ` Eli Zaretskii
2011-03-19  9:28                                     ` Juanma Barranquero
2011-03-17 20:01                     ` Lexbind Stefan Monnier
2011-03-17 22:07                       ` Lexbind Wojciech Meyer
2011-03-17 23:29                       ` Lexbind Juanma Barranquero
2011-03-18  7:39                         ` Lexbind joakim
2011-03-10 19:27   ` Emacs 23.3 released Mike Mattie
2011-03-10 19:56   ` Glenn Morris
2011-03-11  8:45   ` Eli Zaretskii
2011-03-11 16:56     ` Chong Yidong
2011-03-11 20:19     ` Stefan Monnier
2011-03-10 18:57 ` Chong Yidong
2011-03-12  9:28   ` updating web manuals [Re: " Jim Meyering

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87y5zeng2a.fsf@stupidchicken.com \
    --to=cyd@stupidchicken.com \
    --cc=emacs-devel@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.