How to Generate CVS Changelog Automatically

There is a perl script called cvs2cl.pl provided by Red-Bean You can get the latest version thru cvs: cvs -d :pserver:[email protected]:/usr/local/cvs co cvs2cl/cvs2cl.pl Copy the script in a directory that belong to the path e.g.: cp cvs2cl.pl /usr/local/bin Then just checkout your project and run cvs2cl.pl to generate a ChangeLog that will look like: 2010-01-18 developer1 * app/cnxapp/Makefile: Added support for SMP8652 target 2010-01-17 developer2 * app/cnxapp/cnx_download.c: Added HTTP resume support [Bug 1250]: Fixed potential buffer overflow … where developer1 and developer2 are the linux usernames of the developers, app/cnxapp/Makefile, app/cnxapp/cnx_download.c the files that have been modified, and the comments correspond to the messages input during cvs commit. cvs2cl.pl also have other options such as XML output, date selection etc… Just type cvs2cl.pl –help to get the full options.

Block CVS Commits without message

If you are in my case, and you found it difficult to make some people in your team make proper comments/messages or any comments at all (cvs commit -m “Description of the changes”) while committing their changes to CVS, here’s what can be done to block commit without comments and with short comments. Checkout the CVSROOT directory cvs co CVSROOT Edit verifymsg in CVSROOT as follows #Set the verifymsg file to run a script DEFAULT /usr/local/bin/validate-cvs-log.sh Create /usr/local/bin/validate-cvs-log.sh script (make it executable for all cvs users): #!/bin/sh # # validate-cvs-log.sh logfile # test that log message has some characters in it if [ cat $1 | wc -c -lt 12 ] ; then echo “log message too short; please enter a description for the changes” exit 1 else exit 0 fi Commit verifymsg cvs commit -m “Added script to set minimum message size to 12 characters” verifymsg That’s it ! […]

Khadas Edge2 Arm mini PC

How to do a framebuffer screenshot

I’ll explain how to do framebuffer screenshots on 16-bit and 32-bit framebuffer. For 16-bit this is fully based on http://docs.blackfin.uclinux.org/doku.php?id=framebuffer Capturing screenshots Whatever the bit-depth of your framebuffer, the first step is to capture the frambuffer raw data on the board:

Now the you need to take the raw image, and convert it to a standard image format. This step depends on what type of display is there Converting 16-bit Framebuffer screenshot (RGB565) into png To convert the raw rgb data extracted from /dev/fb0, use iraw2png perl script

To do the conversion, type the following command in the host:

where 640 and 480 are respectively the width and height of your framebuffer. This has been tried on a 16-bit framebuffer on EM8620 series. Converting 32-bit Framebuffer screenshot (ARGB, RGBA, BGRA…) into png The solution proposed here is not as neat as the blackfin’s solution for 16-bit framebuffer, […]

uClinux kernel panic: Stack overflow

If you’re using ucLinux, you may get kernel panic errors coming out of nowhere. There may be several reasons (buffer overflow, out of memory..), but the most common is stack overflow for the process or one of the threads. To increase the stack size of a flat binary you’ll need to adjust the LDFLAGS as follows:

This will set the stack size to 64KB. To change the stack size of a thread (e.g. 32KB below), you’ll need to set the stack size attribute:

How to detect which thread suffers from stack overflow? First, you can check your code for recursive function calls and local variables (especially arrays) both of which will be added at runtime to the stack to estimate what should be the stack size. So if you have large arrays you may use a pointer + a call to malloc instead. If this can not fix […]

Digital Signage Standard by POPAI

Currently digital signage implementations are mainly proprietary, and that means once you choose a vendor you are stuck with it, unless you completely change your network and the way you manage your content or handles separate systems. If the digital signage industry really wants to take off some standards are needed. One of the first standard for digital signage has been released by POPAI (Point of Purchase Advertising International). This first standard is to promote interoperability between different providers by defining Screen Media Formats (Click to open the standard) basically telling which video and audio codecs and containers (“Wrappers”)  and which and picture formats  should/could be supported by digital signage players and providing different levels of standard profiles and extended profiles a bit like it is done in MPEG-4 specifications. POPAI also used to provide some media samples to test your system previously available at www.popai.com/DS/ContentSamples but the link is […]

Intel Arc Graphics Technology

Installing 2 Linux distributions in one PC

Here are the step I followed to install two distributions of Linux: Install the first distribution normally with GRUB in the MBR. While installing the second distribution make sure to set GRUB in its root partition. At this point the second distribution should not be available in GRUB Boot loader, login in the first distribution as root and edit /etc/grub.conf and add the following lines: Linux Distribution 2 root (hd0,2) chainloader +1 Save and restart your PC you should have 2 choices in GRUB, select “Linux Distribution 2”or whatever name you gave in grub.conf and this should start the second Linux distribution.

Finding large files in a Linux system

To list large files in a directory and subdirectories

This command looks for files larger than 10MB in /home/user directory and displays the result as follows: /home/user/largefile1.tar.bz2: 32M /home/user/bugzilla.sql: 21M

Khadas VIM4 SBC