Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » U++ TheIDE » U++ TheIDE: Other Features Wishlist and/or Bugs » TheIDE remote package dependencies proposal - dealing with baazar
TheIDE remote package dependencies proposal - dealing with baazar [message #49906] Sun, 03 June 2018 23:02 Go to next message
Klugier is currently offline  Klugier
Messages: 1075
Registered: September 2012
Location: Poland, Kraków
Senior Contributor
Hello,

I was thinking how to deal with bazaar problem and I found one interesting solution that we can implement to U++ build infrastructure. However, it will require serve effort to implement.

The main idea of solving that problem is too provide remote package dependency. The user will be able to specif remote dependencies for his package. For example I want to use MessageCtrl from Oblivion in my package without manually copy it to my project...
#include <Remote/Github/Oblivion/MessageCtrl.h> // Should be able to specific GitHub repo directly...
...
#include <Remote/Bazaar/plugin/gtest/gtest.h> // Another example of using self hosted bazzar package...


Before build U++ can check and download required dependencies to Remote assembly folder that can be hidden in ~/.upp/theide directory. After that U++ is super easy to extend and It will be much more powerful with that feature.

This is the concept, so I would be grateful for any comments.

Sincerely,
Klugier


U++ - one framework to rule them all.
Re: TheIDE remote package dependencies proposal - dealing with baazar [message #49909 is a reply to message #49906] Mon, 04 June 2018 09:05 Go to previous messageGo to next message
koldo is currently offline  koldo
Messages: 3355
Registered: August 2008
Senior Veteran
Dear Klugier

I am sorry, could you explain the problem and define the proposal a little bit more?
Do you mean to convert Bazaar packages into header libraries?


Best regards
Iñaki
Re: TheIDE remote package dependencies proposal - dealing with baazar [message #49910 is a reply to message #49906] Mon, 04 June 2018 09:29 Go to previous messageGo to next message
Sender Ghost is currently offline  Sender Ghost
Messages: 301
Registered: November 2008
Senior Member
Hello Klugier.

I think, the current U++ build system is flexible on assembly and/or nests level without a need to use specific include(s):
Configuring Packages & Assemblies, Packages, Assemblies & Nests.

Klugier wrote on Sun, 03 June 2018 21:02
#include <Remote/Github/Oblivion/MessageCtrl.h> // Should be able to specific GitHub repo directly...
...
#include <Remote/Bazaar/plugin/gtest/gtest.h> // Another example of using self hosted bazzar package...

If you meant about https://github.com/ismail-yilmaz/upp-components repository, there is some example about how to use MessageCtrl package:
https://github.com/ismail-yilmaz/upp-components/blob/66a389c 08cec65a655b75bc4f7355646f36f708e/Examples/Messages/main.cpp #L1-L2
#include <CtrlLib/CtrlLib.h>
#include <MessageCtrl/MessageCtrl.h>

I may recommend to create upp-components-examples (or with a different name) assembly with following "Package nests", in this case (based on 39bbba5 commit):
path/to/upp-components/Examples;path/to/upp-components/Attic;path/to/upp-components/CtrlLib;path/to/upp-components/Core;path/to/upp/uppsrc
where
path/to/upp-components - is path to cloned https://github.com/ismail-yilmaz/upp-components repository
path/to/upp - is path to root of U++ uppsrc directory (also can be cloned from https://github.com/ultimatepp/mirror repository)

On the other hand, the concept of so-called downloadable/remote/vendor packages may require versioning (or other, e.g. commit) support to solve possible backward compatibility issue(s) or if some specific version is needed. But this may be unrelated.

[Updated on: Mon, 04 June 2018 11:49]

Report message to a moderator

Re: TheIDE remote package dependencies proposal - dealing with baazar [message #49911 is a reply to message #49906] Mon, 04 June 2018 09:59 Go to previous messageGo to next message
mr_ped is currently offline  mr_ped
Messages: 825
Registered: November 2005
Location: Czech Republic - Praha
Experienced Contributor
The proposed "remote" looks to resemble some things like artifactory/etc, where the "remote" packages are locally residing in some hidden directory in some cache.

I prefer to build from sources everything, and if I already have source somewhere, I prefer ordinary common location, like "bazaar", not some temporary cache. Also for important projects I keep all required sources (including framework libraries) in the project git, so I can be sure, that I have everything available even 15 years later, if for whatever reason I will need to rebuild the project (and I will have to fight hard only with the obsolete build tools, not also hunting down some old variants of libraries).

This policy is result of my personal experience, how I got burnt over years with my old work, which is now impossible to restore/update.

I guess the "cache" thingy with remote updates makes sense for binary distribution (like jar/aar/war archives in Java and Android world), but even there we often download the packages separately, and put them into project locally (and into git), so again the project git is self-contained, and doesn't need any remote server to be built. It makes the situation somewhat messy when you need to update the third party libraries often (like they are in development), but for most of the time it works reasonably well.

So I believe your proposal goes exactly in opposite direction ("without manually copy it to my project"), and I'm not interested.

But BTW, if you have the packages like in "bazaar" nest, and you have your apps nest configured to use that for build, you don't need to copy the bazaar package to your project nest, it will build from original bazaar location, so the UPP looks to solve this aspect (no need to copy manually) well.

[Updated on: Mon, 04 June 2018 10:00]

Report message to a moderator

Re: TheIDE remote package dependencies proposal - dealing with baazar [message #49914 is a reply to message #49906] Tue, 05 June 2018 18:19 Go to previous messageGo to next message
coolman is currently offline  coolman
Messages: 114
Registered: April 2006
Location: Czech Republic
Experienced Member
Hi all,

I would like solve another problem - how to develop and distribute the application. I've partially solved this problem using the upp_cmake and git submodules. This works OK for distribution. But developing is a little bit confusing. When I put the directory path of the application to the package nest I can see all packages in nested directories. (The application directory structure can bee seen at Rajce album downloader).

Do you have any idea how to see only the application package in the IDE package assembly or how to solve this problem better?

Thanks, Radek
Re: TheIDE remote package dependencies proposal - dealing with baazar [message #49926 is a reply to message #49914] Tue, 05 June 2018 22:20 Go to previous messageGo to next message
Sender Ghost is currently offline  Sender Ghost
Messages: 301
Registered: November 2008
Senior Member
Hello Radek.

coolman wrote on Tue, 05 June 2018 16:19
Do you have any idea how to see only the application package in the IDE package assembly or how to solve this problem better?

I think, that possible to create some nest directory for Rajce package to solve mentioned issue:
1. (Optional) Create some branch:
git checkout -b devel
2. Create Apps (or with a different name) directory:
mkdir Apps
3. Move Rajce to Apps/Rajce directory:
git mv Rajce Apps/Rajce
4. Fix symbolic link for LICENSE file:
ln -sf Apps/Rajce/Copying LICENSE
5. Rename "Rajce/Rajce.upp" to "Apps/Rajce/Rajce.upp" for PROJECT_NAME variable in GenerateCMakeFiles.sh file:
sed -i '' -e '/^PROJECT_NAME=/s|Rajce/|Apps/&|' GenerateCMakeFiles.sh
6.1. Save changes in local repository, if necessary (but also possible to do this for specific steps):
git commit -am "Move Rajce to Apps/Rajce directory"
6.2. (Optional) Merge and delete created branch:
git checkout master
git merge devel
git branch -d devel
7. Fix "Package nests" in some assembly, where Rajce package available:
path/to/Apps;path/to/ultimatepp/uppsrc
where path/to - is path to cloned rajce repository.

For example, separate nest directories also used for upp-components repository.

A possible alternative is to select the required package directly. For example, select ide package for uppsrc assembly:
theide uppsrc ide

[Updated on: Wed, 06 June 2018 00:18]

Report message to a moderator

Re: TheIDE remote package dependencies proposal - dealing with baazar [message #49927 is a reply to message #49906] Wed, 06 June 2018 07:51 Go to previous messageGo to next message
coolman is currently offline  coolman
Messages: 114
Registered: April 2006
Location: Czech Republic
Experienced Member
Hi Mirek,

Thank you for the reply. I did not think of this simple solution - just move the directory Rajce to another directory. And I have to admit it is elegant.

btw - LAYOUTFILE, TFILE and IMAGEFILE have to be updated as well.

Radek
Re: TheIDE remote package dependencies proposal - dealing with baazar [message #49929 is a reply to message #49927] Wed, 06 June 2018 08:52 Go to previous messageGo to next message
Sender Ghost is currently offline  Sender Ghost
Messages: 301
Registered: November 2008
Senior Member
coolman wrote on Wed, 06 June 2018 05:51
Hi Mirek,

I'm not him (if you replied to me).
coolman wrote on Wed, 06 June 2018 05:51
btw - LAYOUTFILE, TFILE and IMAGEFILE have to be updated as well.

No, this is not needed, if you added Apps (or with a different name) to first path of "Packages nest" for your assembly, where Rajce package available.
Sender Ghost wrote on Tue, 05 June 2018 20:20
7. Fix "Package nests" in some assembly, where Rajce package available:
path/to/Apps;path/to/ultimatepp/uppsrc
where path/to - is path to cloned rajce repository.

But looks like, you did this because of how current version of upp-cmake script(s) works. Probably, there is a need to add Apps (or with a different name) to include directories of generated CMakeLists.txt file:
# Set the default include directory for the whole project
include_directories ( BEFORE Apps )

In other words, there is may be a need to add ability to specify path(s) for nest(s), which may be used as include directories for compiler also.

[Updated on: Wed, 06 June 2018 09:35]

Report message to a moderator

Re: TheIDE remote package dependencies proposal - dealing with baazar [message #49936 is a reply to message #49906] Wed, 06 June 2018 10:01 Go to previous messageGo to next message
coolman is currently offline  coolman
Messages: 114
Registered: April 2006
Location: Czech Republic
Experienced Member
Hi,

I apologize for the wrong address.

Yes, you are right. I've updated the LAYOUTFILE, TFILE and IMAGEFILE because it was easiest to do that during testing of CLI build. But there is problem in the IDE with the compilation when assembly is set to path/to/Apps.

So I need to update upp_cmake to include appropriate path/to/Apps based on the package path using the "include_directories ()".

Radek
Re: TheIDE remote package dependencies proposal - dealing with baazar [message #49938 is a reply to message #49936] Wed, 06 June 2018 10:24 Go to previous messageGo to next message
Sender Ghost is currently offline  Sender Ghost
Messages: 301
Registered: November 2008
Senior Member
coolman wrote on Wed, 06 June 2018 08:01
I apologize for the wrong address.

It's ok, no problem.
coolman wrote on Wed, 06 June 2018 08:01
So I need to update upp_cmake to include appropriate path/to/Apps based on the package path using the "include_directories ()".

I may recommend to check how TheIDE uses assembly's nest(s), when "Setup -> Be verbose" selected for build (e.g. it may use them for compiler invocation as -I"path/to/Apps" -I"path/to/ultimatepp/uppsrc", when "Package nests" is "path/to/Apps;path/to/ultimatepp/uppsrc").

[Updated on: Wed, 06 June 2018 12:37]

Report message to a moderator

Re: TheIDE remote package dependencies proposal - dealing with baazar [message #49940 is a reply to message #49906] Wed, 06 June 2018 10:46 Go to previous message
coolman is currently offline  coolman
Messages: 114
Registered: April 2006
Location: Czech Republic
Experienced Member
Hi,

I've update the upp_cmake to include directories relevant to the package.

Radek
Previous Topic: Include full year in build_info.h instead of two last digits
Next Topic: [PROPOSAL] Redesigned Assembly Setup Dialog
Goto Forum:
  


Current Time: Thu Mar 28 23:20:21 CET 2024

Total time taken to generate the page: 0.01118 seconds