HELP ME BUILD THE SIMPEST MAX EXTERNAL :) 'ext.h' not found

Austin B Stockwell's icon

HELLO GUYS. I AM COMPLETELY LOST as how to build THE SIMPLEST max external. PLEASE HELP. Can't find help anywhere on this that seems to help me with my current knowledge set.

I NEED HELP MAKING SURE I AM NOT MISSING SOMETHING

I have...
1) DOWNLOADED X CODE & ECLIPSE
2) PLACE MAX 7 SDK FOLDER IN 'PACKAGES' FOLDER Documents >> Max 7 >> Packages >> Max7SDK
3) ADD 'max7SDK' PATH TO MAX/MSP file path
4) OPEN ECLIPSE/XCODE
5) TYPE CODE -- RUN CODE --
6) BUILD FAILED??? 'ERROR MESSAGE: 'EXT.H' NOT FOUND

I WAS TOLD TO USE XCODE. However, every example I have found has a bundle entitled "carbon" and I do not have that on my version of XCODE ( I am using 8.0) OSX 10.11.

IF I USED XCODE:

1) Which PROJECT TEMPLATE do I choose to begin writing THE MOST BASIC MAX EXTERNAL.
2) Do I need to add the MAX SDK folder to an X-Code directory? If so, how?

FINALLY:

I've tried to open some of the "help" examples within MAX (such as dummy.maxhelp) but the objects are not found in the patch itself. (Although the MAX folder path includes the SDK folders/subfolders). I have attached an image of this.

Any help guys?

HERE IS THE CODE THAT GIVES ME THE "EXT.H NOT FOUND" ERROR.

I may be missing crucial pieces/structure of the code! Please help!

/*
============================================================================
Name : Hello_World.c
Author : Austin Stockwell
Version :
Copyright : Your copyright notice
Description : Hello World in C, Ansi-style
============================================================================
*/
#include "ext.h" // should always be first, followed by ext_obex.h and any other files.
#include
#include
#include
//#include
//#include

typedef struct _simp
{
t_object s_obj; // t_object header
long s_value; // something else
} t_simp;

static t_class *s_simp_class; // global pointer to our class definition that is setup in ext_main()
void ext_main(void *r)
{
t_class *c;
c = class_new("simp", (method)simp_new, (method)NULL, sizeof(t_simp), 0L, 0);
class_addmethod(c, (method)simp_int, "int", A_LONG, 0);
class_addmethod(c, (method)simp_bang, "bang", 0);
class_register(CLASS_BOX, c);
s_simp_class = c;
}

void *simp_new()
{
t_simp *x = (t_simp *)object_alloc(s_simp_class);
x->s_value = 0;
return x; }

int main(void) {
    puts("!!!Does this work?!!"); /* prints !!!Hello World!!! */
    return EXIT_SUCCESS;
}

Austin B Stockwell's icon

SOLVED: USED EXAMPLES UNDER 'HELP FOLDER' OF SDK

THEN OPENED XCODE TEMPLATE

CHANGED BUILD TO "32 BIT"

BUILD EXTERNAL WITHIN XCODE

OPEN MAX

TYPE NAME OF EXTERNAL

VOILA! RUNNING EXTERNAL :)