[csw-devel] SF.net SVN: gar:[20687] csw/mgar/pkg

pfelecan at users.sourceforge.net pfelecan at users.sourceforge.net
Fri Apr 12 16:16:48 CEST 2013


Revision: 20687
          http://gar.svn.sourceforge.net/gar/?rev=20687&view=rev
Author:   pfelecan
Date:     2013-04-12 14:16:47 +0000 (Fri, 12 Apr 2013)
Log Message:
-----------
leocad/trunk: initial build and packaging

Added Paths:
-----------
    csw/mgar/pkg/leocad/
    csw/mgar/pkg/leocad/Makefile
    csw/mgar/pkg/leocad/branches/
    csw/mgar/pkg/leocad/tags/
    csw/mgar/pkg/leocad/trunk/
    csw/mgar/pkg/leocad/trunk/Makefile
    csw/mgar/pkg/leocad/trunk/checksums
    csw/mgar/pkg/leocad/trunk/files/
    csw/mgar/pkg/leocad/trunk/files/0001-Use-POSIX-to-determine-the-file-type.patch

Added: csw/mgar/pkg/leocad/Makefile
===================================================================
--- csw/mgar/pkg/leocad/Makefile	                        (rev 0)
+++ csw/mgar/pkg/leocad/Makefile	2013-04-12 14:16:47 UTC (rev 20687)
@@ -0,0 +1,2 @@
+%:
+	$(MAKE) -C trunk $*


Property changes on: csw/mgar/pkg/leocad/trunk
___________________________________________________________________
Added: svn:ignore
   + work


Added: csw/mgar/pkg/leocad/trunk/Makefile
===================================================================
--- csw/mgar/pkg/leocad/trunk/Makefile	                        (rev 0)
+++ csw/mgar/pkg/leocad/trunk/Makefile	2013-04-12 14:16:47 UTC (rev 20687)
@@ -0,0 +1,41 @@
+# $Id$
+
+NAME			=	leocad
+VERSION			=	0.79.3
+PIECES_VERSION	=	7114
+GARTYPE			=	v2
+
+DESCRIPTION = Virtual Lego brick CAD software
+define BLURB
+  CAD program that allows people to build virtual models using bricks similar
+  to those found in LEGO toys
+endef
+
+MASTER_SITES	=	$(GOOGLE_MIRROR)
+DISTNAME		=	$(NAME)
+DISTFILES		=	$(NAME)-$(VERSION)-src.tgz
+DISTFILES		+=	pieces-$(PIECES_VERSION).zip
+# this raises "warning: 1 line adds whitespace errors"; choosed to ignore
+PATCHFILES		+=	0001-Use-POSIX-to-determine-the-file-type.patch
+
+GARCOMPILER			=	GNU
+
+CONFIGURE_ARGS		=	$(DIRPATHS)
+CONFIGURE_SCRIPTS	=	custom
+
+BUILD_DEP_PKGS		+=	CSWlibglib2-dev
+BUILD_DEP_PKGS		+=	CSWlibgtk2-dev
+BUILD_DEP_PKGS		+=	CSWlibz-dev
+BUILD_DEP_PKGS		+=	CSWlibjpeg-dev
+BUILD_DEP_PKGS		+=	CSWlibpng-dev
+BUILD_DEP_PKGS		+=	CSWmesa
+
+TEST_SCRIPTS		=
+
+include gar/category.mk
+
+PATH := /opt/csw/gnu:/opt/csw/libexec/flex-2.5.35/bin:$(PATH)
+
+configure-custom:
+	cd $(WORKSRC) && $(MAKE) config PREFIX=$(prefix)
+	$(MAKECOOKIE)


Property changes on: csw/mgar/pkg/leocad/trunk/Makefile
___________________________________________________________________
Added: svn:keywords
   + Id

Added: csw/mgar/pkg/leocad/trunk/checksums
===================================================================
--- csw/mgar/pkg/leocad/trunk/checksums	                        (rev 0)
+++ csw/mgar/pkg/leocad/trunk/checksums	2013-04-12 14:16:47 UTC (rev 20687)
@@ -0,0 +1,2 @@
+edea92ce268b761c9da46742e78c106d  leocad-0.79.3-src.tgz
+5be3590d960c546edf1d4dcb72dba7c1  pieces-7114.zip

Added: csw/mgar/pkg/leocad/trunk/files/0001-Use-POSIX-to-determine-the-file-type.patch
===================================================================
--- csw/mgar/pkg/leocad/trunk/files/0001-Use-POSIX-to-determine-the-file-type.patch	                        (rev 0)
+++ csw/mgar/pkg/leocad/trunk/files/0001-Use-POSIX-to-determine-the-file-type.patch	2013-04-12 14:16:47 UTC (rev 20687)
@@ -0,0 +1,58 @@
+From f64ec2a672aa68d43bd7e275cc42af4a9b86b0e0 Mon Sep 17 00:00:00 2001
+From: Peter Felecan <pfelecan at opencsw.org>
+Date: Wed, 3 Apr 2013 12:05:18 +0200
+Subject: [PATCH] Use POSIX to determine the file type
+
+---
+ linux/system.cpp | 18 +++++++++++++++---
+ 1 file changed, 15 insertions(+), 3 deletions(-)
+
+diff --git a/linux/system.cpp b/linux/system.cpp
+index bde6901..b3cf12a 100644
+--- a/linux/system.cpp
++++ b/linux/system.cpp
+@@ -7,7 +7,9 @@
+ #include <gtk/gtk.h>
+ #include <X11/keysym.h>
+ #include <sys/time.h>
++#include <fcntl.h>
+ #include <sys/types.h>
++#include <sys/stat.h>
+ #include <dirent.h>
+ #include "opengl.h"
+ #include "gtkmisc.h"
+@@ -124,7 +126,8 @@ void Sys_GetFileList(const char* Path, ObjArray<String>& FileList)
+ {
+ 	struct dirent* Entry;
+ 	char DirPath[LC_MAXPATH], FilePath[LC_MAXPATH];
+-
++	struct stat statBuff;
++	
+ 	strcpy(DirPath, Path);
+ 	int Length = strlen(DirPath);
+ 	if (DirPath[Length - 1] != '/')
+@@ -141,10 +144,19 @@ void Sys_GetFileList(const char* Path, ObjArray<String>& FileList)
+ 
+ 	while ((Entry = readdir(Dir)))
+ 	{
+-		if (Entry->d_type != DT_REG)
++		if(lstat(Entry->d_name, &statBuff) == -1)
++		{
+ 			continue;
++		}
++		else
++		{
++			if(!S_ISREG(statBuff.st_mode))
++			{
++				continue;
++			}
++		}
+ 
+-		sprintf(FilePath, "%s%s", DirPath, Entry->d_name);
++		snprintf(FilePath, LC_MAXPATH, "%s%s", DirPath, Entry->d_name);
+ 		FileList.Add(FilePath);
+ 	}
+ 
+-- 
+1.8.1.4
+

This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.



More information about the devel mailing list