mirror of
https://github.com/tailix/libkernaux.git
synced 2025-03-31 17:25:22 -04:00
Start working on command line parser
This commit is contained in:
parent
90d2ef08dd
commit
761fb821d8
7 changed files with 30 additions and 0 deletions
1
.gitignore
vendored
1
.gitignore
vendored
|
@ -32,6 +32,7 @@
|
|||
|
||||
/tests/multiboot2_print1
|
||||
/tests/multiboot2_print2
|
||||
/tests/test_cmdline
|
||||
/tests/test_multiboot2_helpers
|
||||
/tests/test_multiboot2_print
|
||||
/tests/test_multiboot2_validation
|
||||
|
|
|
@ -5,6 +5,7 @@ AM_CFLAGS = -std=c99 -Wall -Wextra -I$(top_srcdir)/include
|
|||
lib_LIBRARIES = libkernaux.a
|
||||
|
||||
TESTS = \
|
||||
tests/test_cmdline \
|
||||
tests/test_multiboot2_helpers \
|
||||
tests/test_multiboot2_print \
|
||||
tests/test_multiboot2_validation \
|
||||
|
@ -17,6 +18,7 @@ noinst_PROGRAMS = \
|
|||
tests/multiboot2_print2
|
||||
|
||||
libkernaux_a_SOURCES = \
|
||||
src/cmdline.c \
|
||||
src/console.c \
|
||||
src/multiboot2/helpers.c \
|
||||
src/multiboot2/is_valid.c \
|
||||
|
@ -36,6 +38,10 @@ tests_multiboot2_print2_SOURCES = \
|
|||
$(libkernaux_a_SOURCES) \
|
||||
tests/multiboot2_print2.c
|
||||
|
||||
tests_test_cmdline_SOURCES = \
|
||||
$(libkernaux_a_SOURCES) \
|
||||
tests/test_cmdline.c
|
||||
|
||||
tests_test_multiboot2_helpers_SOURCES = \
|
||||
$(libkernaux_a_SOURCES) \
|
||||
tests/test_multiboot2_helpers.c
|
||||
|
|
|
@ -21,6 +21,7 @@ Table of contents
|
|||
API
|
||||
---
|
||||
|
||||
* [Simple command line parser](/include/kernaux/cmdline.h) *(work in progress)*
|
||||
* [Multiboot 2 (GRUB 2) information parser](/include/kernaux/multiboot2.h)
|
||||
* [Serial console](/include/kernaux/console.h)
|
||||
* [Page Frame Allocator](/include/kernaux/pfa.h) *(work in progress)*
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
nobase_include_HEADERS = \
|
||||
kernaux/arch/x86.h \
|
||||
kernaux/cmdline.h \
|
||||
kernaux/console.h \
|
||||
kernaux/multiboot2.h \
|
||||
kernaux/pfa.h \
|
||||
|
|
12
include/kernaux/cmdline.h
Normal file
12
include/kernaux/cmdline.h
Normal file
|
@ -0,0 +1,12 @@
|
|||
#ifndef KERNAUX_INCLUDED_CMDLINE
|
||||
#define KERNAUX_INCLUDED_CMDLINE 1
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif
|
3
src/cmdline.c
Normal file
3
src/cmdline.c
Normal file
|
@ -0,0 +1,3 @@
|
|||
#include "config.h"
|
||||
|
||||
#include <kernaux/cmdline.h>
|
6
tests/test_cmdline.c
Normal file
6
tests/test_cmdline.c
Normal file
|
@ -0,0 +1,6 @@
|
|||
#include <kernaux/cmdline.h>
|
||||
|
||||
int main()
|
||||
{
|
||||
return 0;
|
||||
}
|
Loading…
Add table
Reference in a new issue