FennelEclipse
From Eigenpedia
Instructions for setting up Eclipse for use in Fennel development (experimental, lots of gotchas):
- Get a standard command-line build of Fennel working.
- Download and unpack a copy of Eclipse SDK 3.1
- Start Eclipse
- Install the CDT using the Install from the Update Site method
- From the top menu, choose File->New->Project
- Open the C++ tree node and choose Standard Make C++ Project
- Click Next
- Enter fennel for project name
- For Project contents, uncheck Use default
- Enter the path to fennel (e.g. /home/calvin/open/fennel)
- Click Finish and tell it to remember the perspective
- Right-click the project and choose Properties
- Select the C/C++ Make Project tree node
- Under Workbench Build Behavior, uncheck all of the automatic build preferences (Build, Rebuild, Clean), unless you are a masochist
- Click Apply
- Under C/C++ Include Paths, add open, open/thirdparty/boost, and open/thirdparty/stlport
- Under C/C++ Indexer, choose No Indexer (we haven't figured out how to get either indexer working correctly, possibly because of our namespace macros)
- Click OK
- From the top menu, choose Window->Preferences
- Select the C/C++ subtree
- Select the Editor subtree
- Check Insert spaces for tabs
- Click Apply and OK
- Install the Perforce plugin
- From the Package Explorer, right-click the fennel project to get a pop-up menu
- Choose Team->Share Project
- Select Perforce for repository type and click Next
- Enter connection information for your client and click Finish
To debug a unit test:
- Under the Binaries subtree, select a test executable
- Right-click and choose Debug As->Debug Local C/C++ Application
- Choose GDB Debugger (not GDB Server)
The instructions below are for debugging Fennel running inside of Farrago's JVM, but they don't work yet.
- Start by following the instructions from the Farrago developer FAQ up until you see "Waiting for debugger"; note the process ID (pid)
- Select the fennel project in the Package Explorer
- From the top menu, choose Run->Debug
- Choose the C/C++ Attach to Local subtree
- Right-click New
- In the Debugger tab, choose GDB Debugger from the dropdown
- Click Apply
- Click Debug
- A list of processes should appear; the one you want will probably be named java, but use the process ID to discriminate if more than one matches
- A message about an internal error during launch will appear; this is probably why nothing works correctly from here on
- In the empty Console pane at the bottom, enter the correct resume command from the FAQ (e.g. signal SIGHUP) and hit return; a bunch of thread info should appear
- After this, the console no longer responds to commands, and setting a breakpoint will cause a SIGINT which brings everything to a grinding halt

