Getting started with CEDET
Asked Answered
R

1

7

Try as I might, I can't get CEDET to do anything. Emacs 24.3. I downloaded the most recent CEDET snapshot. I took Alex Ott's setup file from the bottom of his (not so) Gentle Introduction, and changed the first line to point to my cedet-bzr.

I visited hello_world.cpp. I execute M-x semantic-mode.

Now what do I do? Should anything look different? (It doesn't.)

A glance at Alex's setup file suggests that C-c? should do something, but Emacs complains that that key combination is not bound. I really need some hand-holding here!

Edit: I really think the problem might be: "What do I do next?" How do I know it's installed and ready? What should I expcect? Should there be new menu items? Do I have to do something to turn it on? What should my first steps be? Right now, Emacs looks and behaves as if nothing has happened, but I may not be trying the right things. More generally: how do I use it?

Edit #2 (still using Alex's setup file)

  1. It works on Kubuntu if I change the load directory to .../cedet-bzr/trunk as opposed to .../cedet-bzr.
  2. No luck yet at all on OS X. In an attempt to use the built-in version I've tried pointing directly at the cedet directory within the Emacs.app bundle. Building the snapshot version outside of the bundle throws warnings: "Insecure world writable dir /Library/Frameworks in PATH, mode 040777", and there are no changes to the menus.
  3. In Cygwin, I had to comment out the references to "eassist" and "java", and with that I have two new menus: Development and SRecorder.
Repair answered 28/5, 2013 at 18:30 Comment(4)
Have you compiled CEDET?Boyne
Is it Emacs 24.3 issue ? I have CEDET working on 23.2.1.Kozlowski
Yes, it's compiled. No difference Emacs 23 or 24, built-in or standalone. See my edit to the O.P.Repair
Check "Senator" in menu items. Senator = semantic-navigator.Kozlowski
T
1

Here's my setup on emacs 24.3.1 on ubuntu 13.04:

(load "~/cedet-snapshot/cedet-devel-load.el")
(semantic-add-system-include "~/misc/include/" 'c++-mode)
(set-default 'semantic-case-fold t)

Here, ~/misc/include/ refers to the includes of some library that you could be using that isn't installed to /usr/include/.

I enable 'semantic-mode occasionally since it can be slow, but after it's enabled, 'semantic-ia-complete-symbol works.

UPD

I was installing a fresh Ubuntu on my new SSD and I've discovered that CEDET stopped working. Here's how I got it back on the track:

cd ~/.emacs.d/semanticdb
rm -rf *

Then in a C++ buffer M-x semantic-force-refresh. It may ask you something about debugging the hooks, just say type y.

Teressaterete answered 4/6, 2013 at 8:0 Comment(3)
Is that your entire setup for cedet? If I use yours on OS X (pointing to my cedet-devel-load.el) I get nothing. No change in menus, M-x seman[tab] returns no completions. sigh.Repair
Oh ... I should have asked first: what is in ~/misc/include ? I'll have to find the equivalent on my system.Repair
The only essential command listed here is the first line, (load ...), which loads the dev CEDET version. If you run cedet-version and do not see 'ok' in the file column, then the load command is not being run at all or you are missing an error message. Try printing something in the file and see if it shows up in the mini-buffer using (message "Hello world!"). Also try running emacs --debug-initDesideratum

© 2022 - 2024 — McMap. All rights reserved.