Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

gcc error: 'min' is not defined in this scope using gcc 4.5.2 on Windows 7 64-bit #147

Open
GoogleCodeExporter opened this issue Mar 18, 2015 · 2 comments

Comments

@GoogleCodeExporter
Copy link

Building in Windows 7 64-bit using EPD 6.3-2 I got the above error. I fixed it 
and was able to compile the 2.1.8 tagged version from GitHub by adding:

#if !defined(max)
#define max(a, b) ((a) > (b) ? (a) : (b))
#define min(a, b) ((a) < (b) ? (a) : (b))
#endif

to several of the C++ files

Sorry if someone else has reported this issue.

Original issue reported on code.google.com by [email protected] on 3 Jan 2011 at 7:24

@GoogleCodeExporter
Copy link
Author

I'll look into this, but !defined(max) doesn't work for installations that use 
a max template.

Also, I don't really want to support gcc builds on Windows.  Is there a reason 
the VC++ builds on Windows doesn't work for you?  There is event a prebuilt 
installer for 2.7.  (And I'm getting requests for 2.6 x64, so I'll try to 
supply those also.)

Original comment by mkleehammer on 6 Feb 2011 at 7:44

  • Changed state: Accepted
  • Added labels: Type-Enhancement
  • Removed labels: Type-Defect

@GoogleCodeExporter
Copy link
Author

Well, I can understand not wanting to support gcc builds on Windows. But a lot 
of 64-bit Windows users will be opting for the headache-free Enthought 
distribution (especially scientific users), which comes bundled with gcc set up 
to easily build any additional libraries. Whereas getting a working VC++ 2008 
setup is kind of a hassle (requires downloading ISOs from Microsoft, 
installing, rigging up distutils, etc.). 

Thanks for looking into it!

Original comment by [email protected] on 6 Feb 2011 at 7:51

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant