4장. Creating software for RPM packaging
To prepare software for RPM packaging, you must understand what source code is and how to create software.
4.1. What is source code 링크 복사링크가 클립보드에 복사되었습니다!
Source code is human-readable instructions to the computer that describe how to perform a computation. Source code is expressed by using a programming language.
The following versions of the Hello World program written in three different programming languages cover major RPM Package Manager use cases:
Hello Worldwritten in BashThe bello project implements
Hello Worldin Bash. The implementation contains only thebelloshell script. The purpose of this program is to outputHello Worldon the command line.The
bellofile has the following contents:#!/bin/bash printf "Hello World\n"
Hello Worldwritten in PythonThe pello project implements
Hello Worldin Python. The implementation contains only thepello.pyprogram. The purpose of the program is to outputHello Worldon the command line.The
pello.pyfile has the following contents:#!/usr/bin/python3 print("Hello World")
Hello Worldwritten in CThe cello project implements
Hello Worldin C. The implementation contains only thecello.candMakefilefiles. The resultingtar.gzarchive therefore has two files in addition to theLICENSEfile. The purpose of the program is to outputHello Worldon the command line.The
cello.cfile has the following contents:#include <stdio.h> int main(void) { printf("Hello World\n"); return 0; }
The packaging process is different for each version of the Hello World program.