Andersbakken / rtags

A client/server indexer for c/c++/objc[++] with integration for Emacs based on clang.
http://www.rtags.net
GNU General Public License v3.0
1.83k stars 252 forks source link

Creating byte-compiled Emacs lisp #1411

Open haluk opened 3 years ago

haluk commented 3 years ago

Describe the bug I have gccemacs installed and I tried to build rtags from aur. I got the following error while creating "Creating byte-compiled Emacs lisp".

Eager macro-expansion failure: (wrong-number-of-arguments (3 . 4) 2) Eager macro-expansion failure: (wrong-number-of-arguments (3 . 4) 2) Debugger entered--Lisp error: (wrong-number-of-arguments (3 . 4) 2)

f(compiled-function (obsolete-name current-name when &optional docstring) "Set OBSOLETE-NAME's function definition to CURRENT-NAME and mark it obsolete.\n\n(define-obsolete-function-alias \='old-fun \='new-fun \"22.1\" \"old-fun's doc.\")\n\nis equivalent to the following two lines of code:\n\n(defalias \='old-fun \='new-fun \"old-fun's doc.\")\n(make-obsolete \='old-fun \='new-fun \"22.1\")\n\nWHEN should be a string indicating when the function was first\nmade obsolete, for example a date or a release number.\n\nSee the docstrings of defalias' andmake-obsolete' for more details." #<bytecode 0x15d0cae283d681dd>)('rtags-start-process-maybe 'rtags-start-process-unless-running)

(define-obsolete-function-alias 'rtags-start-process-maybe 'rtags-start-process-unless-running) load-with-code-conversion("/home/hd/.cache/yay/rtags/src/rtags/src/rtags.el" "/home/hd/.cache/yay/rtags/src/rtags/src/rtags.el" nil t) command-line-1(("-l" "/home/hd/.cache/yay/rtags/src/rtags/src/compile-sh..." "-l" "/home/hd/.cache/yay/rtags/src/rtags/src/rtags.el" "-f" "batch-byte-compile" "/home/hd/.cache/yay/rtags/src/rtags/src/company-rt...")) command-line() normal-top-level()

make[2]: [src/CMakeFiles/emacs_byte_compile_company-rtags.el.dir/build.make:80: src/company-rtags.elc] Error 255 make[1]: [CMakeFiles/Makefile2:1142: src/CMakeFiles/emacs_byte_compile_company-rtags.el.dir/all] Error 2 make: *** [Makefile:160: all] Error 2 ==> ERROR: A failure occurred in build().

Environment (please complete the following information):

kentbull commented 3 years ago

I have this same issue OS/Version: OS X BigSur 11.2.3 RTags: cloned master today. 2.40+ Emacs: brew installed emacs 28.1 LLVM/Clang: 11.1.0

rtags/build > make                                                                                                                                                                                                          (master)rtags
Scanning dependencies of target emacs_byte_compile_rtags-xref.el
[  1%] Copying /Users/kbull/code/c++/rtags/src/rtags-xref.el -> /Users/kbull/code/c++/rtags/build/src/rtags-xref.el
[  2%] Creating byte-compiled Emacs lisp /Users/kbull/code/c++/rtags/build/src/rtags-xref.elc
Eager macro-expansion failure: (wrong-number-of-arguments (3 . 4) 2)
Eager macro-expansion failure: (wrong-number-of-arguments (3 . 4) 2)
Debugger entered--Lisp error: (wrong-number-of-arguments (3 . 4) 2)
  #f(compiled-function (obsolete-name current-name when &optional docstring) "Set OBSOLETE-NAME's function definition to CURRENT-NAME and mark it obsolete.\n\n(define-obsolete-function-alias \\='old-fun \\='new-fun \"22.1\" \"old-fun's doc.\")\n\nis equivalent to the following two lines of code:\n\n(defalias \\='old-fun \\='new-fun \"old-fun's doc.\")\n(make-obsolete \\='old-fun \\='new-fun \"22.1\")\n\nWHEN should be a string indicating when the function was first\nmade obsolete, for example a date or a release number.\n\nSee the docstrings of `defalias' and `make-obsolete' for more details." #<bytecode 0x155f8ed4de4828bd>)('rtags-start-process-maybe 'rtags-start-process-unless-running)
  (define-obsolete-function-alias 'rtags-start-process-maybe 'rtags-start-process-unless-running)
  eval-buffer(#<buffer  *load*> nil "/Users/kbull/code/c++/rtags/src/rtags.el" nil t)  ; Reading at buffer position 206096
  load-with-code-conversion("/Users/kbull/code/c++/rtags/src/rtags.el" "/Users/kbull/code/c++/rtags/src/rtags.el" nil t)
  load("/Users/kbull/code/c++/rtags/src/rtags.el" nil t)
  command-line-1(("-l" "/Users/kbull/code/c++/rtags/src/compile-shim.elisp" "-l" "/Users/kbull/code/c++/rtags/src/rtags.el" "-f" "batch-byte-compile" "/Users/kbull/code/c++/rtags/build/src/rtags-xref.e..."))
  command-line()
  normal-top-level()

make[2]: *** [src/rtags-xref.elc] Error 255
make[1]: *** [src/CMakeFiles/emacs_byte_compile_rtags-xref.el.dir/all] Error 2
make: *** [all] Error 2
kentbull commented 3 years ago

@haluk I suggest you add Creating byte-compiled Emacs lisp to this issue's title for clarity.

kentbull commented 3 years ago

This is resolved by https://github.com/Andersbakken/rtags/pull/1412

kentbull commented 3 years ago

This was properly resolved by the following commit: https://github.com/Andersbakken/rtags/commit/63f18acb21e664fd92fbc19465f0b5df085b5e93 Now this issue can be closed.