mirror of
https://github.com/YosysHQ/nextpnr.git
synced 2026-04-28 12:57:13 +00:00
gowin: Himbaechel. Support DragonFlyBSD
Signed-off-by: YRabbit <rabbit@yrabbit.cyou>
This commit is contained in:
@@ -156,8 +156,7 @@ std::string proc_self_dirname(void)
|
||||
{
|
||||
char buf[PATH_MAX + 1] = "", *path, *p;
|
||||
// if case argv[0] contains a valid path, return it
|
||||
if (strlen(npnr_path) > 0) {
|
||||
p = strrchr(npnr_path, '/');
|
||||
if (strlen(npnr_path) > 0 && (p = strrchr(npnr_path, '/')) != NULL) {
|
||||
snprintf(buf, sizeof buf, "%*s/", (int)(npnr_path - p), npnr_path);
|
||||
return buf;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user