226c7d1415b661a6abeda40ad1b95bca52e80fed
[project/opkg-lede.git] / libopkg / opkg_utils.h
1 /* opkg_utils.h - the opkg package management system
2
3 Steven M. Ayer
4
5 Copyright (C) 2002 Compaq Computer Corporation
6
7 This program is free software; you can redistribute it and/or
8 modify it under the terms of the GNU General Public License as
9 published by the Free Software Foundation; either version 2, or (at
10 your option) any later version.
11
12 This program is distributed in the hope that it will be useful, but
13 WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 General Public License for more details.
16 */
17
18 #ifndef OPKG_UTILS_H
19 #define OPKG_UTILS_H
20
21 #include "pkg.h"
22 #include "opkg_error.h"
23
24 void push_error_list(struct errlist **errors,char * msg);
25 void reverse_error_list(struct errlist **errors);
26 void free_error_list();
27
28 long unsigned int get_available_blocks(char * filesystem);
29 char **read_raw_pkgs_from_file(const char *file_name);
30 char **read_raw_pkgs_from_stream(FILE *fp);
31 char *trim_alloc(char * line);
32 int line_is_blank(const char *line);
33
34 #endif