Quantcast
Channel: Active questions tagged gcc - Stack Overflow
Viewing all articles
Browse latest Browse all 22016

16-Bit Error When Developing OpenGL Application on Windows

$
0
0

First, the background information - the question itself follows in bold.

I am trying to learn how to write OpenGL programs on 64-Bit Windows 10 Home (Version 21H2 OS Build 19044.1706). I program using Notepad++ as a text editor, and build via batch scripts and command prompt. I do not want to use an IDE or advanced build tools as I have found minimalistic tools to be easier for me to learn.

My development environment is as follows:

I have downloaded the .zip files for GLEW and freeglut from graphics.ucdenver.edu, and extracted the files to Desktop\Graphics\Dependencies\Glew and Desktop\Graphics\Dependencies\FreeGlut, respectively.

In Desktop\Graphics, I have included the code from https://github.com/TransmissionZero/Hello-GLUT as a test, and I am trying to build it using the following batch script:

@echo off

gcc -c %1.c -o %1.exe -I"C:\Users\myusername\Desktop\Graphics\Dependencies\FreeGlut\include" -L"C:\Users\myusername\Desktop\Graphics\Dependencies\FreeGlut\lib" -I"C:\Users\myusername\Desktop\Graphics\Dependencies\Glew\include" -L"C:\Users\myusername\Desktop\Graphics\Dependencies\Glew\lib" -lopengl32 -lbz2 -Wl,--subsystem,windows -Wall

where I am passing the location of the C program (TransmissionZero\HelloGLUT\HelloGLUT) as the command line argument.

The command succeeds without errors or warnings, but when I run the exe, I get "Unsupported 16-Bit Application" and the example program does not run. How do I resolve this issue?


Viewing all articles
Browse latest Browse all 22016

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>