4 messages in com.perforce.perforce-user[p4] Shared code
FromSent OnAttachments
Suttenbach, Roger21 Aug 2000 01:12 
axel...@coremedia-ag.com21 Aug 2000 03:18 
Robert Cowham21 Aug 2000 03:34 
Jeff A. Bowles21 Aug 2000 08:22 
Subject:[p4] Shared code
From:Robert Cowham (rob@vaccaperna.co.uk)
Date:08/21/2000 03:34:17 AM
List:com.perforce.perforce-user

Roger

You should check out the trigger/daemon scripts that Jeff Bowles has kindly put into the public depot file://guest/jeff_bowles/scripts/... for maintaining a common set of files and preventing modifications to them.

You may find it easier to invert the directory structure:

main/unix/... main/nt/... main/xp/... rel1.0/unix/... rel1.0/nt/... rel1.0/xp/... etc..

and set up those scripts etc to help you maintain things. If rel1.0 is an "NT release" then the unix subtree doesn't get modified by any bug fixes (and vice versa) - and you could have triggers ensuring this if you want.

Lots of branches isn't a problem for Perforce as long as you (and your developers) can understand why they exist and where changes should be made.

Robert

-----Original Message----- From: perforce-user-admin at perforce.com [mailto:perforce-user-admin at perforce.com]On Behalf Of Suttenbach, Roger Sent: Monday, August 21, 2000 09:13 To: 'perforce-user at perforce.com' Cc: 'support at perforce.com' Subject: [p4] Shared code

Hello everybody!

I have the following problem, maybe somebody else has a similar problem (or a solution :). We develop a system for at least two different platforms - here UNIX and NT - and we have code (xp=cross platform code) which is used on both platforms. The structure of our repository looks like this:

|--unix | |--nt | |--xp

We build our systems by combining the platform and the cross platform code, for example nt system = nt + xp unix system = unix +xp

In the future we also have one or two releases to maintain, that means we are having the following structure

|--unix | |-main | |-release | |--nt | |-main | |-release | |--xp | |-main | |-release

So again, we have to build a system by combining the release platform code with the shared release platform code, for example unix release system = unix release + xp release. nt release system = nt release +xp release

The problem here is, that if I make a bug fix e.g. for a unix release system in the cross platform code, it also effects the nt release system. (because the cross platform code (xp release) is shared)

I can deal with the problem by using branches for the xp code (a branch for unix and a branch for nt), but it creates a lot of branches. (and problems how to merge, ...)

1. Can anybody think of a better solution? 2. Is that the right way to deal with shared code (having a mainline for the shared code)?

Regards Roger