1
0
Fork 0
mirror of https://github.com/pygos/pkg-utils.git synced 2024-11-24 21:40:43 +01:00

Move mkdir_p helper function to main code

Signed-off-by: David Oberhollenzer <goliath@infraroot.at>
This commit is contained in:
David Oberhollenzer 2019-01-29 22:03:33 +01:00
parent 09a336507d
commit e3740ba387
3 changed files with 12 additions and 2 deletions

View file

@ -10,6 +10,7 @@ GLOBALHDR += include/image_entry.h
MAIN = main/pkg.c main/util.c main/compressor.c main/command.c main/pkgreader.c
MAIN += main/pkgwriter.c main/image_entry.c main/image_entry_sort.c
MAIN += main/mkdir_p.c
pkg_SOURCES = $(GLOBALHDR) $(MAIN)
pkg_CFLAGS = $(AM_CFLAGS)
@ -34,7 +35,7 @@ pkg_SOURCES += main/cmd/dump/dump_header.c
# unpack command
pkg_SOURCES += main/cmd/unpack/unpack.c main/cmd/unpack/unpack.h
pkg_SOURCES += main/cmd/unpack/mkdir_p.c main/cmd/unpack/create_hierarchy.c
pkg_SOURCES += main/cmd/unpack/create_hierarchy.c
# help command
pkg_SOURCES += main/cmd/help.c

View file

@ -9,4 +9,6 @@ ssize_t write_retry(int fd, void *data, size_t size);
ssize_t read_retry(int fd, void *buffer, size_t size);
int mkdir_p(const char *path);
#endif /* UTIL_H */

View file

@ -1,4 +1,11 @@
#include "unpack.h"
#include <sys/types.h>
#include <sys/stat.h>
#include <string.h>
#include <alloca.h>
#include <stdio.h>
#include <errno.h>
#include "util.h"
int mkdir_p(const char *path)
{