This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Using CCS command line build with no GUI. Is this possible?

Other Parts Discussed in Thread: CCSTUDIO

Hello,

I previously posted a question about building my projects outside of CCS using a command line build.  People were most helpful on this forum with that, and I found that it was possible by doing the following:

/opt/ti/ccsv5/eclipse/eclipse -noSplash -application com.ti.ccstudio.apps.projectBuild -data /tmp/nightly_build -import /tmp/nightly_build/  ..etc...

That was great and it works well.  So well in fact, that now we want to move this functionality off to a server and run automated builds using this tool.

However, that server is a virtual Ubuntu machine with no graphical front end.  It will be running in a cron job on that machine as a separate user (local to that machine) so thus there is no way to set a display or VNC or anything.  I would like it to just run on the machine in a text mode with no graphics at all.  Is this possible?

When I run the script from there (in a cron job as a different user), it fails with the following errors:

(eclipse:15346): GLib-GObject-WARNING **: invalid (NULL) pointer instance

(eclipse:15346): GLib-GObject-CRITICAL **: g_signal_connect_data: assertion `G_TYPE_CHECK_INSTANCE (instance)' failed

(eclipse:15346): Gtk-CRITICAL **: IA__gtk_settings_get_for_screen: assertion `GDK_IS_SCREEN (screen)' failed

(eclipse:15346): GdkPixbuf-CRITICAL **: gdk_pixbuf_get_width: assertion `GDK_IS_PIXBUF (pixbuf)' failed

(eclipse:15346): GdkPixbuf-CRITICAL **: gdk_pixbuf_get_height: assertion `GDK_IS_PIXBUF (pixbuf)' failed

(eclipse:15346): Gtk-CRITICAL **: IA__gtk_window_resize: assertion `width > 0' failed

(eclipse:15346): Gtk-WARNING **: Screen for GtkWindow not set; you must always set
a screen for a GtkWindow before using the window

(eclipse:15346): Gtk-WARNING **: Screen for GtkWindow not set; you must always set
a screen for a GtkWindow before using the window

(eclipse:15346): Gdk-CRITICAL **: IA__gdk_screen_get_display: assertion `GDK_IS_SCREEN (screen)' failed

(eclipse:15346): Gdk-CRITICAL **: IA__gdk_display_get_pointer: assertion `GDK_IS_DISPLAY (display)' failed

(eclipse:15346): Gtk-WARNING **: Screen for GtkWindow not set; you must always set
a screen for a GtkWindow before using the window

(eclipse:15346): Gdk-CRITICAL **: IA__gdk_screen_get_n_monitors: assertion `GDK_IS_SCREEN (screen)' failed

(eclipse:15346): Gtk-WARNING **: Screen for GtkWindow not set; you must always set
a screen for a GtkWindow before using the window

(eclipse:15346): Gdk-CRITICAL **: IA__gdk_screen_get_monitor_geometry: assertion `GDK_IS_SCREEN (screen)' failed

(eclipse:15346): Gdk-CRITICAL **: IA__gdk_screen_get_default_colormap: assertion `GDK_IS_SCREEN (screen)' failed

(eclipse:15346): Gdk-CRITICAL **: IA__gdk_colormap_get_visual: assertion `GDK_IS_COLORMAP (colormap)' failed

(eclipse:15346): Gdk-CRITICAL **: IA__gdk_screen_get_default_colormap: assertion `GDK_IS_SCREEN (screen)' failed

(eclipse:15346): Gdk-CRITICAL **: IA__gdk_screen_get_root_window: assertion `GDK_IS_SCREEN (screen)' failed

(eclipse:15346): Gdk-CRITICAL **: IA__gdk_screen_get_root_window: assertion `GDK_IS_SCREEN (screen)' failed

(eclipse:15346): Gdk-CRITICAL **: IA__gdk_window_new: assertion `GDK_IS_WINDOW (parent)' failed
#
# An unexpected error has been detected by Java Runtime Environment:
#
# SIGSEGV (0xb) at pc=0xccad3d0d, pid=15346, tid=4150224576
#
# Java VM: Java HotSpot(TM) Client VM (11.3-b02 mixed mode linux-x86)
# Problematic frame:
# C [libgdk-x11-2.0.so.0+0x6dd0d] gdk_window_enable_synchronized_configure+0x1d
#
# An error report file with more information is saved as:
# /home/jchoate/hs_err_pid15346.log
#
# If you would like to submit a bug report, please visit:
# http://java.sun.com/webapps/bugreport/crash.jsp
# The crash happened outside the Java Virtual Machine in native code.
# See problematic frame for where to report the bug.
#
Aborted

  • Jeff, 

    Unfortunately, current CCS versions have a limitation of requiring a display. The way people have worked around this is by using virtual frame buffer (xvfb). CCSv5.3 will have a fix for this issue. CCSv5.3 target release date is end Oct. 

    Martin

  • Hi,

    I managed to make CCS compile projects from command line (even integrated with Jenkins). The main thing you should do as far as I remember is to install CCS under the same user you want to compile under.

    Alexey

  • Hi,

    I just wanted to give another suggestion to any others who may have this problem.  The way that I got around this problem until the limitation is removed in 5.3 was to start my VM up, log into the console and type "xhost +" to allow all X connections to the console.  Then in my crontab, I just set DISPLAY=":0", and run my jobs.  This works perfectly fine, although I believe "xhost +" creates a security vulnerability.  This system is totally isolated though, so it didn't concern me too much.

    Just another alternative work around.

    -Jeff

  • Jeff - Thanks for the update and suggestion!