-
Notifications
You must be signed in to change notification settings - Fork 86
Debugging
By default LambdaNative sets the current-exception-handler
to log:exception-handler. This results in all errors and additional desired logging information to be written to the applications log/
folder.
If the regular logfile doesn't show the error, the following procedure can be attempted: Configure the application in debug mode, using ./configure <appname> debug
. Clean the cache, so that gambit-c is rebuild in with source lines, using make scrub
. The following make; make install
will take a while as the entire system is rebuild in debug mode. Logfiles will now contain the trace of the error to the line, where it occured.
If DemoConsole is changed to include(sin 2.3 3.3)
, and invalid command for the (sin x)
function it will compile without errors when using ./configure DemoConsole; make;
However, when run with make install
it will exit without an error. When followed up with cat ~/Desktop/DemoConsole.app/log/*
the following errors are found:
[SYSTEM] 2015-01-28 09:58:15: Application DemoConsole built 2015-01-28 09:58:09
[SYSTEM] 2015-01-28 09:58:15: Git hash lambdanative: 6c06e2b,parts: 3f70dff
[ERROR] 2015-01-28 09:58:15: primordial: (sin 2.3 3.3): Wrong number of arguments passed to procedure
[ERROR] 2015-01-28 09:58:15: HALT
If DemoConsole is changed to include(sin undef)
, whereby undef
is not defined, it will throw a warning during compilation with ./configure DemoConsole debug; make;
=> creating gsc link..
*** WARNING -- "undef" is not defined,
*** referenced in: ("/home/mg/documents/Programming/lambdanative-cache/linux/build/4285167665.c")
=> generating hook..
However, when run with make install
it will cause a segmentation fault. When followed up with cat ~/Desktop/DemoConsole.app/log/*
the following errors are found, which point to the location of the error:
[SYSTEM] 2015-02-01 00:24:08: Git hash lambdanative: 7443b12,parts: 4dc8857
[ERROR] 2015-02-01 00:24:08: primordial: (sin #!unbound): (Argument 1) NUMBER expected
[ERROR] 2015-02-01 00:24:08: trace: /home/mg/documents/Programming/lambdanative/apps/DemoConsole/main.scm line=40 col=1
[ERROR] 2015-02-01 00:24:08: HALT
-
- accelerometer
- alist
- audio
- audioaux
- base64
- btle-scan
- camera
- cdb
- cgi
- config
- csv
- curl
- digest
- dmtx
- download
- eventloop
- fcgi
- fft
- generalized-arrays
- gps
- graph
- gyro
- hidapi
- hpdf
- html
- httpsclient
- hybridapp
- json
- lmdb
- ln_core
- ln_glcore
- ln_glgui
- ln_store
- localization
- localization_gui
- localnotification
- magnetometer
- mdns
- mqtt
- mqtt-store
- multitouch
- oauth
- orientation
- p256ecdsa
- png
- portaudio
- pregexp
- pressure
- prime
- pushnotification
- redcap
- rsa
- rtaudio
- rupi
- rotation
- sanestring
- scheduler
- serial
- sets
- settings
- simplexnoise
- sqlite
- ssax
- syntax-case
- timestamp
- ttf
- uiform
- url
- uuid
- vibrate
- videoplayer
- watchdog
- website
- xml
- zip