首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >Maven Building eclipse-gov.redhawk.core,nxm-ui repo

Maven Building eclipse-gov.redhawk.core,nxm-ui repo
EN

Stack Overflow用户
提问于 2014-05-16 18:21:51
回答 1查看 154关注 0票数 0

这个问题是对Netrunner的问题here.的后续,基于Englund的答复,我能够通过创建自己的mil.jpeojtrs.sca包,在本地安装它,并相应地更新mil.jpeojtrs.sca/releng中的pom.xml文件来打包和安装mil.jpeojtrs.sca。

但是,Netrunner在试图安装gov.redhawk.core时也会出现同样的问题.nxm-ui回购指向redhawk.sdr.org回购:

代码语言:javascript
复制
http://download.redhawksdr.org/nxm-rcp/releases/1.0

与jacorb不同的是,我找不到可以打包的等效包。正如Netrunner所问的,这是一个独特的,红鹰开发的软件包吗?如果是的话,是否可以在github上访问它,以便我们也可以在必要时构建自己的包?如果没有,你能指给我们一个同等的包裹吗?

EN

回答 1

Stack Overflow用户

回答已采纳

发布于 2014-07-02 12:45:45

IDE可以从源代码构建,但是它目前需要一些腿的工作。下面是您可以采取的步骤和自动化过程的脚本。这只是一个例子,应该修改以满足您的需要。

  1. 有许多插件,您需要创建一个更新站点,使用Redhawk1.9.0IDE,这是相当容易的。

代码语言:javascript
复制
- Open your 1.9.0 IDE.  File -> New -> Project.  Select the Show All Wizards checkbox.  Type in "update" to filter to the "Update Site Project"
- You may be prompted to enable development of plugin projects, hit okay.
- Give the project a name & click finish.
- Add a category, provide an ID & name doesn't matter what but it is required.
- Now add the following features: 

-- org.jacorb -没有打包成互联网上任何地方的更新站点

- org.eclipse.nebula.widgets.xviewer.feature -这只是因为星云特性没有稳定的API,并且自1.9.0构建以来发生了变化

代码语言:javascript
复制
- Click Build All.  Copy down the location of this update site.  To find the location you can right click on site.xml and select properties.  The path needed is the folder which contains site.xml

  1. 复制下面的脚本,将其放置到一个空文件夹中,并将LOCAL_P2变量更改为指向这个新生成的P2站点。
  2. 使用chmod +x使脚本可执行
  3. 运行脚本。这可能需要一段时间,但它将克隆所有的存储库,做出适当的补丁,并构建IDE产品。

同样,这应该只是一个示例,而不是IDE的构建系统。还请注意,这是构建1.9.0和修改将是必要的,以构建开发-1.10和开发-1.9分支的IDE。

代码语言:javascript
复制
#!/bin/bash

function error() {
        printf "\n\nREDHAWK IDE BUILD Failed!\n\n"
        exit 1
}

LOCAL_P2="/home/ylb/exampleLocation"

MVN="mvn"
MVN_PHASE="clean verify"
GIT="git"
REDHAWK_VERSION="develop-1.9"
MINOR_VERSION="1.9.0"

BASEDIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"

MIL_GIT="https://github.com/RedhawkSDR/eclipse-mil.jpeojtrs.sca.git"
MIL_BRANCH=${REDHAWK_VERSION}
MIL_P2="-Dmil.jpeojtrs.sca=file:///${BASEDIR}/mil.jpeojtrs.sca/releng/p2/target/repository"

CORE_GIT="https://github.com/RedhawkSDR/eclipse-gov.redhawk.core.git"
CORE_BRANCH=${REDHAWK_VERSION}
CORE_P2="-Dgov.redhawk.core=file:///${BASEDIR}/gov.redhawk.core/releng/core/p2/target/repository"
RCP_P2="-Dgov.redhawk.core.rcp=file:///${BASEDIR}/gov.redhawk.core/releng/rcp/p2/target/repository"

IDE_GIT="https://github.com/RedhawkSDR/eclipse-gov.redhawk.ide.git"
IDE_BRANCH=${REDHAWK_VERSION}
IDE_P2="-Dgov.redhawk.ide=file:///${BASEDIR}/gov.redhawk.ide/releng/p2/target/repository"
DOC_ZIP="-Dgov.redhawk.ide.help.doc.zip=file:///${BASEDIR}/doc.zip"

CODEGEN_GIT="https://github.com/RedhawkSDR/eclipse-gov.redhawk.codegen.git"
CODEGEN_BRANCH=${REDHAWK_VERSION}
CODEGEN_P2="-Dgov.redhawk.codegen=file:///${BASEDIR}/gov.redhawk.codegen/releng/p2/target/repository"

PRODUCT_GIT="https://github.com/RedhawkSDR/eclipse-products-gov.redhawk.ide.product.git"
PRODUCT_BRANCH=${REDHAWK_VERSION}
PRODUCT_P2="-Dgov.redhawk.ide.product=file:///${BASEDIR}/gov.redhawk.ide.product/releng/p2/target/repository"

# First clone all the repositories
if [ ! -d mil.jpeojtrs.sca ]; then
  printf "\n\nCloning mil.jpeojtrs.sca...\n\n"
  ${GIT} clone -b ${MIL_BRANCH} ${MIL_GIT} mil.jpeojtrs.sca; cd mil.jpeojtrs.sca; git checkout ${MINOR_VERSION}; cd ..;
fi

if [ ! -d gov.redhawk.core ]; then
  printf "\n\nCloning gov.redhawk.core...\n\n"
  ${GIT} clone -b ${CORE_BRANCH} ${CORE_GIT} gov.redhawk.core; cd gov.redhawk.core; git checkout ${MINOR_VERSION}; cd ..;
fi


if [ ! -d gov.redhawk.ide ]; then
  printf "\n\nCloning gov.redhawk.ide...\n\n"
  ${GIT} clone -b ${IDE_BRANCH} ${IDE_GIT} gov.redhawk.ide; cd gov.redhawk.ide; git checkout ${MINOR_VERSION}; cd ..;
fi

if [ ! -d gov.redhawk.codegen ]; then
  printf "\n\nCloning gov.redhawk.codegen...\n\n"
  ${GIT} clone -b ${CODEGEN_BRANCH} ${CODEGEN_GIT} gov.redhawk.codegen; cd gov.redhawk.codegen; git checkout ${MINOR_VERSION}; cd ..;
fi

if [ ! -d gov.redhawk.ide.product ]; then
  printf "\n\nCloning gov.redhawk.ide.product...\n\n"
  ${GIT} clone -b ${PRODUCT_BRANCH} ${PRODUCT_GIT} gov.redhawk.ide.product; cd gov.redhawk.ide.product; git checkout ${MINOR_VERSION}; cd ..;
fi

# The documentation is wrapped up into the build, rather than build the documentation just create a dummy zip file
touch FakeDocumentation.txt
zip doc.zip FakeDocumentation.txt

# Now we must fix the pom.xml files to point to proper locations

# Fix things wrong with core
sed -i 's,http://download.redhawksdr.org/nxm-rcp/releases/1.0,http://nextmidas.techma.com/p2/nxm.ui/updates/latest,g' ./gov.redhawk.core/releng/pom.xml

# Now ide pom

# CAREFUL! Removing lines 33-45
if [ $(grep "<id>eclipse-updates</id>" ./gov.redhawk.ide/releng/pom.xml | wc -l) == 1 ]; then
  sed -i '33,45d' ./gov.redhawk.ide/releng/pom.xml
fi

sed -i '/<eclipse-support>/d' ./gov.redhawk.ide/releng/pom.xml
sed -i '/<eclipse-updates>/d' ./gov.redhawk.ide/releng/pom.xml
sed -i "s,http://download.eclipse.org/technology/nebula/snapshot,file://${LOCAL_P2},g" ./gov.redhawk.ide/releng/pom.xml
sed -i 's,http://download.redhawksdr.org/nxm-rcp/releases/1.0,http://nextmidas.techma.com/p2/nxm.ui/updates/latest,g' ./gov.redhawk.ide/releng/pom.xml

# Now the codegen
sed -i 's,http://download.redhawksdr.org/nxm-rcp/releases/1.0,http://nextmidas.techma.com/p2/nxm.ui/updates/latest,g' ./gov.redhawk.codegen/releng/pom.xml
sed -i "s,http://pydev.org/updates,file://${LOCAL_P2},g" ./gov.redhawk.codegen/releng/pom.xml

# Now the product
sed -i "s,http://download.redhawksdr.org/mil.jpeojtrs.sca/releases/1.9,file://${BASEDIR}/mil.jpeojtrs.sca/releng/p2/target/repository,g" ./gov.redhawk.ide.product/releng/target-definition/target-definition.target
sed -i 's,http://download.redhawksdr.org/nxm-ui/releases/1.0,http://nextmidas.techma.com/p2/nxm.ui/updates/latest,g' ./gov.redhawk.ide.product/releng/target-definition/target-definition.target
sed -i "s,http://download.redhawksdr.org/gov.redhawk.codegen/releases/1.9,file://${BASEDIR}/gov.redhawk.codegen/releng/p2/target/repository,g" ./gov.redhawk.ide.product/releng/target-definition/target-definition.target
sed -i "s,http://download.redhawksdr.org/gov.redhawk.core/rcp/releases/1.9,file://${BASEDIR}/gov.redhawk.core/releng/rcp/p2/target/repository,g" ./gov.redhawk.ide.product/releng/target-definition/target-definition.target
sed -i "s,http://download.redhawksdr.org/jacorb/releases/3.1,file://${LOCAL_P2},g" ./gov.redhawk.ide.product/releng/target-definition/target-definition.target
sed -i "s,http://download.redhawksdr.org/gov.redhawk.ide/releases/1.9,file://${BASEDIR}/gov.redhawk.ide/releng/p2/target/repository,g" ./gov.redhawk.ide.product/releng/target-definition/target-definition.target
sed -i "s,http://download.redhawksdr.org/gov.redhawk.core/releases/1.9,file://${BASEDIR}/gov.redhawk.core/releng/core/p2/target/repository,g" ./gov.redhawk.ide.product/releng/target-definition/target-definition.target
sed -i "s,http://download.eclipse.org/technology/nebula/snapshot,file://${LOCAL_P2},g" ./gov.redhawk.ide.product/releng/target-definition/target-definition.target

# Then build each repo.
printf "\n\nBuilding mil.jpeojtrs.sca...\n\n"
${MVN} -f ${BASEDIR}/mil.jpeojtrs.sca/releng/pom.xml ${MVN_PHASE} -Djacorb=file://${LOCAL_P2} ${MIL_P2} || error

printf "\n\nBuilding gov.redhawk.core...\n\n"
${MVN} -f ${BASEDIR}/gov.redhawk.core/releng/core/pom.xml ${MVN_PHASE} -Djacorb=file://${LOCAL_P2} ${MIL_P2} ${CORE_P2} || error

printf "\n\nBuilding gov.redhawk.rcp...\n\n"
${MVN} -f ${BASEDIR}/gov.redhawk.core/releng/rcp/pom.xml ${MVN_PHASE} -Djacorb=file://${LOCAL_P2} ${MIL_P2} ${CORE_P2} ${RCP_P2} || error

printf "\n\nBuilding gov.redhawk.ide...\n\n"
${MVN} -f ${BASEDIR}/gov.redhawk.ide/releng/pom.xml ${MVN_PHASE} -Djacorb=file://${LOCAL_P2} ${MIL_P2} ${CORE_P2} ${RCP_P2} ${DOC_ZIP} ${IDE_P2} || error

printf "\n\nBuilding gov.redhawk.codegen...\n\n"
${MVN} -f ${BASEDIR}/gov.redhawk.codegen/releng/pom.xml ${MVN_PHASE} -Djacorb=file://${LOCAL_P2} ${MIL_P2} ${CORE_P2} ${RCP_P2} ${IDE_P2} ${CODEGEN_P2} || error

printf "\n\nBuilding gov.redhawk.ide.product...\n\n"
${MVN} -f ${BASEDIR}/gov.redhawk.ide.product/releng/pom.xml ${MVN_PHASE} -Djacorb=file://${LOCAL_P2} ${MIL_P2} ${CORE_P2} ${RCP_P2} ${IDE_P2} ${CODEGEN_P2} ${PRODUCT_P2} || error

printf "\n\nBuild SUCCESS!!!\n"
printf "\n\nProducts may be found in ${BASEDIR}/gov.redhawk.ide.product/releng/product/target/products/gov.redhawk.product.ide.product\n"
票数 1
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/23702165

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档