Declare external functions for termcolour and commander in the headers
This commit is contained in:
		@@ -15,7 +15,6 @@ internal inline CMDResult execute_command(const char *cmd, CMDOutHandling out_ha
 | 
			
		||||
                                          u64 buf_size);
 | 
			
		||||
internal inline CMDError get_command_output(FILE *fp, CMDOutHandling out_handling, char *out_buf,
 | 
			
		||||
                                            u64 buf_size);
 | 
			
		||||
extern CMDError get_output_status(FILE *fp, i32 *status_out);
 | 
			
		||||
 | 
			
		||||
CMDResult run_command(CMDOutHandling out_handling, char *out_buf, u64 buf_size, ...) {
 | 
			
		||||
  va_list args;
 | 
			
		||||
 
 | 
			
		||||
@@ -4,6 +4,7 @@
 | 
			
		||||
#include "aliases.h"
 | 
			
		||||
#include "commander_output.h"
 | 
			
		||||
#include <stdbool.h>
 | 
			
		||||
#include <stdio.h>
 | 
			
		||||
#include <stdlib.h>
 | 
			
		||||
 | 
			
		||||
#ifdef __cplusplus
 | 
			
		||||
@@ -16,6 +17,8 @@ BEGIN_C_LINKAGE
 | 
			
		||||
 | 
			
		||||
CMDResult run_command(CMDOutHandling out_handling, char *out_buf, u64 buf_size, ...);
 | 
			
		||||
 | 
			
		||||
external CMDError get_output_status(FILE *fp, i32 *status_out);
 | 
			
		||||
 | 
			
		||||
#ifdef __cplusplus
 | 
			
		||||
END_C_LINKAGE
 | 
			
		||||
#endif // __cplusplus
 | 
			
		||||
 
 | 
			
		||||
@@ -1,8 +1,6 @@
 | 
			
		||||
#include "termcolour.h"
 | 
			
		||||
#include "terminal_colours.h"
 | 
			
		||||
 | 
			
		||||
extern void print_coloured_text(const char *text, TerminalColour colour);
 | 
			
		||||
 | 
			
		||||
void wapp_shell_termcolour_print_text(const char *text, TerminalColour colour) {
 | 
			
		||||
  if (colour < WAPP_TERM_COLOUR_FG_BLACK || colour > WAPP_TERM_COLOUR_FG_BR_WHITE) {
 | 
			
		||||
    return;
 | 
			
		||||
 
 | 
			
		||||
@@ -1,6 +1,7 @@
 | 
			
		||||
#ifndef TERM_COLOUR_H
 | 
			
		||||
#define TERM_COLOUR_H
 | 
			
		||||
 | 
			
		||||
#include "aliases.h"
 | 
			
		||||
#include "terminal_colours.h"
 | 
			
		||||
 | 
			
		||||
#ifdef __cplusplus
 | 
			
		||||
@@ -10,6 +11,8 @@ BEGIN_C_LINKAGE
 | 
			
		||||
void wapp_shell_termcolour_print_text(const char *text, TerminalColour colour);
 | 
			
		||||
void wapp_shell_termcolour_clear_colour(void);
 | 
			
		||||
 | 
			
		||||
external void print_coloured_text(const char *text, TerminalColour colour);
 | 
			
		||||
 | 
			
		||||
#ifdef __cplusplus
 | 
			
		||||
END_C_LINKAGE
 | 
			
		||||
#endif // __cplusplus
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user