강현태

init

//
// Client.c
// RandomChat
//
// Created by 강현태 on 2017. 12. 20..
// Copyright © 2017년 KHU. All rights reserved.
//
#include "Client.h"
//
// Client.h
// RandomChat
//
// Created by 강현태 on 2017. 12. 20..
// Copyright © 2017년 KHU. All rights reserved.
//
#ifndef Client_h
#define Client_h
#include <stdio.h>
#endif /* Client_h */
CC = gcc
main : main.o Server.o
$(CC) -o $@ $<
main.o : Server.h main.c
gcc -c -o $^
Server.o : Server.h Server.c
gcc -c -o $^
clean :
rm -f $(all)
......@@ -6,10 +6,27 @@
objectVersion = 48;
objects = {
/* Begin PBXFileReference section */
61D9C4A11FE94CD3000D9240 /* Server.c */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.c; path = Server.c; sourceTree = "<group>"; usesTabs = 1; };
61D9C4A21FE94DD3000D9240 /* main.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = main.h; sourceTree = "<group>"; };
61D9C4A31FE94DD3000D9240 /* main.c */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.c; path = main.c; sourceTree = "<group>"; usesTabs = 1; };
61D9C4A41FE95072000D9240 /* Makefile */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.make; path = Makefile; sourceTree = "<group>"; usesTabs = 1; };
61D9C4AB1FEA6390000D9240 /* Server.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = Server.h; sourceTree = "<group>"; };
61D9C4AC1FEA639F000D9240 /* Client.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = Client.h; sourceTree = "<group>"; };
61D9C4AD1FEA639F000D9240 /* Client.c */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.c; path = Client.c; sourceTree = "<group>"; };
/* End PBXFileReference section */
/* Begin PBXGroup section */
6102FFC01FE94C7C0021C471 = {
isa = PBXGroup;
children = (
61D9C4AC1FEA639F000D9240 /* Client.h */,
61D9C4AD1FEA639F000D9240 /* Client.c */,
61D9C4AB1FEA6390000D9240 /* Server.h */,
61D9C4A11FE94CD3000D9240 /* Server.c */,
61D9C4A21FE94DD3000D9240 /* main.h */,
61D9C4A31FE94DD3000D9240 /* main.c */,
61D9C4A41FE95072000D9240 /* Makefile */,
);
sourceTree = "<group>";
};
......
//
// Server.c
// RandomChat
//
// Created by 강현태 on 2017. 12. 19..
// Copyright © 2017년 KHU. All rights reserved.
//
#include "Server.h"
int openServer(){
int serverSock;
struct sockaddr_in servAddr;
if((serverSock=socket(PF_INET,SOCK_STREAM,0))<0){
return -1;
}
bzero(&servAddr,sizeof(servAddr));
return 1;
}
//
// Server.h
// RandomChat
//
// Created by 강현태 on 2017. 12. 20..
// Copyright © 2017년 KHU. All rights reserved.
//
#ifndef Server_h
#define Server_h
#endif /* Server_h */
//
// main.c
// RandomChat
//
// Created by 강현태 on 2017. 12. 19..
// Copyright © 2017년 KHU. All rights reserved.
//
#include "main.h"
int main(){
return 0;
}
//
// main.h
// RandomChat
//
// Created by 강현태 on 2017. 12. 19..
// Copyright © 2017년 KHU. All rights reserved.
//
#ifndef main_h
#define main_h
#include <stdio.h>
#include "Server.h"
#endif /* main_h */