limine.c: Add copyright and license information to version command
This commit is contained in:
parent
6e41938206
commit
d08ea721a5
@ -120,7 +120,7 @@ override LIMINE_NO_BIOS := -DLIMINE_NO_BIOS
|
||||
|
||||
$(call MKESCAPE,$(BINDIR))/limine: $(call MKESCAPE,$(BINDIR))/Makefile $(call MKESCAPE,$(SRCDIR))/host/limine.c
|
||||
endif
|
||||
$(SED) 's/@LIMINE_VERSION@/@PACKAGE_VERSION@/g' <'$(call SHESCAPE,$(SRCDIR))/host/limine.c' >'$(call SHESCAPE,$(BINDIR))/limine.c'
|
||||
$(SED) 's/%VERSION%/@PACKAGE_VERSION@/g;s/%COPYRIGHT%/@LIMINE_COPYRIGHT@/g' <'$(call SHESCAPE,$(SRCDIR))/host/limine.c' >'$(call SHESCAPE,$(BINDIR))/limine.c'
|
||||
CPPFLAGS="$(CPPFLAGS) $(LIMINE_NO_BIOS)" $(MAKE) -C '$(call SHESCAPE,$(BINDIR))' limine
|
||||
|
||||
$(call MKESCAPE,$(BINDIR))/Makefile: $(call MKESCAPE,$(SRCDIR))/host/Makefile $(call MKESCAPE,$(SRCDIR))/host/.gitignore
|
||||
|
@ -1120,10 +1120,14 @@ cleanup:
|
||||
return ret;
|
||||
}
|
||||
|
||||
#define LIMINE_VERSION "@LIMINE_VERSION@"
|
||||
#define LIMINE_VERSION "%VERSION%"
|
||||
#define LIMINE_COPYRIGHT "%COPYRIGHT%"
|
||||
|
||||
static int version(void) {
|
||||
puts(LIMINE_VERSION);
|
||||
puts("Limine " LIMINE_VERSION);
|
||||
puts(LIMINE_COPYRIGHT);
|
||||
puts("Limine is distributed under the terms of the BSD-2-Clause license.");
|
||||
puts("There is ABSOLUTELY NO WARRANTY, to the extent permitted by law.");
|
||||
return EXIT_SUCCESS;
|
||||
}
|
||||
|
||||
@ -1153,7 +1157,8 @@ int main(int argc, char *argv[]) {
|
||||
#endif
|
||||
} else if (strcmp(argv[1], "enroll-config") == 0) {
|
||||
return enroll_config(argc - 1, &argv[1]);
|
||||
} else if (strcmp(argv[1], "version") == 0) {
|
||||
} else if (strcmp(argv[1], "version") == 0
|
||||
|| strcmp(argv[1], "--version") == 0) {
|
||||
return version();
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user