mirror of
https://github.com/akuker/RASCSI.git
synced 2025-02-21 07:29:28 +00:00
45 lines
1.4 KiB
C++
45 lines
1.4 KiB
C++
//---------------------------------------------------------------------------
|
|
//
|
|
// SCSI Target Emulator RaSCSI (*^..^*)
|
|
// for Raspberry Pi
|
|
//
|
|
// Copyright (C) 2020 akuker
|
|
// [ Define the version string]
|
|
//
|
|
//---------------------------------------------------------------------------
|
|
|
|
#include "rascsi_version.h"
|
|
#include <stdio.h>
|
|
#include <string.h>
|
|
|
|
// The following should be updated for each release
|
|
const int rascsi_major_version = 21; // Last two digits of year
|
|
const int rascsi_minor_version = 99; // Month
|
|
const int rascsi_patch_version = -1; // Patch number - increment for each update
|
|
|
|
static char rascsi_version_string[30]; // Allow for string up to "XX.XX.XXX" + null character + "development build"
|
|
|
|
//---------------------------------------------------------------------------
|
|
//
|
|
// Get the RaSCSI version string
|
|
//
|
|
//---------------------------------------------------------------------------
|
|
char* rascsi_get_version_string()
|
|
{
|
|
if(rascsi_patch_version < 0)
|
|
{
|
|
snprintf(rascsi_version_string, sizeof(rascsi_version_string),
|
|
"%02d.%02d --DEVELOPMENT BUILD--",
|
|
rascsi_major_version,
|
|
rascsi_minor_version);
|
|
}
|
|
else
|
|
{
|
|
snprintf(rascsi_version_string, sizeof(rascsi_version_string), "%02d.%02d.%d",
|
|
rascsi_major_version,
|
|
rascsi_minor_version,
|
|
rascsi_patch_version);
|
|
}
|
|
return rascsi_version_string;
|
|
}
|