The eval() function evaluates a string, as it would be a Python instruction. I don't see why you'd need to have it here.
You did not declare your width and length variables, they do not exist, and they do not have any value assigned to them.
Your program would run if the code would be something like this:
length = int(input("Length? "))
width = int(input("Width? "))
if width == length:
print("It is a square")
else:
print("It is a rectangle")