Import parse_timestamp() from ostree

Closes: #1538
Approved by: alexlarsson
This commit is contained in:
Alexander Larsson
2018-03-29 16:32:00 +02:00
committed by Atomic Bot
parent 4b002ebacd
commit 222d7e2382
4 changed files with 4958 additions and 0 deletions

View File

@@ -2,6 +2,8 @@ bin_PROGRAMS += \
flatpak \
$(NULL)
EXTRA_DIST += app/parse-datetime.y
flatpak_SOURCES = \
app/flatpak-main.c \
app/flatpak-builtins.h \
@@ -39,6 +41,8 @@ flatpak_SOURCES = \
app/flatpak-builtins-document-info.c \
app/flatpak-builtins-document-list.c \
app/flatpak-builtins-search.c \
app/parse-datetime.c \
app/parse-datetime.h \
$(NULL)
flatpak_LDADD = $(AM_LDADD) $(BASE_LIBS) $(OSTREE_LIBS) $(SOUP_LIBS) $(JSON_LIBS) $(APPSTREAM_GLIB_LIBS) \

3328
app/parse-datetime.c Normal file
View File

File diff suppressed because it is too large Load Diff

22
app/parse-datetime.h Normal file
View File

@@ -0,0 +1,22 @@
/* Parse a string into an internal time stamp.
Copyright (C) 1995, 1997-1998, 2003-2004, 2007, 2009-2015 Free Software
Foundation, Inc.
This program is free software: you can redistribute it and/or modify it
under the terms of the GNU Lesser General Public License as published
by the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
#include <stdbool.h>
#include <time.h>
bool parse_datetime (struct timespec *, char const *, struct timespec const *);

1604
app/parse-datetime.y Normal file
View File

File diff suppressed because it is too large Load Diff