public inbox for gcc@gcc.gnu.org
 help / color / mirror / Atom feed
* Can cppalloc.c be removed?
@ 1999-09-04  7:30 Kaveh R. Ghazi
  1999-09-04  7:50 ` Per Bothner
  1999-09-30 18:02 ` Kaveh R. Ghazi
  0 siblings, 2 replies; 8+ messages in thread
From: Kaveh R. Ghazi @ 1999-09-04  7:30 UTC (permalink / raw)
  To: bothner, brolley; +Cc: egcs

Now that libiberty.a is linked with everywhere (except for modules
including hconfig.h,) can cppalloc.c be removed or is libcpp.a
expected to be usable as a standaline library and therefore must
provide its own xmalloc, etc?

		Thanks,
		--Kaveh
--
Kaveh R. Ghazi			Engagement Manager / Project Services
ghazi@caip.rutgers.edu		Qwest Internet Solutions

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: Can cppalloc.c be removed?
  1999-09-04  7:30 Can cppalloc.c be removed? Kaveh R. Ghazi
@ 1999-09-04  7:50 ` Per Bothner
  1999-09-30 18:02   ` Per Bothner
  1999-09-30 18:02 ` Kaveh R. Ghazi
  1 sibling, 1 reply; 8+ messages in thread
From: Per Bothner @ 1999-09-04  7:50 UTC (permalink / raw)
  To: Kaveh R. Ghazi; +Cc: egcs

"Kaveh R. Ghazi" <ghazi@caip.rutgers.edu> writes:

> Now that libiberty.a is linked with everywhere (except for modules
> including hconfig.h,) can cppalloc.c be removed or is libcpp.a
> expected to be usable as a standaline library and therefore must
> provide its own xmalloc, etc?

One of the goals of cpplib is that it can be used as a stand-alone
library with a public API.  One obvious application is using cpplib to
mscro-expand C/C++ expressions when typed at the Gdb command line.

One reason for a separate cppalloc.c was to provide some flexibility;
specifically, I did not want xmalloc etc to be *required*, just because
cpplib might be linked with aplications that have their own xmalloc.

I don't know if this specifically answers your question.  Note that
Gdb does use libiberty, and does use (a version of) xmalloc.  So I
suspect you can remove cppalloc.c, as long as we specify in the cpplib
public interface that the cpplib client must provide xmalloc etc.
-- 
	--Per Bothner
bothner@pacbell.net  per@bothner.com   http://home.pacbell.net/bothner/

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: Can cppalloc.c be removed?
  1999-09-04  7:50 ` Per Bothner
@ 1999-09-30 18:02   ` Per Bothner
  0 siblings, 0 replies; 8+ messages in thread
From: Per Bothner @ 1999-09-30 18:02 UTC (permalink / raw)
  To: Kaveh R. Ghazi; +Cc: egcs

"Kaveh R. Ghazi" <ghazi@caip.rutgers.edu> writes:

> Now that libiberty.a is linked with everywhere (except for modules
> including hconfig.h,) can cppalloc.c be removed or is libcpp.a
> expected to be usable as a standaline library and therefore must
> provide its own xmalloc, etc?

One of the goals of cpplib is that it can be used as a stand-alone
library with a public API.  One obvious application is using cpplib to
mscro-expand C/C++ expressions when typed at the Gdb command line.

One reason for a separate cppalloc.c was to provide some flexibility;
specifically, I did not want xmalloc etc to be *required*, just because
cpplib might be linked with aplications that have their own xmalloc.

I don't know if this specifically answers your question.  Note that
Gdb does use libiberty, and does use (a version of) xmalloc.  So I
suspect you can remove cppalloc.c, as long as we specify in the cpplib
public interface that the cpplib client must provide xmalloc etc.
-- 
	--Per Bothner
bothner@pacbell.net  per@bothner.com   http://home.pacbell.net/bothner/

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Can cppalloc.c be removed?
  1999-09-04  7:30 Can cppalloc.c be removed? Kaveh R. Ghazi
  1999-09-04  7:50 ` Per Bothner
@ 1999-09-30 18:02 ` Kaveh R. Ghazi
  1 sibling, 0 replies; 8+ messages in thread
From: Kaveh R. Ghazi @ 1999-09-30 18:02 UTC (permalink / raw)
  To: bothner, brolley; +Cc: egcs

Now that libiberty.a is linked with everywhere (except for modules
including hconfig.h,) can cppalloc.c be removed or is libcpp.a
expected to be usable as a standaline library and therefore must
provide its own xmalloc, etc?

		Thanks,
		--Kaveh
--
Kaveh R. Ghazi			Engagement Manager / Project Services
ghazi@caip.rutgers.edu		Qwest Internet Solutions

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: Can cppalloc.c be removed?
  1999-09-05  0:34 ` Per Bothner
@ 1999-09-30 18:02   ` Per Bothner
  0 siblings, 0 replies; 8+ messages in thread
From: Per Bothner @ 1999-09-30 18:02 UTC (permalink / raw)
  To: egcs

"Kaveh R. Ghazi" <ghazi@caip.rutgers.edu> writes:

> Thanks for the information.  After some poking around, I don't think
> we can remove cppalloc.c just yet.  We link libcpp.a with fix-header
> and gen-protos.  Neither of them is linked with libiberty.a because
> they are "build" ("host"?) programs.

fix-header and gen-protos (like fix-includes) should only be run
when build==host==target, so I don't think that is a problem.
-- 
	--Per Bothner
bothner@pacbell.net  per@bothner.com   http://home.pacbell.net/bothner/

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: Can cppalloc.c be removed?
  1999-09-04 19:38 Kaveh R. Ghazi
  1999-09-05  0:34 ` Per Bothner
@ 1999-09-30 18:02 ` Kaveh R. Ghazi
  1 sibling, 0 replies; 8+ messages in thread
From: Kaveh R. Ghazi @ 1999-09-30 18:02 UTC (permalink / raw)
  To: per; +Cc: egcs

 > From: Per Bothner <per@bothner.com>
 > 
 > "Kaveh R. Ghazi" <ghazi@caip.rutgers.edu> writes:
 > 
 > > Now that libiberty.a is linked with everywhere (except for modules
 > > including hconfig.h,) can cppalloc.c be removed or is libcpp.a
 > > expected to be usable as a standaline library and therefore must
 > > provide its own xmalloc, etc?
 > 
 > One of the goals of cpplib is that it can be used as a stand-alone
 > library with a public API.  One obvious application is using cpplib to
 > mscro-expand C/C++ expressions when typed at the Gdb command line.
 > 
 > One reason for a separate cppalloc.c was to provide some flexibility;
 > specifically, I did not want xmalloc etc to be *required*, just because
 > cpplib might be linked with aplications that have their own xmalloc.
 > 
 > I don't know if this specifically answers your question.  Note that
 > Gdb does use libiberty, and does use (a version of) xmalloc.  So I
 > suspect you can remove cppalloc.c, as long as we specify in the cpplib
 > public interface that the cpplib client must provide xmalloc etc.
 > -- 
 > 	--Per Bothner

Thanks for the information.  After some poking around, I don't think
we can remove cppalloc.c just yet.  We link libcpp.a with fix-header
and gen-protos.  Neither of them is linked with libiberty.a because
they are "build" ("host"?) programs.

I think we'll eventually compile both "host" and "build" copies of
libiberty.a, but until then we need cppalloc.c.

Now something doesn't look right, libcpp.a is linked with both "host"
and "build" programs but I see no mechanism to compile two copies of
it.  It something wrong here, or am I not seeing things right?

		--Kaveh
--
Kaveh R. Ghazi			Engagement Manager / Project Services
ghazi@caip.rutgers.edu		Qwest Internet Solutions

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: Can cppalloc.c be removed?
  1999-09-04 19:38 Kaveh R. Ghazi
@ 1999-09-05  0:34 ` Per Bothner
  1999-09-30 18:02   ` Per Bothner
  1999-09-30 18:02 ` Kaveh R. Ghazi
  1 sibling, 1 reply; 8+ messages in thread
From: Per Bothner @ 1999-09-05  0:34 UTC (permalink / raw)
  To: egcs

"Kaveh R. Ghazi" <ghazi@caip.rutgers.edu> writes:

> Thanks for the information.  After some poking around, I don't think
> we can remove cppalloc.c just yet.  We link libcpp.a with fix-header
> and gen-protos.  Neither of them is linked with libiberty.a because
> they are "build" ("host"?) programs.

fix-header and gen-protos (like fix-includes) should only be run
when build==host==target, so I don't think that is a problem.
-- 
	--Per Bothner
bothner@pacbell.net  per@bothner.com   http://home.pacbell.net/bothner/

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: Can cppalloc.c be removed?
@ 1999-09-04 19:38 Kaveh R. Ghazi
  1999-09-05  0:34 ` Per Bothner
  1999-09-30 18:02 ` Kaveh R. Ghazi
  0 siblings, 2 replies; 8+ messages in thread
From: Kaveh R. Ghazi @ 1999-09-04 19:38 UTC (permalink / raw)
  To: per; +Cc: egcs

 > From: Per Bothner <per@bothner.com>
 > 
 > "Kaveh R. Ghazi" <ghazi@caip.rutgers.edu> writes:
 > 
 > > Now that libiberty.a is linked with everywhere (except for modules
 > > including hconfig.h,) can cppalloc.c be removed or is libcpp.a
 > > expected to be usable as a standaline library and therefore must
 > > provide its own xmalloc, etc?
 > 
 > One of the goals of cpplib is that it can be used as a stand-alone
 > library with a public API.  One obvious application is using cpplib to
 > mscro-expand C/C++ expressions when typed at the Gdb command line.
 > 
 > One reason for a separate cppalloc.c was to provide some flexibility;
 > specifically, I did not want xmalloc etc to be *required*, just because
 > cpplib might be linked with aplications that have their own xmalloc.
 > 
 > I don't know if this specifically answers your question.  Note that
 > Gdb does use libiberty, and does use (a version of) xmalloc.  So I
 > suspect you can remove cppalloc.c, as long as we specify in the cpplib
 > public interface that the cpplib client must provide xmalloc etc.
 > -- 
 > 	--Per Bothner

Thanks for the information.  After some poking around, I don't think
we can remove cppalloc.c just yet.  We link libcpp.a with fix-header
and gen-protos.  Neither of them is linked with libiberty.a because
they are "build" ("host"?) programs.

I think we'll eventually compile both "host" and "build" copies of
libiberty.a, but until then we need cppalloc.c.

Now something doesn't look right, libcpp.a is linked with both "host"
and "build" programs but I see no mechanism to compile two copies of
it.  It something wrong here, or am I not seeing things right?

		--Kaveh
--
Kaveh R. Ghazi			Engagement Manager / Project Services
ghazi@caip.rutgers.edu		Qwest Internet Solutions

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~1999-09-30 18:02 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1999-09-04  7:30 Can cppalloc.c be removed? Kaveh R. Ghazi
1999-09-04  7:50 ` Per Bothner
1999-09-30 18:02   ` Per Bothner
1999-09-30 18:02 ` Kaveh R. Ghazi
1999-09-04 19:38 Kaveh R. Ghazi
1999-09-05  0:34 ` Per Bothner
1999-09-30 18:02   ` Per Bothner
1999-09-30 18:02 ` Kaveh R. Ghazi

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).