New Projects - Fresh from the Labs
In a world of ever-expanding code, it's easy to become sloppy, with lines of redundant code or inelegant design coming into play. Thankfully, deheader steps up to the plate—a simple tool that can save coders a great deal of time.
According to the Web site: “deheader analyzes C and C++ files to determine which header inclusions can be removed while still allowing them to compile. This may result in substantial improvements in compilation time, especially on large C++ projects; it also sometimes exposes dependencies and cohesions of which developers were unaware.”
Installation and Usage
As far as packages go, at the time of this writing, the only thing available was a source tarball. But, fear not. No compiling is necessary, and because there's no real mention of library requirements, I'm guessing most distros will run it off the bat, assuming they have Python.
Download the latest tarball from the Web site, extract it, and open a terminal in the new folder. Then, it's simply a case of running:
$ ./deheader path-of-files
If the given path is a directory, deheader scans all the files within. Give it some time to process, and eventually a list of all the unnecessary headers appears on-screen. For instance, I chose to analyze the now ten-year-old MPlayer code, a project that would unavoidably have a lot of legacy code and loose ends simply from being around for such a long time.
If you're ready to take things further, add a switch of -r, and the unnecessary headers are removed from the files. If you want to do some test compiling, use the -m switch. As an example, here's a command I ran against the MPlayer code:
$ ./deheader -r ~/src/mplayer-export-2010-12-27/
Those are the basics; refer to the documentation for more information.
As you can see, deheader is a very simple-to-use program with an elegant design. This ideal of coding elegance is manifest in deheader's results. It should save a great deal of compilation time and highlight coding foibles that likely would have remained unnoticed. Although it's still sitting around in tarball source form, hopefully it will make its way into distro repositories soon.
Projects at a Glance
Fans of the hard-core gaming company, Razer, no doubt will want to look up this project. According to the Web site: “This is the next-generation Razer device configuration tool bringing the Razer gaming experience to the free, Open Source world. This utility is supposed to replace the old deathaddercfg utility. The tool architecture is based on razerd, which is a background dæmon doing all of the low-level privileged hardware accesses. The user interface tools are razercfg, a command-line tool; and qrazercfg, a Qt4-based graphical device configuration tool.”
And, according to its Freshmeat entry: “Supported devices are the Razer DeathAdder mouse, the Razer Krait mouse, the Razer Lachesis mouse, the Razer Copperhead mouse and the Razer Naga mouse.”
I've always been put off by Clam antivirus's command-line interface (I just don't get it), so a GUI front end would be brilliant. Thankfully, it seems numerous front ends exist, and hopefully, I can cover one or two in the coming months. Details on this project, however, are scarce, although I'd like to try it anyway. According to its Freshmeat entry: “GAdmin-Antivirus is a fast-and-easy to use GTK+ front end for Clam antivirus. Multiple scan sets can be scheduled to run at specific times via cron. Each of these scan sets can contain multiple directories to be scanned.”
Brewing something fresh, innovative or mind-bending? Send e-mail to email@example.com.
John Knight is a 26-year-old, drumming- and climbing-obsessed maniac from the world's most isolated city—Perth, Western Australia. He can usually be found either buried in an Audacity screen or thrashing a kick-drum beyond recognition.
John Knight is the New Projects columnist for Linux Journal.
Practical Task Scheduling Deployment
July 20, 2016 12:00 pm CDT
One of the best things about the UNIX environment (aside from being stable and efficient) is the vast array of software tools available to help you do your job. Traditionally, a UNIX tool does only one thing, but does that one thing very well. For example, grep is very easy to use and can search vast amounts of data quickly. The find tool can find a particular file or files based on all kinds of criteria. It's pretty easy to string these tools together to build even more powerful tools, such as a tool that finds all of the .log files in the /home directory and searches each one for a particular entry. This erector-set mentality allows UNIX system administrators to seem to always have the right tool for the job.
Cron traditionally has been considered another such a tool for job scheduling, but is it enough? This webinar considers that very question. The first part builds on a previous Geek Guide, Beyond Cron, and briefly describes how to know when it might be time to consider upgrading your job scheduling infrastructure. The second part presents an actual planning and implementation framework.
Join Linux Journal's Mike Diehl and Pat Cameron of Help Systems.
Free to Linux Journal readers.Register Now!
- Returning Values from Bash Functions
- SUSE LLC's SUSE Manager
- Tech Tip: Really Simple HTTP Server with Python
- Murat Yener and Onur Dundar's Expert Android Studio (Wrox)
- My +1 Sword of Productivity
- Non-Linux FOSS: Caffeine!
- Managing Linux Using Puppet
- Doing for User Space What We Did for Kernel Space
- Parsing an RSS News Feed with a Bash Script
- Rogue Wave Software's Zend Server
With all the industry talk about the benefits of Linux on Power and all the performance advantages offered by its open architecture, you may be considering a move in that direction. If you are thinking about analytics, big data and cloud computing, you would be right to evaluate Power. The idea of using commodity x86 hardware and replacing it every three years is an outdated cost model. It doesn’t consider the total cost of ownership, and it doesn’t consider the advantage of real processing power, high-availability and multithreading like a demon.
This ebook takes a look at some of the practical applications of the Linux on Power platform and ways you might bring all the performance power of this open architecture to bear for your organization. There are no smoke and mirrors here—just hard, cold, empirical evidence provided by independent sources. I also consider some innovative ways Linux on Power will be used in the future.Get the Guide