English Amiga Board


Go Back   English Amiga Board > Coders > Coders. General

 
 
Thread Tools
Old 28 January 2018, 16:49   #1
elwis
 
Posts: n/a
SASC - Hello inutition world?

For some reason I decided to create a small intuition app on the Amiga1200 I finally bought the other week. (I'm actually not much of a C programmer nowadays, mostly Java/.NET)

So I got SAS/C installed and had no problems at all creating the oh so famous "Hello world". However, Inuition.. I downloaded the NDK39 to data:ndk and then I struggled with makefiles and console compiles but inution is definietly undefined. Do I need to do some assigns? (Havent used an amiga for 20 years so bear with me), or is it something I missed in SASC settings?


Regards

Last edited by elwis; 28 January 2018 at 17:23.
 
Old 28 January 2018, 17:21   #2
emufan
Registered User
 
Join Date: Feb 2012
Location: #DrainTheSwamp
Posts: 4,545
I have this in my user-startup:
Code:
; SAS/C assigns
assign sc: dh1:sc
assign include: sc:include
assign cxxinclude: sc:cxxinclude
assign lib: sc:lib
assign c: dh1:sc/c ADD
assign libs: dh1:sc/libs ADD
; end
sc: is the installations folder of SAS/C

in an smakefile you can put some definitions in like this:
Code:
UINC    = /SDK/include/
ULIB    = /SDK/lib/
CFLAGS  = cpu=68020 math=68881 opt nostkchk idir=$(UINC) idir=cxxinclude:

blotchGUI.p: blotch.o gui_help.o
        sc link $(CFLAGS) startup=$(ULIB)serv_s.o $(ULIB)server.lib \
        blotch.o gui_help.o  pname=$@

blotch.o:
        sc $(CFLAGS) blotch.c

gui_help.o:
        sc $(CFLAGS) gui_help.c

all: blotchGUI.p

clean:
        delete \#?.o \#?.p
with smakefile in your source folder you start to build it with:
Code:
smake
maybe you can try this with the data:ndk folder - added in user-startup:
Code:
assign include: data:ndk ADD
something usefull for the SCOPTIONS file - put this file in your source folder:
Code:
VERBOSE
ERRORREXX
NOICONS
there is a default SCOPTIONS in envarc:sc/ which you may edit accordingly

Last edited by emufan; 28 January 2018 at 17:43.
emufan is offline  
Old 28 January 2018, 17:43   #3
elwis
 
Posts: n/a
Thanks for helping, I'll just try to code that simple example :http://www.pjhutchison.org/tutorial/screens.html together and then I'll try your setup.

This is great fun, feel like I'm back in 1997 trying to compile hello world on my first Linux machine. I Will wire you a pizza & a beer if it works
 
Old 28 January 2018, 17:52   #4
elwis
 
Posts: n/a
wooohoo! You saved the day for sure! Now I can start coding for real, thank you!
 
Old 28 January 2018, 18:11   #5
emufan
Registered User
 
Join Date: Feb 2012
Location: #DrainTheSwamp
Posts: 4,545
Quote:
Originally Posted by elwis View Post
wooohoo! You saved the day for sure! Now I can start coding for real, thank you!
ok, cool

#1) some more examples using SAS/C you may find on aminet.
a simple search for a smakefile in the archives.

Last edited by emufan; 28 January 2018 at 18:26.
emufan is offline  
Old 28 January 2018, 18:40   #6
elwis
 
Posts: n/a
Thanks, I forgot about aminet, there's usually a lot of examples to be found there.
(and I still owe you that pizza & beer)

Last edited by elwis; 28 January 2018 at 19:06.
 
Old 28 January 2018, 20:15   #7
emufan
Registered User
 
Join Date: Feb 2012
Location: #DrainTheSwamp
Posts: 4,545
Quote:
Originally Posted by elwis View Post
Thanks, I forgot about aminet, there's usually a lot of examples to be found there.
(and I still owe you that pizza & beer)
ok, I keep that in mind
emufan is offline  
 


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools

Similar Threads
Thread Thread Starter Forum Replies Last Post
Another World andrewwan1980 Retrogaming General Discussion 25 22 March 2013 20:35
Another World... DamienD project.TOSEC (amiga only) 22 14 April 2008 16:56
Another World fmcpma support.Games 4 29 May 2007 18:46
Sasc swampcretin request.Apps 2 29 May 2005 14:52

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +2. The time now is 10:10.

Top

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
Page generated in 0.18942 seconds with 13 queries