473,772 Members | 2,402 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

C++ SDL Makefile for MPW on Mac OS 9

MPD
Hi, I'm new to the MPW (Mac Programmers Workshop -- Apple's now freely
avilable development tools for Classic Mac OS's) and wish to construct
a simple 2D game using MPW's C++ compiler and SDL.

However I don't know how to write a C++ makefile that initializes both
SDL and C++ (not C) in MPW. I have got the SDL examples that came with
the Mac Classic SDL Development Binaries to compile however they are
all written in straight C and as such don't use object orientation
(and MPW passes the code to a C compiler called rather than use a
backwards compatible C++ compiler).

I know that this is down to the makefile MPW needs to compile C++
rather than C programs but I have no idea how to write one as I've
only started using MPW in the last 2 days. Can anyone tell me how to
construt a C++ makefile that initializes a simple C++ class along with
all the relevant SDL header files and Libraries:

simple_class.h

main.cpp // object of simple_class gets initialised here
// also simple SDL window initialised

Very simple stuff I know, but I'm stuck! Any help will be much
appreciated, thanks!!
Jul 23 '05 #1
1 3106
MPD wrote:
Hi, I'm new to the MPW (Mac Programmers Workshop -- Apple's now freely
avilable development tools for Classic Mac OS's) and wish to construct
a simple 2D game using MPW's C++ compiler and SDL.

However I don't know how to write a C++ makefile that initializes both
SDL and C++ (not C) in MPW. I have got the SDL examples that came with
the Mac Classic SDL Development Binaries to compile however they are
all written in straight C and as such don't use object orientation
(and MPW passes the code to a C compiler called rather than use a
backwards compatible C++ compiler).

I know that this is down to the makefile MPW needs to compile C++
rather than C programs but I have no idea how to write one as I've
only started using MPW in the last 2 days. Can anyone tell me how to
construt a C++ makefile that initializes a simple C++ class along with
all the relevant SDL header files and Libraries:


Just use MPW's CreateMake tool. Invoke it via the commando interface and
then just pick the source files that you need to include in the build.

Paul
Jul 23 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
11769
by: Bryan Olson | last post by:
Here's the problem: Suppose we use: import socket f = some_socket.makefile() Then: f.read() is efficient, but verbose, and incorrect (or at least does not play will with others);
1
4652
by: Jamie Saker | last post by:
I think I'm overlooking something assumed in socket's makefile method. Googling several hours and digging thru the python reference didn't help - I think I'm overlooking an assumption between Python and UNIX socket objects neither is explicitely discussing. I think my mknod In the makefile operation on socket (pydoc socket.socket.makefile... using AF_UNIX, allowing you to create a file object to correspond to a socket) I've got an sample...
4
3284
by: newbiecpp | last post by:
I am very sorry to post this one because I know it is out of topic but I cannot find the proper news group. I understand that most senior C++ programmers know makefile very well. My question is GNU makefile support command line argument? I want to write a makefile so that when you invoke "make test", the makefile will compile test like this: $project = "command line argument, i.e., test";
4
2904
by: Sharp Tool | last post by:
Hi I have downloaded a program that is written in C++ that I would like to compile into a Win XP executable. The program contains a Makefile written for Unix/linux/cygwin. I would like to modify it, if neccessary, so that I can compile it using MS Visual C++ 6.0. Here is the code for the Makefile: //START
2
3021
by: Juhan Voolaid | last post by:
Hello I need help with my makefile, so that when I compile my project the source code files would be separated from the object (*.o) files. So if I have: main.cpp and classes.cpp - the filestructure should be like that: project_dir/ source_dir/ main.cpp
4
3959
by: Jess | last post by:
Hello, I am now trying to use makefile to compile C++ programs. My makefile looks like: f1.o : f1.cpp h1.h h2.h g++ -c f1.cpp f2.o : f2.cpp h2.h h3.h g++ -c f2.cpp
8
3197
by: xz | last post by:
I am a rookie of C++ and got so confused with the Makefile these days. Could anyone be so kind and give a little sample Makefile for the following particular example? Let's say I have the following files describing 4 classes (A, B, C1, C2) and a test program (test.cpp) which runs a test for classes C1 and C2. A.h A.cpp
1
5044
by: rpjanaka | last post by:
I am using an open source library called IGI_UDP for measure the available bandwidth of a link (http://www.cs.cmu.edu/%7Ehnn/igi/ ). with that library they have provided a "Makefile" which is not an auto generated one. the following is the given Makefile, ***************************************************************** CC = gcc INCS = -I. CFLAGS = -g -Wall $(DEFS) $(INCS)
5
3302
by: M.Liang Liu | last post by:
I have a project with the following dirs: --------------------------------------------------------------------------------------- +src |-proj0 |-program1 |-program2 |-proj1 |-program1 |-program2 |-program3
2
2146
by: chutsu | last post by:
I'm basically a summer student working on a program called Rivet. (http://projects.hepforge.org/rivet/) And I'm trying to port it to BOINC so that the hosts can download the BOINC client and do some calculation over a large clusters of computers. Me being an absolute beginner at programming, I don't know how to update the Makefile in Rivet! I edited the Makefile.am in the src directory to include the BOINC APIs and Libraries, but what do...
0
9619
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9454
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
1
7460
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6713
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5354
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5482
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4007
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
3609
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2850
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.