Merge branch 'work' into tomerge
This commit is contained in:
commit
64d849994b
|
|
@ -5,6 +5,7 @@ config.log
|
||||||
scripts/config.log
|
scripts/config.log
|
||||||
scripts/config.status
|
scripts/config.status
|
||||||
scripts/defs.mak
|
scripts/defs.mak
|
||||||
|
.*.swp
|
||||||
*.o
|
*.o
|
||||||
*.so
|
*.so
|
||||||
*~
|
*~
|
||||||
|
|
|
||||||
13
README
13
README
|
|
@ -27,6 +27,19 @@
|
||||||
development push over 8.1 is to add a Cairo (2D hardware-accelerated
|
development push over 8.1 is to add a Cairo (2D hardware-accelerated
|
||||||
graphics) interface ("magic -d CAIRO" or "magic -d XR").
|
graphics) interface ("magic -d CAIRO" or "magic -d XR").
|
||||||
|
|
||||||
|
October, 2017: DRC changes correctly handle DRC errors in a child
|
||||||
|
cell that are effectively corrected by geometry in the parent cell.
|
||||||
|
|
||||||
|
March, 2018: Added better version handling of subcells. "Use"
|
||||||
|
records contain a path (relative or absolute) to the library used
|
||||||
|
by the subcell, and this path is honored as long as it can be
|
||||||
|
found.
|
||||||
|
|
||||||
|
April, 2018: Added the "plow" function back to the level of
|
||||||
|
capability it originally had. This does not include handling of
|
||||||
|
magic extensions since version 7, including non-manhattan geometry,
|
||||||
|
stacked contacts, and DRC rule extensions.
|
||||||
|
|
||||||
4. Version 8.1 Release Notes:
|
4. Version 8.1 Release Notes:
|
||||||
---------------------------------
|
---------------------------------
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -3666,6 +3666,7 @@ cmdDumpParseArgs(cmdName, w, cmd, dummy, scx)
|
||||||
Rect rootBox;
|
Rect rootBox;
|
||||||
Transform *tx_cell, trans_cell;
|
Transform *tx_cell, trans_cell;
|
||||||
char **av;
|
char **av;
|
||||||
|
char *cellnameptr, *fullpathname;
|
||||||
int ac, clen;
|
int ac, clen;
|
||||||
|
|
||||||
if (cmd->tx_argc < 2)
|
if (cmd->tx_argc < 2)
|
||||||
|
|
@ -3680,18 +3681,78 @@ cmdDumpParseArgs(cmdName, w, cmd, dummy, scx)
|
||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Locate the cell specified by the command */
|
/* cellnameptr should not include any path components */
|
||||||
if (CmdIllegalChars(cmd->tx_argv[1], "", "Cell name"))
|
if ((cellnameptr = strrchr(cmd->tx_argv[1], '/')) != NULL)
|
||||||
return (FALSE);
|
{
|
||||||
|
cellnameptr++;
|
||||||
|
/* Allocate extra space for cellname in case it needs an extension */
|
||||||
|
fullpathname = (char *)mallocMagic(strlen(cmd->tx_argv[1]) + 10);
|
||||||
|
strcpy(fullpathname, cmd->tx_argv[1]);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
cellnameptr = cmd->tx_argv[1];
|
||||||
|
fullpathname = NULL;
|
||||||
|
}
|
||||||
|
|
||||||
/* If the name still has ".mag" attached, then strip it. */
|
/* If the name still has ".mag" attached, then strip it. */
|
||||||
clen = strlen(cmd->tx_argv[1]);
|
clen = strlen(cellnameptr);
|
||||||
if ((clen > 4) && !strcmp(cmd->tx_argv[1] + clen - 4, ".mag"))
|
if ((clen > 4) && !strcmp(cellnameptr + clen - 4, ".mag"))
|
||||||
*(cmd->tx_argv[1] + clen - 4) = '\0';
|
*(cellnameptr + clen - 4) = '\0';
|
||||||
|
|
||||||
def = DBCellLookDef(cmd->tx_argv[1]);
|
/* However, if this is a full path, then the full path name must have .mag */
|
||||||
|
if (fullpathname != NULL)
|
||||||
|
{
|
||||||
|
clen = strlen(fullpathname);
|
||||||
|
if ((clen <= 4) || strcmp(fullpathname + clen - 4, ".mag"))
|
||||||
|
strcat(cellnameptr, ".mag");
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Check for illegal characters in the cellname */
|
||||||
|
if (CmdIllegalChars(cellnameptr, "", "Cell name"))
|
||||||
|
{
|
||||||
|
if (fullpathname) freeMagic(fullpathname);
|
||||||
|
return (FALSE);
|
||||||
|
}
|
||||||
|
|
||||||
|
def = DBCellLookDef(cellnameptr);
|
||||||
if (def == (CellDef *) NULL)
|
if (def == (CellDef *) NULL)
|
||||||
def = DBCellNewDef(cmd->tx_argv[1], (char *) NULL);
|
def = DBCellNewDef(cellnameptr, (char *) NULL);
|
||||||
|
|
||||||
|
if (fullpathname != NULL)
|
||||||
|
{
|
||||||
|
/* Check if def already exists. If it points to a */
|
||||||
|
/* different file, then force a rename of the cell and */
|
||||||
|
/* flag a warning. */
|
||||||
|
|
||||||
|
if (def->cd_file != NULL)
|
||||||
|
{
|
||||||
|
/* Note: may want processing to see if absolute paths match */
|
||||||
|
if (strcmp(def->cd_file, fullpathname))
|
||||||
|
{
|
||||||
|
char uniqchar;
|
||||||
|
char *newcellname = (char *)mallocMagic(strlen(cellnameptr) + 3);
|
||||||
|
TxError("Warning: Cell file path mismatch. Existing cell has"
|
||||||
|
" path \"%s\", while %s path is \"%s\".\n",
|
||||||
|
def->cd_file, cmdName, fullpathname);
|
||||||
|
uniqchar = 'a';
|
||||||
|
while (def != NULL)
|
||||||
|
{
|
||||||
|
sprintf(newcellname, "%s_%c", cellnameptr, uniqchar);
|
||||||
|
def = DBCellLookDef(newcellname);
|
||||||
|
uniqchar++;
|
||||||
|
}
|
||||||
|
TxError("Renaming cell to \"%s\" to avoid conflict.", newcellname);
|
||||||
|
def = DBCellNewDef(cellnameptr, (char *)NULL);
|
||||||
|
def->cd_file = StrDup(&def->cd_file, fullpathname);
|
||||||
|
freeMagic(newcellname);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
def->cd_file = StrDup(&def->cd_file, fullpathname);
|
||||||
|
freeMagic(fullpathname);
|
||||||
|
}
|
||||||
|
|
||||||
editDef = EditCellUse->cu_def;
|
editDef = EditCellUse->cu_def;
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue