Language Selection

English French German Italian Portuguese Spanish

Programming Leftovers

Filed under
Development
  • Coming in glibc 2.33: Reloadable nsswitch.conf

    In my previous article about nsswitch.conf I talked about how simple, perhaps too simple, this config file is to use. What I didn’t cover then was how simplistic its internal implementation is. Specifically, an application only loads this file once—the first time it’s needed.

    So, what do you do when nsswitch.conf needs to change? How do you update all of the running applications? You don’t! The only way to force a reload is to stop the application and restart it. That is not always an option, especially for critical applications that might take a long time to restart.

    Recent work behind the scenes in the GNU C library will change all of this. As of glibc version 2.33, this config file now reloads and reparses each time it changes, and only the configuration is reloaded. If the configuration calls for an external shared library to be loaded, that object is only ever loaded once. It may be called in a different sequence, or not called at all, but it is never unloaded. This behavior avoids a whole class of problems related to unloading shared objects that might still be in use.

  • SEGGER's Complete J-Link Software Now Available for Linux on ARM

    SEGGER’s entire portfolio of J-Link software is now available for Linux on ARM, for both 32-bit and 64-bit platforms. This includes both the command-line programs and GUI tools such as J-Flash, J-Flash SPI, J-Scope, the J-Link Configurator, and the GUI version of the GDB Server.

    “J-Link can now be used on Raspberry Pi and other ARM-based machines, without any limitations,” says Alex Grüner, CTO at SEGGER. “Small single-board ARM computers now offer the same functionality as x86 powered machines. The inexpensive Raspberry Pi and similar boards are now viable options, especially in test farms and production environments.”

  • Bootstrappable builds

    The idea of Reproducible Builds—being able to recreate bit-for-bit identical binaries using the same source code—has gained momentum over the last few years. Reproducible builds provide some safeguards against bad actors in the software supply chain. But building software depends on the tools used to construct the binary, including compilers and build-automation tools, many of which depend on pre-existing binaries. Minimizing the reliance on opaque binaries for building our software ecosystem is the goal of the Bootstrappable Builds project.

    For example, GCC is written in C and C++, which means that it requires compilers for those two languages in order to be built from source. In practice, that generally means a distribution would use its existing binary executables of those tools to build a new GCC version, which would then be released to users. One of the concerns with that approach is described in Unix inventor Ken Thompson's Turing Award lecture "Reflections on Trusting Trust" [PDF]. In a nutshell, Thompson said that trusting the output of a binary compiler is an act of faith that someone has not tampered with the creation of that binary—even if the source code is available.

    The Bootstrappable Builds project was started as an offshoot of the Reproducible Builds project during the latter's 2016 summit in Berlin. A bootstrappable build takes the idea of reproducibility one step further, in some sense. The build of a target binary can be reproduced alongside the build of the tools required to do so. It is, conceptually, almost like building a house from a large collection of atoms of different elements.

  • Parasoft Accelerates CI/CD Pipeline Through Partnership With IAR Systems

    IAR Build Tools for Linux uses the leading build tools from IAR Embedded Workbench and empowers software developers who build safety-critical applications to work directly on the Linux host environment, eliminating toolchain version management.

  • Josef Strzibny: Working with decimals in Elixir

    Integers are not enough, and floats are flawed? Decimals to the rescue! A short guide of what’s important when working with decimals in Elixir.

    This post is about the Decimal 2.0 module from decimal Hex package.

    As with every module in Elixir, running h Module and Module.module_info in IEx is a good place to start.

  • Swift Deploys: Dealing with Anti-Patterns and Unresolved Issues

    In a long end-of-the-year blog post, Charity Majors, co-founder and CTO of honeycomb.io, discussed lead time to deploy, or “the interval encompassing the time from when the code gets written and when it’s been deployed to production.”

  • Perl weekly challenge 95

    You are given a number $N. Write a script to figure out if the given number is Palindrome. Print 1 if true otherwise 0.

  • Perl Weekly Challenge 95: Palindrome Numbers and Demo Stack
  • Learn awk by coding a "guess the number" game | Opensource.com

    Once you understand these concepts, you can start figuring the rest out. For example, most languages have a "way of doing things" supported by their design, and those ways can be quite different from one program to another. These ways include modularity (grouping related functionality together), declarative vs. imperative, object-orientation, low- vs. high-level syntactic features, and so on. An example familiar to many programmers is "ceremony," that is, the amount of work required to set the scene before tackling the problem. The Java programming language is said to have a significant ceremony requirement, stemming from its design, which requires all code to be defined within a class.

  • The terminal, the console and the shell - what are they?

    The other day, as I was going through some of my old notes, I stumbled upon something I had written about the console, the terminal and the shell on Unix-like operating systems. I have decided to rewrite these notes in order to share them here on my website. So without further ado we will now stroll down memory lane and take a quick look at the origins of the Unix terminal and shell. And I will also give my advice to new users on Linux or BSD regarding the choice of terminal emulator and shell.

More in Tux Machines

The March 2021 Issue of the PCLinuxOS Magazine

The PCLinuxOS Magazine staff is pleased to announce the release of the March 2021 issue. With the exception of a brief period in 2009, The PCLinuxOS Magazine has been published on a monthly basis since September, 2006. The PCLinuxOS Magazine is a product of the PCLinuxOS community, published by volunteers from the community. The magazine is lead by Paul Arnote, Chief Editor, and Assistant Editor Meemaw. The PCLinuxOS Magazine is released under the Creative Commons Attribution- NonCommercial-Share-Alike 3.0 Unported license, and some rights are reserved. All articles may be freely reproduced via any and all means following first publication by The PCLinuxOS Magazine, provided that attribution to both The PCLinuxOS Magazine and the original author are maintained, and a link is provided to the originally published article. In the March 2021 issue: * Short Topix: 10 Year Old Sudo Security Bug Patched * Repo Review: Minitube * GIMP Tutorial: Top GIMP Filters, Part 2 * H.264 vs H.265: The Evolution Of Video Codecs * Two PCLinuxOS Family Members Finally Meet * Tip Top Tips: How I Converted My H.264 Video To HEVC * PCLinuxOS Recipe Corner: Tortilla Casserole * And much more inside! This month’s cover was designed by parnote. Download the PDF (9.8 MB) https://pclosmag.com/download.php?f=2021-03.pdf Download the EPUB Version (7.1 MB) https://pclosmag.com/download.php?f=202103epub.epub Download the MOBI Version (7.2 MB) https://pclosmag.com/download.php?f=202103mobi.mobi Visit the HTML Version https://pclosmag.com/html/enter.html

Android Leftovers

SparkyLinux Finally Gets a KDE Plasma Edition, Xfce Flavor Updated to Xfce 4.16

Based on the Debian Testing repositories as of March 5th, 2021, where the development of the upcoming Debian GNU/Linux 11 “Bullseye” operating system series takes place, the SparkyLinux 2021.03 release ships with Linux kernel 5.10 LTS, the Calamares 3.2.37 installer, and various updated components (see below). But what caught my attention is the fact that SparkyLinux now features a KDE Plasma edition! Until now, SparkyLinux shipped with the Xfce, LXQt, MATE, Openbox (MinimalGUI), and MinimalCLI (text-mode) editions. Read more

How to Mount Windows NTFS Partition in Linux

This is quite common for Dual Boot users who use Windows and Linux simultaneously for their work. You can easily mount Windows partitions through File Manager. When you try to mount the NTFS partition from a terminal, you will encounter an error “The disk contains an unclean file system (0, 0). Read more