Bug 178147 - devel/gps: [MAINTAINER] Update for new compiler (gcc-aux) and USES+= ada
Summary: devel/gps: [MAINTAINER] Update for new compiler (gcc-aux) and USES+= ada
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: Baptiste Daroussin
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-04-25 15:50 UTC by John Marino
Modified: 2013-04-30 13:29 UTC (History)
0 users

See Also:


Attachments
file.diff (7.51 KB, patch)
2013-04-25 15:50 UTC, John Marino
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description John Marino 2013-04-25 15:50:01 UTC
devel/gps will not build with the newer lang/gcc-aux without additional patches.

Main points:
1) add the patches for lang/gcc-aux support
2) Add USES+= ada
3) Convert to new options framework

PRs that must be complete first:
ports/178144
ports/178145
ports/178146

It would be nice to wait for ports/178143 but it's not strictly required.

Fix: Patch attached with submission follows:
Comment 1 Edwin Groothuis freebsd_committer freebsd_triage 2013-04-25 15:50:15 UTC
Class Changed
From-To: sw-bug->maintainer-update

Fix category (submitter is maintainer) (via the GNATS Auto Assign Tool)
Comment 2 Baptiste Daroussin freebsd_committer freebsd_triage 2013-04-25 15:57:34 UTC
Responsible Changed
From-To: freebsd-ports-bugs->bapt

I'll take it.
Comment 3 John Marino 2013-04-29 19:07:16 UTC
Hi Bapt,

I forgot the add the following patch for devel/gps.
Just place this file in devel/gps/files:
http://leaf.dragonflybsd.org/~marino/ada/patch-gps_gps.gpr

It is needed on DragonFly because of the newer binutils it has, and it 
is also needed on FreeBSD 8.x because gcc-aux built on that platform 
pulls in newer binutils as well.

Thanks,
John
Comment 4 dfilter service freebsd_committer freebsd_triage 2013-04-30 13:08:23 UTC
Author: bapt
Date: Tue Apr 30 12:08:08 2013
New Revision: 316922
URL: http://svnweb.freebsd.org/changeset/ports/316922

Log:
  Add patches for lang/gcc-aux support
  Add USES+= ada
  Convert to new options framework
  
  PR:		ports/178147
  Submitted by:	John Marino <draco@marino.st>

Added:
  head/devel/gps/files/patch-ada__module_core_src_ada__semantic__tree-generics.adb   (contents, props changed)
  head/devel/gps/files/patch-gps_gps.gpr   (contents, props changed)
  head/devel/gps/files/patch-prj_editor_src_gpr__creation.adb   (contents, props changed)
  head/devel/gps/files/patch-refactoring_core_src_refactoring-services.adb   (contents, props changed)
  head/devel/gps/files/patch-toolchains_editor_core_src_toolchains-parsers.ads   (contents, props changed)
Modified:
  head/devel/gps/Makefile

Modified: head/devel/gps/Makefile
==============================================================================
--- head/devel/gps/Makefile	Tue Apr 30 12:03:14 2013	(r316921)
+++ head/devel/gps/Makefile	Tue Apr 30 12:08:08 2013	(r316922)
@@ -1,48 +1,41 @@
-# New ports collection makefile for:  gps
-# Date created:                       12 December 2010
-# Whom:                               John Marino <draco@marino.st>
-#
+# Created by: John Marino <draco@marino.st>
 # $FreeBSD$
-#
 
 PORTNAME=	gps
 PORTVERSION=	5.0.1
-PORTREVISION=	1
+PORTREVISION=	2
 CATEGORIES=	devel
-MASTER_SITES=	http://downloads.dragonlace.net/src/ \
-		http://dragonlace.mirrors.ada.cx/src/
+MASTER_SITES=	http://downloads.dragonlace.net/src/
 
 MAINTAINER=	draco@marino.st
 COMMENT=	GNAT Programming Studio - IDE for Ada and many other languages
 
-BUILD_DEPENDS=	gnat-aux>20110325:${PORTSDIR}/lang/gnat-aux \
-		gtkada<2.24:${PORTSDIR}/x11-toolkits/gtkada \
+BUILD_DEPENDS=	gtkada<2.24:${PORTSDIR}/x11-toolkits/gtkada \
 		xmlada>=3.2:${PORTSDIR}/textproc/xmlada \
-		gprbuild-aux>=20101120:${PORTSDIR}/devel/gprbuild-aux
+		gprbuild>=20120510:${PORTSDIR}/devel/gprbuild
 RUN_DEPENDS=	gtkada<2.24:${PORTSDIR}/x11-toolkits/gtkada
 LIB_DEPENDS=	gmp.10:${PORTSDIR}/math/gmp
 
-LATEST_LINK=	gps-ide
+LATEST_LINK=		gps-ide
 
 GNU_CONFIGURE=		yes
 USE_GMAKE=		yes
 USE_BZIP2=		yes
 USE_PERL5_BUILD=	yes
 ALL_TARGET=		default
-CC=			gnatgcc
+USES+=			ada
 
 CONFIGURE_ENV+=		AWK=/usr/bin/awk
-MAKE_ENV+=		ADA_PROJECT_PATH=${PREFIX}/lib/gnat
 
-OPTIONS=		SYSLOG "Enable system logging" on
-OPTIONS+=		SQLITE "Enable SQLite database support" off
-OPTIONS+=		PGSQL  "Enable PostgreSQL database support" off
-OPTIONS+=		PYTHON "Enable Python console" off
+OPTIONS_DEFINE=		SYSLOG SQLITE PGSQL PYTHON
+OPTIONS_DEFAULT=	SYSLOG
+
+PYTHON_DESC=		Enable Python console
 
 .include <bsd.port.options.mk>
 
-.if ${ARCH} == "amd64"
-CONFIGURE_TARGET=	x86_64-portbld-freebsd${OSREL}
+.if ${OPSYS} == FreeBSD
+CONFIGURE_TARGET=	${ARCH:S/amd64/x86_64/}-portbld-${OPSYS:L}${OSREL}
 .endif
 
 CONFIGURE_ARGS+=	--with-gmp=${PREFIX}
@@ -51,7 +44,7 @@ CONFIGURE_ARGS+=	--with-gmp=${PREFIX}
 ##  SYSLOG  ##
 ##############
 
-.if defined(WITH_SYSLOG)
+.if ${PORT_OPTIONS:MSYSLOG}
 CONFIGURE_ARGS+=	--enable-syslog=yes
 .else
 CONFIGURE_ARGS+=	--enable-syslog=no
@@ -61,7 +54,7 @@ CONFIGURE_ARGS+=	--enable-syslog=no
 ##  SQLITE  ##
 ##############
 
-.if defined(WITH_SQLITE)
+.if ${PORT_OPTIONS:MSQLITE}
 CONFIGURE_ARGS+=	--with-sqlite=${PREFIX}
 BUILD_DEPENDS+=		sqlite3>=3:${PORTSDIR}/databases/sqlite3
 RUN_DEPENDS+=		sqlite3>=3:${PORTSDIR}/databases/sqlite3
@@ -71,7 +64,7 @@ RUN_DEPENDS+=		sqlite3>=3:${PORTSDIR}/da
 ##  POSTGRESQL  ##
 ##################
 
-.if defined(WITH_PGSQL)
+.if ${PORT_OPTIONS:MPGSQL}
 CONFIGURE_ARGS+=	--with-postgresql=${PREFIX}
 USE_PGSQL=		true
 .endif
@@ -80,12 +73,12 @@ USE_PGSQL=		true
 ##  PYTHON / PYGTK ##
 #####################
 
-.if defined(WITH_PYTHON)
+.if ${PORT_OPTIONS:MPYTHON}
 CONFIGURE_ARGS+=	--with-python=${PREFIX}
 CONFIGURE_ARGS+=	--enable-shared-python=yes
 CONFIGURE_ARGS+=	--enable-pygtk
 PLIST_SUB+=		PYSUPPORT=""
-USE_PYTHON=		2.6-2.7
+USE_PYTHON=		-2.7
 BUILD_DEPENDS+=		py2[67]-gtk>=2.22:${PORTSDIR}/x11-toolkits/py-gtk2
 RUN_DEPENDS+=		py2[67]-gtk>=2.22:${PORTSDIR}/x11-toolkits/py-gtk2
 PYCOMPILE=		${PREFIX}/lib/${PYTHON_VERSION}/compileall.py
@@ -95,12 +88,10 @@ CONFIGURE_ARGS+=	--disable-pygtk
 PLIST_SUB+=		PYSUPPORT="@comment "
 .endif
 
-.include <bsd.port.pre.mk>
-
 pre-install:
-.if defined(WITH_PYTHON)
+.if ${PORT_OPTIONS:MPYTHON}
 	${PYTHON_CMD} ${PYCOMPILE} ${WRKSRC}/share/plug-ins
 	${PYTHON_CMD} ${PYCOMPILE} ${WRKSRC}/share/library
 .endif
 
-.include <bsd.port.post.mk>
+.include <bsd.port.mk>

Added: head/devel/gps/files/patch-ada__module_core_src_ada__semantic__tree-generics.adb
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/devel/gps/files/patch-ada__module_core_src_ada__semantic__tree-generics.adb	Tue Apr 30 12:08:08 2013	(r316922)
@@ -0,0 +1,24 @@
+$NetBSD: patch-ada__module_core_src_ada__semantic__tree-generics.adb,v 1.1 2012/07/08 20:23:50 marino Exp $
+
+--- ada_module/core/src/ada_semantic_tree-generics.adb.orig	2010-09-17 09:28:03.000000000 +0000
++++ ada_module/core/src/ada_semantic_tree-generics.adb
+@@ -389,14 +389,12 @@ package body Ada_Semantic_Tree.Generics
+       Cached : Cache_Access := Get_Cache (Info);
+    begin
+       if Cached /= null then
+-         Result := new Declaration_View_Record'
+-           (Entity          =>
+-              To_Entity_Access
+-                (Instanciated_Package (Cached.all).Generic_Package),
+-            Generic_Context =>
++         Result := new Declaration_View_Record;
++         Declaration_View_Record (Result.all).Generic_Context :=
+               To_Active
+-                (Instanciated_Package (Cached.all).Generic_Context),
+-            others => <>);
++                (Instanciated_Package (Cached.all).Generic_Context);
++         Result.Entity := To_Entity_Access
++           (Instanciated_Package (Cached.all).Generic_Package);
+ 
+          Ref (Declaration_View_Record (Result.all).Generic_Context);
+ 

Added: head/devel/gps/files/patch-gps_gps.gpr
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/devel/gps/files/patch-gps_gps.gpr	Tue Apr 30 12:08:08 2013	(r316922)
@@ -0,0 +1,14 @@
+$NetBSD: patch-gps_gps.gpr,v 1.2 2012/05/16 17:56:49 marino Exp $
+
+--- gps/gps.gpr.orig	2012-01-28 15:08:25.689555000 +0000
++++ gps/gps.gpr
+@@ -73,7 +73,8 @@ project GPS is
+          when "Windows_NT" =>
+             for Default_Switches ("Ada") use ("obj/gps.res");
+          when "unix" =>
+-            null;
++            for Default_Switches ("Ada") use ("-lXrender", "-lX11",
++               "-lgmodule-2.0");
+       end case;
+       --  for Default_Switches ("Ada") use ("-lgmem");
+       --  for Default_Switches ("Ada") use ("-pg");

Added: head/devel/gps/files/patch-prj_editor_src_gpr__creation.adb
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/devel/gps/files/patch-prj_editor_src_gpr__creation.adb	Tue Apr 30 12:08:08 2013	(r316922)
@@ -0,0 +1,12 @@
+$NetBSD: patch-prj_editor_src_gpr__creation.adb,v 1.1 2012/07/08 20:23:50 marino Exp $
+
+--- prj_editor/src/gpr_creation.adb.orig	2010-03-30 08:12:23.000000000 +0000
++++ prj_editor/src/gpr_creation.adb
+@@ -571,6 +571,7 @@ package body GPR_Creation is
+       Current_Project : Integer;
+       All_Source_Dirs : Boolean := False)
+    is
++      pragma Unreferenced (Root_Project);
+       Current_Dir : Natural;
+       Tmp         : Import_Project_Error;
+    begin

Added: head/devel/gps/files/patch-refactoring_core_src_refactoring-services.adb
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/devel/gps/files/patch-refactoring_core_src_refactoring-services.adb	Tue Apr 30 12:08:08 2013	(r316922)
@@ -0,0 +1,12 @@
+$NetBSD: patch-refactoring_core_src_refactoring-services.adb,v 1.1 2012/07/08 20:23:50 marino Exp $
+
+--- refactoring/core/src/refactoring-services.adb.orig	2010-10-01 14:01:51.000000000 +0000
++++ refactoring/core/src/refactoring-services.adb
+@@ -1318,6 +1318,7 @@ package body Refactoring.Services is
+       Direction : Integer := 1) return Editor_Location'Class
+    is
+       Loc : Editor_Location'Class := From;
++      pragma Unreferenced (Direction);
+       Seen_Comment : Boolean := False;
+    begin
+       loop

Added: head/devel/gps/files/patch-toolchains_editor_core_src_toolchains-parsers.ads
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/devel/gps/files/patch-toolchains_editor_core_src_toolchains-parsers.ads	Tue Apr 30 12:08:08 2013	(r316922)
@@ -0,0 +1,22 @@
+$NetBSD: patch-toolchains_editor_core_src_toolchains-parsers.ads,v 1.1 2012/07/08 20:23:50 marino Exp $
+
+--- toolchains_editor/core/src/toolchains-parsers.ads.orig	2010-09-21 08:15:41.000000000 +0000
++++ toolchains_editor/core/src/toolchains-parsers.ads
+@@ -73,7 +73,7 @@ package Toolchains.Parsers is
+    type Parsed_Project_Record is private;
+    type Parsed_Project is access all Parsed_Project_Record;
+ 
+-   type Project_Parser_Record is private;
++   type Project_Parser_Record is limited private;
+    type Project_Parser is access all Project_Parser_Record;
+ 
+    --------------------
+@@ -184,7 +184,7 @@ private
+    package Parsed_Projects_Maps is new Ada.Containers.Ordered_Maps
+      (Project_Node_Id, Parsed_Project);
+ 
+-   type Project_Parser_Record is record
++   type Project_Parser_Record is limited record
+       Manager                : Toolchain_Manager;
+ 
+       Tree_Data              : Project_Tree_Ref;
_______________________________________________
svn-ports-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-ports-all
To unsubscribe, send any mail to "svn-ports-all-unsubscribe@freebsd.org"
Comment 5 Baptiste Daroussin freebsd_committer freebsd_triage 2013-04-30 13:29:33 UTC
State Changed
From-To: open->closed

Committed. Thanks!