Presentation is loading. Please wait.

Presentation is loading. Please wait.

Building and debugging Electric 1 Building and debugging GNU Electric version 8.08 by Java SDK & Eclipse (Ganymede) by Kazzz (a Japanese engineer) May.

Similar presentations


Presentation on theme: "Building and debugging Electric 1 Building and debugging GNU Electric version 8.08 by Java SDK & Eclipse (Ganymede) by Kazzz (a Japanese engineer) May."— Presentation transcript:

1 Building and debugging Electric 1 Building and debugging GNU Electric version 8.08 by Java SDK & Eclipse (Ganymede) by Kazzz (a Japanese engineer) May 11 th, 2009 (created the original) May 30 th, 2009 (modified for posting to ) June 2 nd, 2009 (added information on Java 3D environment)

2 Building and debugging Electric 2 Objectives ① To build GNU Electric 8.08 from its source code by using Java SDK and Eclipse 3.4.2 (Ganymede) ② To use the source code debugger to survey different causes of exceptions thrown by Electric while processing a user- defined Technology File

3 Building and debugging Electric 3 Some icons used throughout this document Micro-steps to be followed sequentially # 02 Set the default workspace # 03 Uncheck “Build Automatically” flag Options/points to be carefully checked

4 Building and debugging Electric 4 References You should refer to : [1] [2] http://java.com/en/ for Javahttp://java.com/en/ [3] http://www.eclipse.org/ for Eclipsehttp://www.eclipse.org/ [4] http://www.staticfreesoft.com/productsFree.html for GNU Electrichttp://www.staticfreesoft.com/productsFree.html ✔ Not available yet!

5 Building and debugging Electric 5 Index Part-ISetting up Software Development Environment Part-IICreating a New Project Part-IIIBuilding the New Project Part-IVDebugging GNU Electric

6 Building and debugging Electric 6

7 7 01. Java Runtime and SDK The tools listed below are assumed as Java development environment ToolVersionInstall location OS Windows XP SP3 Japanese C:\Windows  this may look like Java Runtime Java 6 Update 13 C:\Program Files\Java\jre6\ Java 3D1.5.2C:\Program Files\Java\Java3D\1.5.2\ Java SDK Java SED Kit 6 Update 13 C:\Program Files\Java\jdk1.6.0_13\ The images were captured on Japanese Windows throughout this document. Therefore, wherever you see a Yen mark in a file path, please understand that it corresponds to a “back slash” character in the non-Japanese world.

8 Building and debugging Electric 8 Customization of Java environment made for my convenience Manually copied --- for some reasons; cannot remember ;-( The modified “build.xml” file embedded in slide #26 reflects this organization as shown below.

9 Building and debugging Electric 9 02. Eclipse The tools checked below are assumed as Eclipse environment ✔ ✔ Visit http://www.eclipse.org/downloads/http://www.eclipse.org/downloads/ ✔

10 Building and debugging Electric 10 Author’s Eclipse environment used in this document ※ C/C++ and Qt tools are not required for building/debugging GNU Electric.

11 Building and debugging Electric 11 Author’s batch file used to start Eclipse rem ----- Batch file for invoking Eclipse with Qt plug-in ----- rem ----- Qt-related environment variables set QTDIR=D:\Qt\2009.01\qt\ set QMAKESPEC=win32-g++ set MINGWDIR=D:\Qt\2009.01\mingw\ rem ----- Java SDK-related environment variable set JDKDIR=c:\Program Files\Java\jdk1.6.0_13\ rem ----- Set path to all the tools set Path=%JDKDIR%\bin;%MINGWDIR%\bin;%QTDIR%\bin;%Path% rem ----- Invoke Eclipse call eclipse.exe exit This shortcut calls the batch file.

12 Building and debugging Electric 12 03. Default workspace for Eclipse # 01 Invoke Eclipse # 02 Set the default workspace

13 Building and debugging Electric 13 # 03 Uncheck “Build Automatically” flag This option is useful for incremental building. As I’m going to build everything from scratch, let’s suppress this feature for the time being. Otherwise, compilation will automatically start while importing a Jar file to a new Java project.

14 Building and debugging Electric 14

15 Building and debugging Electric 15 01. Create a new project for GNU Electric # 01 Create a new Java project

16 Building and debugging Electric 16 # 02 Import the JAR file of GNU Electric 8.08

17 Building and debugging Electric 17 # 03 Select the JAR file of GNU Electric 8.08 Not “electricBinary-8.08.jar”

18 Building and debugging Electric 18 # 04 Configure Build Path

19 Building and debugging Electric 19 # 05 Check the build path (1)

20 Building and debugging Electric 20 # 06 Check the build path (2)

21 Building and debugging Electric 21 # 07 Check the build path (3)

22 Building and debugging Electric 22 # 08 Check the build path (4), then press [OK]

23 Building and debugging Electric 23 # 09 Confirm that these packages have been created

24 Building and debugging Electric 24 # 01 Go through “README.txt” file 02. Information on how-to-build # 02 Read “Building from Sources” section carefully

25 Building and debugging Electric 25 03. Edit “build.xml” file for Ant tool # 01 Copy then paste “build.xml” to backup the original one

26 Building and debugging Electric 26 # 02 Edit “build.xml” according to the information described in “README.txt” file.  For example, Macintosh-related descriptions are to be removed. Original Modified :::: :::: Unpack and compare these two files for details The above tool is Slide #8

27 Building and debugging Electric 27 # 03 Delete “MacOSXInterface.java” file, which is not necessary for Windows

28 Building and debugging Electric 28 # 04 Optionally edit a file to modify the splash image Original Modified

29 Building and debugging Electric 29

30 Building and debugging Electric 30 01. Build by Ant tool # 01 To clean, follow clean  Run As  Ant Build

31 Building and debugging Electric 31 # 02 To build, follow compile  Run As  Ant Build Successfully built with 91 warnings

32 Building and debugging Electric 32 # 03 To run, follow runMain  Run As  Ant Build

33 Building and debugging Electric 33 # 04 Check that the tool has started successfully; watch the console “Added Technologies” is being loaded…

34 Building and debugging Electric 34 02. Quickly check that the tool works # 01 Load a library and open a layout cell Looks OK!

35 Building and debugging Electric 35 # 02 Run NCC Looks OK!

36 Building and debugging Electric 36 # 03 Run DRC Exception has been caught!

37 Building and debugging Electric 37 # 04 Check the console of Eclipse workbench The same exception has also been caught by Eclipse # 05 Click a hyperlink and confirm that the source code can be loaded to the editor view

38 Building and debugging Electric 38 # 06 The location has been correctly identified in the editor view

39 Building and debugging Electric 39

40 Building and debugging Electric 40 01. Configuring the debug setup # 01 Start Debug Configurations …

41 Building and debugging Electric 41 # 02 Setup configuration

42 Building and debugging Electric 42 # 03 Set break point(s) as needed

43 Building and debugging Electric 43 # 01 Change the perspective to Debug and start the debugger 02. Start the debugger

44 Building and debugging Electric 44 # 02 Confirm that GNU Electric has started in a debug mode

45 Building and debugging Electric 45 # 03 Load the same library and open the same layout cell as before Looks OK!

46 Building and debugging Electric 46 # 04 Run NCC Looks OK!

47 Building and debugging Electric 47 # 05 Run DRC Exception has been caught and the program has stopped at the break point.

48 Building and debugging Electric 48 # 06 Inspect variable(s) This is what the author wanted to do!

49 Building and debugging Electric 49 # 07 Resume the execution Exception has been caught!

50 Building and debugging Electric 50 The same exception has also been caught by Eclipse # 08 Check the console of Eclipse debug perspective

51 Building and debugging Electric 51  Summary ① GNU Electric version 8.08 was built from its source code by using Java SDK and Eclipse 3.4.2 (Ganymede). ② The newly built GNU Electric was source-code-debugged on the Eclipse workbench. ③ Such capability of debugging will help us debug a user- defined Technology File. [The End of File]


Download ppt "Building and debugging Electric 1 Building and debugging GNU Electric version 8.08 by Java SDK & Eclipse (Ganymede) by Kazzz (a Japanese engineer) May."

Similar presentations


Ads by Google